aboutsummaryrefslogtreecommitdiff
path: root/crates/ra_syntax
diff options
context:
space:
mode:
Diffstat (limited to 'crates/ra_syntax')
-rw-r--r--crates/ra_syntax/src/ast/edit.rs17
-rw-r--r--crates/ra_syntax/src/ast/generated/nodes.rs88
-rw-r--r--crates/ra_syntax/src/ast/make.rs2
-rw-r--r--crates/ra_syntax/test_data/parser/err/0018_incomplete_fn.rast2
-rw-r--r--crates/ra_syntax/test_data/parser/err/0026_imp_recovery.rast2
-rw-r--r--crates/ra_syntax/test_data/parser/err/0037_visibility_in_traits.rast2
-rw-r--r--crates/ra_syntax/test_data/parser/err/0043_default_const.rast2
-rw-r--r--crates/ra_syntax/test_data/parser/inline/err/0004_impl_type.rast8
-rw-r--r--crates/ra_syntax/test_data/parser/inline/err/0014_default_fn_type.rast2
-rw-r--r--crates/ra_syntax/test_data/parser/inline/ok/0001_trait_item_list.rast2
-rw-r--r--crates/ra_syntax/test_data/parser/inline/ok/0006_self_param.rast2
-rw-r--r--crates/ra_syntax/test_data/parser/inline/ok/0016_unsafe_trait.rast2
-rw-r--r--crates/ra_syntax/test_data/parser/inline/ok/0018_arb_self_types.rast2
-rw-r--r--crates/ra_syntax/test_data/parser/inline/ok/0021_impl_item_list.rast2
-rw-r--r--crates/ra_syntax/test_data/parser/inline/ok/0041_trait_item.rast4
-rw-r--r--crates/ra_syntax/test_data/parser/inline/ok/0043_use_alias.rast8
-rw-r--r--crates/ra_syntax/test_data/parser/inline/ok/0047_unsafe_default_impl.rast2
-rw-r--r--crates/ra_syntax/test_data/parser/inline/ok/0050_fn_decl.rast2
-rw-r--r--crates/ra_syntax/test_data/parser/inline/ok/0063_impl_def_neg.rast2
-rw-r--r--crates/ra_syntax/test_data/parser/inline/ok/0079_impl_def.rast2
-rw-r--r--crates/ra_syntax/test_data/parser/inline/ok/0087_unsafe_impl.rast2
-rw-r--r--crates/ra_syntax/test_data/parser/inline/ok/0091_auto_trait.rast2
-rw-r--r--crates/ra_syntax/test_data/parser/inline/ok/0094_unsafe_auto_trait.rast2
-rw-r--r--crates/ra_syntax/test_data/parser/inline/ok/0097_default_impl.rast2
-rw-r--r--crates/ra_syntax/test_data/parser/inline/ok/0118_impl_inner_attributes.rast2
-rw-r--r--crates/ra_syntax/test_data/parser/inline/ok/0132_default_fn_type.rast2
-rw-r--r--crates/ra_syntax/test_data/parser/inline/ok/0150_impl_type_params.rast2
-rw-r--r--crates/ra_syntax/test_data/parser/inline/ok/0163_default_unsafe_fn.rast2
-rw-r--r--crates/ra_syntax/test_data/parser/inline/ok/0163_default_unsafe_impl.rast2
-rw-r--r--crates/ra_syntax/test_data/parser/ok/0007_extern_crate.rast4
-rw-r--r--crates/ra_syntax/test_data/parser/ok/0015_use_tree.rast6
-rw-r--r--crates/ra_syntax/test_data/parser/ok/0030_traits.rast4
-rw-r--r--crates/ra_syntax/test_data/parser/ok/0042_ufcs_call_list.rast2
-rw-r--r--crates/ra_syntax/test_data/parser/ok/0045_block_inner_attrs.rast2
-rw-r--r--crates/ra_syntax/test_data/parser/ok/0051_parameter_attrs.rast4
-rw-r--r--crates/ra_syntax/test_data/parser/ok/0063_trait_fn_patterns.rast2
-rw-r--r--crates/ra_syntax/test_data/parser/ok/0064_impl_fn_params.rast2
-rw-r--r--crates/ra_syntax/test_data/parser/ok/0066_default_const.rast2
38 files changed, 119 insertions, 82 deletions
diff --git a/crates/ra_syntax/src/ast/edit.rs b/crates/ra_syntax/src/ast/edit.rs
index abc7a646c..2e958fa23 100644
--- a/crates/ra_syntax/src/ast/edit.rs
+++ b/crates/ra_syntax/src/ast/edit.rs
@@ -80,9 +80,12 @@ where
80 } 80 }
81} 81}
82 82
83impl ast::ItemList { 83impl ast::AssocItemList {
84 #[must_use] 84 #[must_use]
85 pub fn append_items(&self, items: impl IntoIterator<Item = ast::AssocItem>) -> ast::ItemList { 85 pub fn append_items(
86 &self,
87 items: impl IntoIterator<Item = ast::AssocItem>,
88 ) -> ast::AssocItemList {
86 let mut res = self.clone(); 89 let mut res = self.clone();
87 if !self.syntax().text().contains_char('\n') { 90 if !self.syntax().text().contains_char('\n') {
88 res = make_multiline(res); 91 res = make_multiline(res);
@@ -92,7 +95,7 @@ impl ast::ItemList {
92 } 95 }
93 96
94 #[must_use] 97 #[must_use]
95 pub fn append_item(&self, item: ast::AssocItem) -> ast::ItemList { 98 pub fn append_item(&self, item: ast::AssocItem) -> ast::AssocItemList {
96 let (indent, position) = match self.assoc_items().last() { 99 let (indent, position) = match self.assoc_items().last() {
97 Some(it) => ( 100 Some(it) => (
98 leading_indent(it.syntax()).unwrap_or_default().to_string(), 101 leading_indent(it.syntax()).unwrap_or_default().to_string(),
@@ -314,8 +317,12 @@ impl ast::UseTree {
314 Some(it) => it, 317 Some(it) => it,
315 None => return self.clone(), 318 None => return self.clone(),
316 }; 319 };
317 let use_tree = 320 let use_tree = make::use_tree(
318 make::use_tree(suffix, self.use_tree_list(), self.alias(), self.star_token().is_some()); 321 suffix,
322 self.use_tree_list(),
323 self.rename(),
324 self.star_token().is_some(),
325 );
319 let nested = make::use_tree_list(iter::once(use_tree)); 326 let nested = make::use_tree_list(iter::once(use_tree));
320 return make::use_tree(prefix.clone(), Some(nested), None, false); 327 return make::use_tree(prefix.clone(), Some(nested), None, false);
321 328
diff --git a/crates/ra_syntax/src/ast/generated/nodes.rs b/crates/ra_syntax/src/ast/generated/nodes.rs
index dfda79550..01e8111b0 100644
--- a/crates/ra_syntax/src/ast/generated/nodes.rs
+++ b/crates/ra_syntax/src/ast/generated/nodes.rs
@@ -75,7 +75,7 @@ impl ExternCrateItem {
75 pub fn crate_token(&self) -> Option<SyntaxToken> { support::token(&self.syntax, T![crate]) } 75 pub fn crate_token(&self) -> Option<SyntaxToken> { support::token(&self.syntax, T![crate]) }
76 pub fn name_ref(&self) -> Option<NameRef> { support::child(&self.syntax) } 76 pub fn name_ref(&self) -> Option<NameRef> { support::child(&self.syntax) }
77 pub fn self_token(&self) -> Option<SyntaxToken> { support::token(&self.syntax, T![self]) } 77 pub fn self_token(&self) -> Option<SyntaxToken> { support::token(&self.syntax, T![self]) }
78 pub fn alias(&self) -> Option<Alias> { support::child(&self.syntax) } 78 pub fn rename(&self) -> Option<Rename> { support::child(&self.syntax) }
79 pub fn semicolon_token(&self) -> Option<SyntaxToken> { support::token(&self.syntax, T![;]) } 79 pub fn semicolon_token(&self) -> Option<SyntaxToken> { support::token(&self.syntax, T![;]) }
80} 80}
81#[derive(Debug, Clone, PartialEq, Eq, Hash)] 81#[derive(Debug, Clone, PartialEq, Eq, Hash)]
@@ -112,7 +112,7 @@ impl ImplDef {
112 pub fn impl_token(&self) -> Option<SyntaxToken> { support::token(&self.syntax, T![impl]) } 112 pub fn impl_token(&self) -> Option<SyntaxToken> { support::token(&self.syntax, T![impl]) }
113 pub fn excl_token(&self) -> Option<SyntaxToken> { support::token(&self.syntax, T![!]) } 113 pub fn excl_token(&self) -> Option<SyntaxToken> { support::token(&self.syntax, T![!]) }
114 pub fn for_token(&self) -> Option<SyntaxToken> { support::token(&self.syntax, T![for]) } 114 pub fn for_token(&self) -> Option<SyntaxToken> { support::token(&self.syntax, T![for]) }
115 pub fn item_list(&self) -> Option<ItemList> { support::child(&self.syntax) } 115 pub fn assoc_item_list(&self) -> Option<AssocItemList> { support::child(&self.syntax) }
116} 116}
117#[derive(Debug, Clone, PartialEq, Eq, Hash)] 117#[derive(Debug, Clone, PartialEq, Eq, Hash)]
118pub struct MacroCall { 118pub struct MacroCall {
@@ -180,7 +180,7 @@ impl TraitDef {
180 pub fn unsafe_token(&self) -> Option<SyntaxToken> { support::token(&self.syntax, T![unsafe]) } 180 pub fn unsafe_token(&self) -> Option<SyntaxToken> { support::token(&self.syntax, T![unsafe]) }
181 pub fn auto_token(&self) -> Option<SyntaxToken> { support::token(&self.syntax, T![auto]) } 181 pub fn auto_token(&self) -> Option<SyntaxToken> { support::token(&self.syntax, T![auto]) }
182 pub fn trait_token(&self) -> Option<SyntaxToken> { support::token(&self.syntax, T![trait]) } 182 pub fn trait_token(&self) -> Option<SyntaxToken> { support::token(&self.syntax, T![trait]) }
183 pub fn item_list(&self) -> Option<ItemList> { support::child(&self.syntax) } 183 pub fn assoc_item_list(&self) -> Option<AssocItemList> { support::child(&self.syntax) }
184} 184}
185#[derive(Debug, Clone, PartialEq, Eq, Hash)] 185#[derive(Debug, Clone, PartialEq, Eq, Hash)]
186pub struct TypeAliasDef { 186pub struct TypeAliasDef {
@@ -238,11 +238,6 @@ impl Visibility {
238 pub fn r_paren_token(&self) -> Option<SyntaxToken> { support::token(&self.syntax, T![')']) } 238 pub fn r_paren_token(&self) -> Option<SyntaxToken> { support::token(&self.syntax, T![')']) }
239} 239}
240#[derive(Debug, Clone, PartialEq, Eq, Hash)] 240#[derive(Debug, Clone, PartialEq, Eq, Hash)]
241pub struct Abi {
242 pub(crate) syntax: SyntaxNode,
243}
244impl Abi {}
245#[derive(Debug, Clone, PartialEq, Eq, Hash)]
246pub struct Name { 241pub struct Name {
247 pub(crate) syntax: SyntaxNode, 242 pub(crate) syntax: SyntaxNode,
248} 243}
@@ -250,6 +245,21 @@ impl Name {
250 pub fn ident_token(&self) -> Option<SyntaxToken> { support::token(&self.syntax, T![ident]) } 245 pub fn ident_token(&self) -> Option<SyntaxToken> { support::token(&self.syntax, T![ident]) }
251} 246}
252#[derive(Debug, Clone, PartialEq, Eq, Hash)] 247#[derive(Debug, Clone, PartialEq, Eq, Hash)]
248pub struct ItemList {
249 pub(crate) syntax: SyntaxNode,
250}
251impl ast::AttrsOwner for ItemList {}
252impl ast::ModuleItemOwner for ItemList {}
253impl ItemList {
254 pub fn l_curly_token(&self) -> Option<SyntaxToken> { support::token(&self.syntax, T!['{']) }
255 pub fn r_curly_token(&self) -> Option<SyntaxToken> { support::token(&self.syntax, T!['}']) }
256}
257#[derive(Debug, Clone, PartialEq, Eq, Hash)]
258pub struct Abi {
259 pub(crate) syntax: SyntaxNode,
260}
261impl Abi {}
262#[derive(Debug, Clone, PartialEq, Eq, Hash)]
253pub struct TypeParamList { 263pub struct TypeParamList {
254 pub(crate) syntax: SyntaxNode, 264 pub(crate) syntax: SyntaxNode,
255} 265}
@@ -367,11 +377,10 @@ impl TypeBoundList {
367 pub fn bounds(&self) -> AstChildren<TypeBound> { support::children(&self.syntax) } 377 pub fn bounds(&self) -> AstChildren<TypeBound> { support::children(&self.syntax) }
368} 378}
369#[derive(Debug, Clone, PartialEq, Eq, Hash)] 379#[derive(Debug, Clone, PartialEq, Eq, Hash)]
370pub struct ItemList { 380pub struct AssocItemList {
371 pub(crate) syntax: SyntaxNode, 381 pub(crate) syntax: SyntaxNode,
372} 382}
373impl ast::ModuleItemOwner for ItemList {} 383impl AssocItemList {
374impl ItemList {
375 pub fn l_curly_token(&self) -> Option<SyntaxToken> { support::token(&self.syntax, T!['{']) } 384 pub fn l_curly_token(&self) -> Option<SyntaxToken> { support::token(&self.syntax, T!['{']) }
376 pub fn assoc_items(&self) -> AstChildren<AssocItem> { support::children(&self.syntax) } 385 pub fn assoc_items(&self) -> AstChildren<AssocItem> { support::children(&self.syntax) }
377 pub fn r_curly_token(&self) -> Option<SyntaxToken> { support::token(&self.syntax, T!['}']) } 386 pub fn r_curly_token(&self) -> Option<SyntaxToken> { support::token(&self.syntax, T!['}']) }
@@ -1169,7 +1178,7 @@ impl UseTree {
1169 pub fn coloncolon_token(&self) -> Option<SyntaxToken> { support::token(&self.syntax, T![::]) } 1178 pub fn coloncolon_token(&self) -> Option<SyntaxToken> { support::token(&self.syntax, T![::]) }
1170 pub fn star_token(&self) -> Option<SyntaxToken> { support::token(&self.syntax, T![*]) } 1179 pub fn star_token(&self) -> Option<SyntaxToken> { support::token(&self.syntax, T![*]) }
1171 pub fn use_tree_list(&self) -> Option<UseTreeList> { support::child(&self.syntax) } 1180 pub fn use_tree_list(&self) -> Option<UseTreeList> { support::child(&self.syntax) }
1172 pub fn alias(&self) -> Option<Alias> { support::child(&self.syntax) } 1181 pub fn rename(&self) -> Option<Rename> { support::child(&self.syntax) }
1173} 1182}
1174#[derive(Debug, Clone, PartialEq, Eq, Hash)] 1183#[derive(Debug, Clone, PartialEq, Eq, Hash)]
1175pub struct UseTreeList { 1184pub struct UseTreeList {
@@ -1181,11 +1190,11 @@ impl UseTreeList {
1181 pub fn r_curly_token(&self) -> Option<SyntaxToken> { support::token(&self.syntax, T!['}']) } 1190 pub fn r_curly_token(&self) -> Option<SyntaxToken> { support::token(&self.syntax, T!['}']) }
1182} 1191}
1183#[derive(Debug, Clone, PartialEq, Eq, Hash)] 1192#[derive(Debug, Clone, PartialEq, Eq, Hash)]
1184pub struct Alias { 1193pub struct Rename {
1185 pub(crate) syntax: SyntaxNode, 1194 pub(crate) syntax: SyntaxNode,
1186} 1195}
1187impl ast::NameOwner for Alias {} 1196impl ast::NameOwner for Rename {}
1188impl Alias { 1197impl Rename {
1189 pub fn as_token(&self) -> Option<SyntaxToken> { support::token(&self.syntax, T![as]) } 1198 pub fn as_token(&self) -> Option<SyntaxToken> { support::token(&self.syntax, T![as]) }
1190} 1199}
1191#[derive(Debug, Clone, PartialEq, Eq, Hash)] 1200#[derive(Debug, Clone, PartialEq, Eq, Hash)]
@@ -1336,10 +1345,10 @@ pub enum AssocItem {
1336 FnDef(FnDef), 1345 FnDef(FnDef),
1337 TypeAliasDef(TypeAliasDef), 1346 TypeAliasDef(TypeAliasDef),
1338 ConstDef(ConstDef), 1347 ConstDef(ConstDef),
1348 MacroCall(MacroCall),
1339} 1349}
1340impl ast::AttrsOwner for AssocItem {} 1350impl ast::AttrsOwner for AssocItem {}
1341impl ast::NameOwner for AssocItem {} 1351impl ast::NameOwner for AssocItem {}
1342impl ast::VisibilityOwner for AssocItem {}
1343#[derive(Debug, Clone, PartialEq, Eq, Hash)] 1352#[derive(Debug, Clone, PartialEq, Eq, Hash)]
1344pub enum Pat { 1353pub enum Pat {
1345 OrPat(OrPat), 1354 OrPat(OrPat),
@@ -1574,8 +1583,8 @@ impl AstNode for Visibility {
1574 } 1583 }
1575 fn syntax(&self) -> &SyntaxNode { &self.syntax } 1584 fn syntax(&self) -> &SyntaxNode { &self.syntax }
1576} 1585}
1577impl AstNode for Abi { 1586impl AstNode for Name {
1578 fn can_cast(kind: SyntaxKind) -> bool { kind == ABI } 1587 fn can_cast(kind: SyntaxKind) -> bool { kind == NAME }
1579 fn cast(syntax: SyntaxNode) -> Option<Self> { 1588 fn cast(syntax: SyntaxNode) -> Option<Self> {
1580 if Self::can_cast(syntax.kind()) { 1589 if Self::can_cast(syntax.kind()) {
1581 Some(Self { syntax }) 1590 Some(Self { syntax })
@@ -1585,8 +1594,19 @@ impl AstNode for Abi {
1585 } 1594 }
1586 fn syntax(&self) -> &SyntaxNode { &self.syntax } 1595 fn syntax(&self) -> &SyntaxNode { &self.syntax }
1587} 1596}
1588impl AstNode for Name { 1597impl AstNode for ItemList {
1589 fn can_cast(kind: SyntaxKind) -> bool { kind == NAME } 1598 fn can_cast(kind: SyntaxKind) -> bool { kind == ITEM_LIST }
1599 fn cast(syntax: SyntaxNode) -> Option<Self> {
1600 if Self::can_cast(syntax.kind()) {
1601 Some(Self { syntax })
1602 } else {
1603 None
1604 }
1605 }
1606 fn syntax(&self) -> &SyntaxNode { &self.syntax }
1607}
1608impl AstNode for Abi {
1609 fn can_cast(kind: SyntaxKind) -> bool { kind == ABI }
1590 fn cast(syntax: SyntaxNode) -> Option<Self> { 1610 fn cast(syntax: SyntaxNode) -> Option<Self> {
1591 if Self::can_cast(syntax.kind()) { 1611 if Self::can_cast(syntax.kind()) {
1592 Some(Self { syntax }) 1612 Some(Self { syntax })
@@ -1728,8 +1748,8 @@ impl AstNode for TypeBoundList {
1728 } 1748 }
1729 fn syntax(&self) -> &SyntaxNode { &self.syntax } 1749 fn syntax(&self) -> &SyntaxNode { &self.syntax }
1730} 1750}
1731impl AstNode for ItemList { 1751impl AstNode for AssocItemList {
1732 fn can_cast(kind: SyntaxKind) -> bool { kind == ITEM_LIST } 1752 fn can_cast(kind: SyntaxKind) -> bool { kind == ASSOC_ITEM_LIST }
1733 fn cast(syntax: SyntaxNode) -> Option<Self> { 1753 fn cast(syntax: SyntaxNode) -> Option<Self> {
1734 if Self::can_cast(syntax.kind()) { 1754 if Self::can_cast(syntax.kind()) {
1735 Some(Self { syntax }) 1755 Some(Self { syntax })
@@ -2663,8 +2683,8 @@ impl AstNode for UseTreeList {
2663 } 2683 }
2664 fn syntax(&self) -> &SyntaxNode { &self.syntax } 2684 fn syntax(&self) -> &SyntaxNode { &self.syntax }
2665} 2685}
2666impl AstNode for Alias { 2686impl AstNode for Rename {
2667 fn can_cast(kind: SyntaxKind) -> bool { kind == ALIAS } 2687 fn can_cast(kind: SyntaxKind) -> bool { kind == RENAME }
2668 fn cast(syntax: SyntaxNode) -> Option<Self> { 2688 fn cast(syntax: SyntaxNode) -> Option<Self> {
2669 if Self::can_cast(syntax.kind()) { 2689 if Self::can_cast(syntax.kind()) {
2670 Some(Self { syntax }) 2690 Some(Self { syntax })
@@ -3144,10 +3164,13 @@ impl From<TypeAliasDef> for AssocItem {
3144impl From<ConstDef> for AssocItem { 3164impl From<ConstDef> for AssocItem {
3145 fn from(node: ConstDef) -> AssocItem { AssocItem::ConstDef(node) } 3165 fn from(node: ConstDef) -> AssocItem { AssocItem::ConstDef(node) }
3146} 3166}
3167impl From<MacroCall> for AssocItem {
3168 fn from(node: MacroCall) -> AssocItem { AssocItem::MacroCall(node) }
3169}
3147impl AstNode for AssocItem { 3170impl AstNode for AssocItem {
3148 fn can_cast(kind: SyntaxKind) -> bool { 3171 fn can_cast(kind: SyntaxKind) -> bool {
3149 match kind { 3172 match kind {
3150 FN_DEF | TYPE_ALIAS_DEF | CONST_DEF => true, 3173 FN_DEF | TYPE_ALIAS_DEF | CONST_DEF | MACRO_CALL => true,
3151 _ => false, 3174 _ => false,
3152 } 3175 }
3153 } 3176 }
@@ -3156,6 +3179,7 @@ impl AstNode for AssocItem {
3156 FN_DEF => AssocItem::FnDef(FnDef { syntax }), 3179 FN_DEF => AssocItem::FnDef(FnDef { syntax }),
3157 TYPE_ALIAS_DEF => AssocItem::TypeAliasDef(TypeAliasDef { syntax }), 3180 TYPE_ALIAS_DEF => AssocItem::TypeAliasDef(TypeAliasDef { syntax }),
3158 CONST_DEF => AssocItem::ConstDef(ConstDef { syntax }), 3181 CONST_DEF => AssocItem::ConstDef(ConstDef { syntax }),
3182 MACRO_CALL => AssocItem::MacroCall(MacroCall { syntax }),
3159 _ => return None, 3183 _ => return None,
3160 }; 3184 };
3161 Some(res) 3185 Some(res)
@@ -3165,6 +3189,7 @@ impl AstNode for AssocItem {
3165 AssocItem::FnDef(it) => &it.syntax, 3189 AssocItem::FnDef(it) => &it.syntax,
3166 AssocItem::TypeAliasDef(it) => &it.syntax, 3190 AssocItem::TypeAliasDef(it) => &it.syntax,
3167 AssocItem::ConstDef(it) => &it.syntax, 3191 AssocItem::ConstDef(it) => &it.syntax,
3192 AssocItem::MacroCall(it) => &it.syntax,
3168 } 3193 }
3169 } 3194 }
3170} 3195}
@@ -3515,12 +3540,17 @@ impl std::fmt::Display for Visibility {
3515 std::fmt::Display::fmt(self.syntax(), f) 3540 std::fmt::Display::fmt(self.syntax(), f)
3516 } 3541 }
3517} 3542}
3518impl std::fmt::Display for Abi { 3543impl std::fmt::Display for Name {
3519 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result { 3544 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
3520 std::fmt::Display::fmt(self.syntax(), f) 3545 std::fmt::Display::fmt(self.syntax(), f)
3521 } 3546 }
3522} 3547}
3523impl std::fmt::Display for Name { 3548impl std::fmt::Display for ItemList {
3549 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
3550 std::fmt::Display::fmt(self.syntax(), f)
3551 }
3552}
3553impl std::fmt::Display for Abi {
3524 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result { 3554 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
3525 std::fmt::Display::fmt(self.syntax(), f) 3555 std::fmt::Display::fmt(self.syntax(), f)
3526 } 3556 }
@@ -3585,7 +3615,7 @@ impl std::fmt::Display for TypeBoundList {
3585 std::fmt::Display::fmt(self.syntax(), f) 3615 std::fmt::Display::fmt(self.syntax(), f)
3586 } 3616 }
3587} 3617}
3588impl std::fmt::Display for ItemList { 3618impl std::fmt::Display for AssocItemList {
3589 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result { 3619 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
3590 std::fmt::Display::fmt(self.syntax(), f) 3620 std::fmt::Display::fmt(self.syntax(), f)
3591 } 3621 }
@@ -4010,7 +4040,7 @@ impl std::fmt::Display for UseTreeList {
4010 std::fmt::Display::fmt(self.syntax(), f) 4040 std::fmt::Display::fmt(self.syntax(), f)
4011 } 4041 }
4012} 4042}
4013impl std::fmt::Display for Alias { 4043impl std::fmt::Display for Rename {
4014 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result { 4044 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
4015 std::fmt::Display::fmt(self.syntax(), f) 4045 std::fmt::Display::fmt(self.syntax(), f)
4016 } 4046 }
diff --git a/crates/ra_syntax/src/ast/make.rs b/crates/ra_syntax/src/ast/make.rs
index 192c610f1..2b05ed2d4 100644
--- a/crates/ra_syntax/src/ast/make.rs
+++ b/crates/ra_syntax/src/ast/make.rs
@@ -37,7 +37,7 @@ fn path_from_text(text: &str) -> ast::Path {
37pub fn use_tree( 37pub fn use_tree(
38 path: ast::Path, 38 path: ast::Path,
39 use_tree_list: Option<ast::UseTreeList>, 39 use_tree_list: Option<ast::UseTreeList>,
40 alias: Option<ast::Alias>, 40 alias: Option<ast::Rename>,
41 add_star: bool, 41 add_star: bool,
42) -> ast::UseTree { 42) -> ast::UseTree {
43 let mut buf = "use ".to_string(); 43 let mut buf = "use ".to_string();
diff --git a/crates/ra_syntax/test_data/parser/err/0018_incomplete_fn.rast b/crates/ra_syntax/test_data/parser/err/0018_incomplete_fn.rast
index 31cc4e551..a87e5061a 100644
--- a/crates/ra_syntax/test_data/parser/err/0018_incomplete_fn.rast
+++ b/crates/ra_syntax/test_data/parser/err/0018_incomplete_fn.rast
@@ -8,7 +8,7 @@ [email protected]
8 [email protected] 8 [email protected]
9 [email protected] "FnScopes" 9 [email protected] "FnScopes"
10 [email protected] " " 10 [email protected] " "
11 [email protected] 11 ASSOC_[email protected]
12 [email protected] "{" 12 [email protected] "{"
13 [email protected] "\n " 13 [email protected] "\n "
14 [email protected] 14 [email protected]
diff --git a/crates/ra_syntax/test_data/parser/err/0026_imp_recovery.rast b/crates/ra_syntax/test_data/parser/err/0026_imp_recovery.rast
index bf07409fb..254ff546a 100644
--- a/crates/ra_syntax/test_data/parser/err/0026_imp_recovery.rast
+++ b/crates/ra_syntax/test_data/parser/err/0026_imp_recovery.rast
@@ -41,7 +41,7 @@ [email protected]
41 [email protected] "T" 41 [email protected] "T"
42 [email protected] ">" 42 [email protected] ">"
43 [email protected] " " 43 [email protected] " "
44 [email protected] 44 ASSOC_[email protected]
45 [email protected] "{" 45 [email protected] "{"
46 [email protected] "}" 46 [email protected] "}"
47 [email protected] "\n" 47 [email protected] "\n"
diff --git a/crates/ra_syntax/test_data/parser/err/0037_visibility_in_traits.rast b/crates/ra_syntax/test_data/parser/err/0037_visibility_in_traits.rast
index e3cda7c43..bc446e3df 100644
--- a/crates/ra_syntax/test_data/parser/err/0037_visibility_in_traits.rast
+++ b/crates/ra_syntax/test_data/parser/err/0037_visibility_in_traits.rast
@@ -14,7 +14,7 @@ [email protected]
14 [email protected] "(" 14 [email protected] "("
15 [email protected] ")" 15 [email protected] ")"
16 [email protected] " " 16 [email protected] " "
17 [email protected] 17 ASSOC_[email protected]
18 [email protected] "{" 18 [email protected] "{"
19 [email protected] "\n " 19 [email protected] "\n "
20 [email protected] 20 [email protected]
diff --git a/crates/ra_syntax/test_data/parser/err/0043_default_const.rast b/crates/ra_syntax/test_data/parser/err/0043_default_const.rast
index 8eb583ef8..6ca1a4870 100644
--- a/crates/ra_syntax/test_data/parser/err/0043_default_const.rast
+++ b/crates/ra_syntax/test_data/parser/err/0043_default_const.rast
@@ -5,7 +5,7 @@ [email protected]
5 [email protected] 5 [email protected]
6 [email protected] "T" 6 [email protected] "T"
7 [email protected] " " 7 [email protected] " "
8 [email protected] 8 ASSOC_[email protected]
9 [email protected] "{" 9 [email protected] "{"
10 [email protected] "\n " 10 [email protected] "\n "
11 [email protected] 11 [email protected]
diff --git a/crates/ra_syntax/test_data/parser/inline/err/0004_impl_type.rast b/crates/ra_syntax/test_data/parser/inline/err/0004_impl_type.rast
index fd939be8d..2d0253aa0 100644
--- a/crates/ra_syntax/test_data/parser/inline/err/0004_impl_type.rast
+++ b/crates/ra_syntax/test_data/parser/inline/err/0004_impl_type.rast
@@ -8,7 +8,7 @@ [email protected]
8 [email protected] 8 [email protected]
9 [email protected] "Type" 9 [email protected] "Type"
10 [email protected] " " 10 [email protected] " "
11 [email protected] 11 ASSOC_[email protected]
12 [email protected] "{" 12 [email protected] "{"
13 [email protected] "}" 13 [email protected] "}"
14 [email protected] "\n" 14 [email protected] "\n"
@@ -29,7 +29,7 @@ [email protected]
29 [email protected] 29 [email protected]
30 [email protected] "T" 30 [email protected] "T"
31 [email protected] " " 31 [email protected] " "
32 [email protected] 32 ASSOC_[email protected]
33 [email protected] "{" 33 [email protected] "{"
34 [email protected] "}" 34 [email protected] "}"
35 [email protected] "\n" 35 [email protected] "\n"
@@ -45,7 +45,7 @@ [email protected]
45 [email protected] 45 [email protected]
46 [email protected] "NotType" 46 [email protected] "NotType"
47 [email protected] " " 47 [email protected] " "
48 [email protected] 48 ASSOC_[email protected]
49 [email protected] "{" 49 [email protected] "{"
50 [email protected] "}" 50 [email protected] "}"
51 [email protected] "\n" 51 [email protected] "\n"
@@ -69,7 +69,7 @@ [email protected]
69 [email protected] 69 [email protected]
70 [email protected] "NotType" 70 [email protected] "NotType"
71 [email protected] " " 71 [email protected] " "
72 [email protected] 72 ASSOC_[email protected]
73 [email protected] "{" 73 [email protected] "{"
74 [email protected] "}" 74 [email protected] "}"
75 [email protected] "\n" 75 [email protected] "\n"
diff --git a/crates/ra_syntax/test_data/parser/inline/err/0014_default_fn_type.rast b/crates/ra_syntax/test_data/parser/inline/err/0014_default_fn_type.rast
index b8cd0587d..5501dc5a6 100644
--- a/crates/ra_syntax/test_data/parser/inline/err/0014_default_fn_type.rast
+++ b/crates/ra_syntax/test_data/parser/inline/err/0014_default_fn_type.rast
@@ -5,7 +5,7 @@ [email protected]
5 [email protected] 5 [email protected]
6 [email protected] "T" 6 [email protected] "T"
7 [email protected] " " 7 [email protected] " "
8 [email protected] 8 ASSOC_[email protected]
9 [email protected] "{" 9 [email protected] "{"
10 [email protected] "\n " 10 [email protected] "\n "
11 [email protected] 11 [email protected]
diff --git a/crates/ra_syntax/test_data/parser/inline/ok/0001_trait_item_list.rast b/crates/ra_syntax/test_data/parser/inline/ok/0001_trait_item_list.rast
index a38b4f573..f422acdda 100644
--- a/crates/ra_syntax/test_data/parser/inline/ok/0001_trait_item_list.rast
+++ b/crates/ra_syntax/test_data/parser/inline/ok/0001_trait_item_list.rast
@@ -8,7 +8,7 @@ [email protected]
8 [email protected] 8 [email protected]
9 [email protected] "F" 9 [email protected] "F"
10 [email protected] " " 10 [email protected] " "
11 [email protected] 11 ASSOC_[email protected]
12 [email protected] "{" 12 [email protected] "{"
13 [email protected] "\n " 13 [email protected] "\n "
14 [email protected] 14 [email protected]
diff --git a/crates/ra_syntax/test_data/parser/inline/ok/0006_self_param.rast b/crates/ra_syntax/test_data/parser/inline/ok/0006_self_param.rast
index 9f4a9e69b..0cd1dffc9 100644
--- a/crates/ra_syntax/test_data/parser/inline/ok/0006_self_param.rast
+++ b/crates/ra_syntax/test_data/parser/inline/ok/0006_self_param.rast
@@ -8,7 +8,7 @@ [email protected]
8 [email protected] 8 [email protected]
9 [email protected] "S" 9 [email protected] "S"
10 [email protected] " " 10 [email protected] " "
11 [email protected] 11 ASSOC_[email protected]
12 [email protected] "{" 12 [email protected] "{"
13 [email protected] "\n " 13 [email protected] "\n "
14 [email protected] 14 [email protected]
diff --git a/crates/ra_syntax/test_data/parser/inline/ok/0016_unsafe_trait.rast b/crates/ra_syntax/test_data/parser/inline/ok/0016_unsafe_trait.rast
index d59c6006d..69b82e33c 100644
--- a/crates/ra_syntax/test_data/parser/inline/ok/0016_unsafe_trait.rast
+++ b/crates/ra_syntax/test_data/parser/inline/ok/0016_unsafe_trait.rast
@@ -7,7 +7,7 @@ [email protected]
7 [email protected] 7 [email protected]
8 [email protected] "T" 8 [email protected] "T"
9 [email protected] " " 9 [email protected] " "
10 [email protected] 10 ASSOC_[email protected]
11 [email protected] "{" 11 [email protected] "{"
12 [email protected] "}" 12 [email protected] "}"
13 [email protected] "\n" 13 [email protected] "\n"
diff --git a/crates/ra_syntax/test_data/parser/inline/ok/0018_arb_self_types.rast b/crates/ra_syntax/test_data/parser/inline/ok/0018_arb_self_types.rast
index 15da6fdd6..79148e953 100644
--- a/crates/ra_syntax/test_data/parser/inline/ok/0018_arb_self_types.rast
+++ b/crates/ra_syntax/test_data/parser/inline/ok/0018_arb_self_types.rast
@@ -8,7 +8,7 @@ [email protected]
8 [email protected] 8 [email protected]
9 [email protected] "S" 9 [email protected] "S"
10 [email protected] " " 10 [email protected] " "
11 [email protected] 11 ASSOC_[email protected]
12 [email protected] "{" 12 [email protected] "{"
13 [email protected] "\n " 13 [email protected] "\n "
14 [email protected] 14 [email protected]
diff --git a/crates/ra_syntax/test_data/parser/inline/ok/0021_impl_item_list.rast b/crates/ra_syntax/test_data/parser/inline/ok/0021_impl_item_list.rast
index c204aeb63..31b5b6616 100644
--- a/crates/ra_syntax/test_data/parser/inline/ok/0021_impl_item_list.rast
+++ b/crates/ra_syntax/test_data/parser/inline/ok/0021_impl_item_list.rast
@@ -8,7 +8,7 @@ [email protected]
8 [email protected] 8 [email protected]
9 [email protected] "F" 9 [email protected] "F"
10 [email protected] " " 10 [email protected] " "
11 [email protected] 11 ASSOC_[email protected]
12 [email protected] "{" 12 [email protected] "{"
13 [email protected] "\n " 13 [email protected] "\n "
14 [email protected] 14 [email protected]
diff --git a/crates/ra_syntax/test_data/parser/inline/ok/0041_trait_item.rast b/crates/ra_syntax/test_data/parser/inline/ok/0041_trait_item.rast
index 1ae791361..884ab2dbf 100644
--- a/crates/ra_syntax/test_data/parser/inline/ok/0041_trait_item.rast
+++ b/crates/ra_syntax/test_data/parser/inline/ok/0041_trait_item.rast
@@ -48,7 +48,7 @@ [email protected]
48 [email protected] 48 [email protected]
49 [email protected] "Copy" 49 [email protected] "Copy"
50 [email protected] " " 50 [email protected] " "
51 [email protected] 51 ASSOC_[email protected]
52 [email protected] "{" 52 [email protected] "{"
53 [email protected] "}" 53 [email protected] "}"
54 [email protected] "\n" 54 [email protected] "\n"
@@ -119,7 +119,7 @@ [email protected]
119 [email protected] 119 [email protected]
120 [email protected] "Copy" 120 [email protected] "Copy"
121 [email protected] " " 121 [email protected] " "
122 [email protected] 122 ASSOC_[email protected]
123 [email protected] "{" 123 [email protected] "{"
124 [email protected] "}" 124 [email protected] "}"
125 [email protected] "\n" 125 [email protected] "\n"
diff --git a/crates/ra_syntax/test_data/parser/inline/ok/0043_use_alias.rast b/crates/ra_syntax/test_data/parser/inline/ok/0043_use_alias.rast
index f0e09d40d..8e9061e1d 100644
--- a/crates/ra_syntax/test_data/parser/inline/ok/0043_use_alias.rast
+++ b/crates/ra_syntax/test_data/parser/inline/ok/0043_use_alias.rast
@@ -13,7 +13,7 @@ [email protected]
13 [email protected] 13 [email protected]
14 [email protected] "path" 14 [email protected] "path"
15 [email protected] " " 15 [email protected] " "
16 ALIAS@15..27 16 RENAME@15..27
17 [email protected] "as" 17 [email protected] "as"
18 [email protected] " " 18 [email protected] " "
19 [email protected] 19 [email protected]
@@ -43,7 +43,7 @@ [email protected]
43 [email protected] 43 [email protected]
44 [email protected] "path" 44 [email protected] "path"
45 [email protected] " " 45 [email protected] " "
46 ALIAS@54..72 46 RENAME@54..72
47 [email protected] "as" 47 [email protected] "as"
48 [email protected] " " 48 [email protected] " "
49 [email protected] 49 [email protected]
@@ -61,7 +61,7 @@ [email protected]
61 [email protected] 61 [email protected]
62 [email protected] "path" 62 [email protected] "path"
63 [email protected] " " 63 [email protected] " "
64 ALIAS@91..108 64 RENAME@91..108
65 [email protected] "as" 65 [email protected] "as"
66 [email protected] " " 66 [email protected] " "
67 [email protected] 67 [email protected]
@@ -130,7 +130,7 @@ [email protected]
130 [email protected] 130 [email protected]
131 [email protected] "Trait" 131 [email protected] "Trait"
132 [email protected] " " 132 [email protected] " "
133 ALIAS@192..196 133 RENAME@192..196
134 [email protected] "as" 134 [email protected] "as"
135 [email protected] " " 135 [email protected] " "
136 [email protected] "_" 136 [email protected] "_"
diff --git a/crates/ra_syntax/test_data/parser/inline/ok/0047_unsafe_default_impl.rast b/crates/ra_syntax/test_data/parser/inline/ok/0047_unsafe_default_impl.rast
index 52de6023b..8a6b5a8fc 100644
--- a/crates/ra_syntax/test_data/parser/inline/ok/0047_unsafe_default_impl.rast
+++ b/crates/ra_syntax/test_data/parser/inline/ok/0047_unsafe_default_impl.rast
@@ -12,7 +12,7 @@ [email protected]
12 [email protected] 12 [email protected]
13 [email protected] "Foo" 13 [email protected] "Foo"
14 [email protected] " " 14 [email protected] " "
15 [email protected] 15 ASSOC_[email protected]
16 [email protected] "{" 16 [email protected] "{"
17 [email protected] "}" 17 [email protected] "}"
18 [email protected] "\n" 18 [email protected] "\n"
diff --git a/crates/ra_syntax/test_data/parser/inline/ok/0050_fn_decl.rast b/crates/ra_syntax/test_data/parser/inline/ok/0050_fn_decl.rast
index 8bf62cda9..5f1429102 100644
--- a/crates/ra_syntax/test_data/parser/inline/ok/0050_fn_decl.rast
+++ b/crates/ra_syntax/test_data/parser/inline/ok/0050_fn_decl.rast
@@ -5,7 +5,7 @@ [email protected]
5 [email protected] 5 [email protected]
6 [email protected] "T" 6 [email protected] "T"
7 [email protected] " " 7 [email protected] " "
8 [email protected] 8 ASSOC_[email protected]
9 [email protected] "{" 9 [email protected] "{"
10 [email protected] " " 10 [email protected] " "
11 [email protected] 11 [email protected]
diff --git a/crates/ra_syntax/test_data/parser/inline/ok/0063_impl_def_neg.rast b/crates/ra_syntax/test_data/parser/inline/ok/0063_impl_def_neg.rast
index 24b9a1f46..31178f86e 100644
--- a/crates/ra_syntax/test_data/parser/inline/ok/0063_impl_def_neg.rast
+++ b/crates/ra_syntax/test_data/parser/inline/ok/0063_impl_def_neg.rast
@@ -17,7 +17,7 @@ [email protected]
17 [email protected] 17 [email protected]
18 [email protected] "X" 18 [email protected] "X"
19 [email protected] " " 19 [email protected] " "
20 [email protected] 20 ASSOC_[email protected]
21 [email protected] "{" 21 [email protected] "{"
22 [email protected] "}" 22 [email protected] "}"
23 [email protected] "\n" 23 [email protected] "\n"
diff --git a/crates/ra_syntax/test_data/parser/inline/ok/0079_impl_def.rast b/crates/ra_syntax/test_data/parser/inline/ok/0079_impl_def.rast
index a00ab40f9..26825ef86 100644
--- a/crates/ra_syntax/test_data/parser/inline/ok/0079_impl_def.rast
+++ b/crates/ra_syntax/test_data/parser/inline/ok/0079_impl_def.rast
@@ -8,7 +8,7 @@ [email protected]
8 [email protected] 8 [email protected]
9 [email protected] "Foo" 9 [email protected] "Foo"
10 [email protected] " " 10 [email protected] " "
11 [email protected] 11 ASSOC_[email protected]
12 [email protected] "{" 12 [email protected] "{"
13 [email protected] "}" 13 [email protected] "}"
14 [email protected] "\n" 14 [email protected] "\n"
diff --git a/crates/ra_syntax/test_data/parser/inline/ok/0087_unsafe_impl.rast b/crates/ra_syntax/test_data/parser/inline/ok/0087_unsafe_impl.rast
index 01ed3afca..e3223cee5 100644
--- a/crates/ra_syntax/test_data/parser/inline/ok/0087_unsafe_impl.rast
+++ b/crates/ra_syntax/test_data/parser/inline/ok/0087_unsafe_impl.rast
@@ -10,7 +10,7 @@ [email protected]
10 [email protected] 10 [email protected]
11 [email protected] "Foo" 11 [email protected] "Foo"
12 [email protected] " " 12 [email protected] " "
13 [email protected] 13 ASSOC_[email protected]
14 [email protected] "{" 14 [email protected] "{"
15 [email protected] "}" 15 [email protected] "}"
16 [email protected] "\n" 16 [email protected] "\n"
diff --git a/crates/ra_syntax/test_data/parser/inline/ok/0091_auto_trait.rast b/crates/ra_syntax/test_data/parser/inline/ok/0091_auto_trait.rast
index 800412cef..7efa4c34d 100644
--- a/crates/ra_syntax/test_data/parser/inline/ok/0091_auto_trait.rast
+++ b/crates/ra_syntax/test_data/parser/inline/ok/0091_auto_trait.rast
@@ -7,7 +7,7 @@ [email protected]
7 [email protected] 7 [email protected]
8 [email protected] "T" 8 [email protected] "T"
9 [email protected] " " 9 [email protected] " "
10 [email protected] 10 ASSOC_[email protected]
11 [email protected] "{" 11 [email protected] "{"
12 [email protected] "}" 12 [email protected] "}"
13 [email protected] "\n" 13 [email protected] "\n"
diff --git a/crates/ra_syntax/test_data/parser/inline/ok/0094_unsafe_auto_trait.rast b/crates/ra_syntax/test_data/parser/inline/ok/0094_unsafe_auto_trait.rast
index 9370f6ae7..fad27be66 100644
--- a/crates/ra_syntax/test_data/parser/inline/ok/0094_unsafe_auto_trait.rast
+++ b/crates/ra_syntax/test_data/parser/inline/ok/0094_unsafe_auto_trait.rast
@@ -9,7 +9,7 @@ [email protected]
9 [email protected] 9 [email protected]
10 [email protected] "T" 10 [email protected] "T"
11 [email protected] " " 11 [email protected] " "
12 [email protected] 12 ASSOC_[email protected]
13 [email protected] "{" 13 [email protected] "{"
14 [email protected] "}" 14 [email protected] "}"
15 [email protected] "\n" 15 [email protected] "\n"
diff --git a/crates/ra_syntax/test_data/parser/inline/ok/0097_default_impl.rast b/crates/ra_syntax/test_data/parser/inline/ok/0097_default_impl.rast
index 80bda4ba7..8a839a4a6 100644
--- a/crates/ra_syntax/test_data/parser/inline/ok/0097_default_impl.rast
+++ b/crates/ra_syntax/test_data/parser/inline/ok/0097_default_impl.rast
@@ -10,7 +10,7 @@ [email protected]
10 [email protected] 10 [email protected]
11 [email protected] "Foo" 11 [email protected] "Foo"
12 [email protected] " " 12 [email protected] " "
13 [email protected] 13 ASSOC_[email protected]
14 [email protected] "{" 14 [email protected] "{"
15 [email protected] "}" 15 [email protected] "}"
16 [email protected] "\n" 16 [email protected] "\n"
diff --git a/crates/ra_syntax/test_data/parser/inline/ok/0118_impl_inner_attributes.rast b/crates/ra_syntax/test_data/parser/inline/ok/0118_impl_inner_attributes.rast
index a65a5c85f..ea54347fc 100644
--- a/crates/ra_syntax/test_data/parser/inline/ok/0118_impl_inner_attributes.rast
+++ b/crates/ra_syntax/test_data/parser/inline/ok/0118_impl_inner_attributes.rast
@@ -17,7 +17,7 @@ [email protected]
17 [email protected] 17 [email protected]
18 [email protected] "F" 18 [email protected] "F"
19 [email protected] " " 19 [email protected] " "
20 [email protected] 20 ASSOC_[email protected]
21 [email protected] "{" 21 [email protected] "{"
22 [email protected] "\n " 22 [email protected] "\n "
23 [email protected] "//! This is a doc com ..." 23 [email protected] "//! This is a doc com ..."
diff --git a/crates/ra_syntax/test_data/parser/inline/ok/0132_default_fn_type.rast b/crates/ra_syntax/test_data/parser/inline/ok/0132_default_fn_type.rast
index 00ce5ecf0..3772cb64b 100644
--- a/crates/ra_syntax/test_data/parser/inline/ok/0132_default_fn_type.rast
+++ b/crates/ra_syntax/test_data/parser/inline/ok/0132_default_fn_type.rast
@@ -16,7 +16,7 @@ [email protected]
16 [email protected] 16 [email protected]
17 [email protected] "Foo" 17 [email protected] "Foo"
18 [email protected] " " 18 [email protected] " "
19 [email protected] 19 ASSOC_[email protected]
20 [email protected] "{" 20 [email protected] "{"
21 [email protected] "\n " 21 [email protected] "\n "
22 [email protected] 22 [email protected]
diff --git a/crates/ra_syntax/test_data/parser/inline/ok/0150_impl_type_params.rast b/crates/ra_syntax/test_data/parser/inline/ok/0150_impl_type_params.rast
index e70c3b710..77e12cad6 100644
--- a/crates/ra_syntax/test_data/parser/inline/ok/0150_impl_type_params.rast
+++ b/crates/ra_syntax/test_data/parser/inline/ok/0150_impl_type_params.rast
@@ -32,7 +32,7 @@ [email protected]
32 [email protected] "N" 32 [email protected] "N"
33 [email protected] ">" 33 [email protected] ">"
34 [email protected] " " 34 [email protected] " "
35 [email protected] 35 ASSOC_[email protected]
36 [email protected] "{" 36 [email protected] "{"
37 [email protected] "}" 37 [email protected] "}"
38 [email protected] "\n" 38 [email protected] "\n"
diff --git a/crates/ra_syntax/test_data/parser/inline/ok/0163_default_unsafe_fn.rast b/crates/ra_syntax/test_data/parser/inline/ok/0163_default_unsafe_fn.rast
index adb6159f4..c0b8c0300 100644
--- a/crates/ra_syntax/test_data/parser/inline/ok/0163_default_unsafe_fn.rast
+++ b/crates/ra_syntax/test_data/parser/inline/ok/0163_default_unsafe_fn.rast
@@ -16,7 +16,7 @@ [email protected]
16 [email protected] 16 [email protected]
17 [email protected] "Foo" 17 [email protected] "Foo"
18 [email protected] " " 18 [email protected] " "
19 [email protected] 19 ASSOC_[email protected]
20 [email protected] "{" 20 [email protected] "{"
21 [email protected] "\n " 21 [email protected] "\n "
22 [email protected] 22 [email protected]
diff --git a/crates/ra_syntax/test_data/parser/inline/ok/0163_default_unsafe_impl.rast b/crates/ra_syntax/test_data/parser/inline/ok/0163_default_unsafe_impl.rast
index a9eda5668..e0c338297 100644
--- a/crates/ra_syntax/test_data/parser/inline/ok/0163_default_unsafe_impl.rast
+++ b/crates/ra_syntax/test_data/parser/inline/ok/0163_default_unsafe_impl.rast
@@ -12,7 +12,7 @@ [email protected]
12 [email protected] 12 [email protected]
13 [email protected] "Foo" 13 [email protected] "Foo"
14 [email protected] " " 14 [email protected] " "
15 [email protected] 15 ASSOC_[email protected]
16 [email protected] "{" 16 [email protected] "{"
17 [email protected] "}" 17 [email protected] "}"
18 [email protected] "\n" 18 [email protected] "\n"
diff --git a/crates/ra_syntax/test_data/parser/ok/0007_extern_crate.rast b/crates/ra_syntax/test_data/parser/ok/0007_extern_crate.rast
index 271486605..948c4ddb3 100644
--- a/crates/ra_syntax/test_data/parser/ok/0007_extern_crate.rast
+++ b/crates/ra_syntax/test_data/parser/ok/0007_extern_crate.rast
@@ -16,7 +16,7 @@ [email protected]
16 [email protected] 16 [email protected]
17 [email protected] "foo" 17 [email protected] "foo"
18 [email protected] " " 18 [email protected] " "
19 ALIAS@35..41 19 RENAME@35..41
20 [email protected] "as" 20 [email protected] "as"
21 [email protected] " " 21 [email protected] " "
22 [email protected] 22 [email protected]
@@ -30,7 +30,7 @@ [email protected]
30 [email protected] " " 30 [email protected] " "
31 [email protected] "self" 31 [email protected] "self"
32 [email protected] " " 32 [email protected] " "
33 ALIAS@61..67 33 RENAME@61..67
34 [email protected] "as" 34 [email protected] "as"
35 [email protected] " " 35 [email protected] " "
36 [email protected] 36 [email protected]
diff --git a/crates/ra_syntax/test_data/parser/ok/0015_use_tree.rast b/crates/ra_syntax/test_data/parser/ok/0015_use_tree.rast
index 09e0050f0..cdddb4214 100644
--- a/crates/ra_syntax/test_data/parser/ok/0015_use_tree.rast
+++ b/crates/ra_syntax/test_data/parser/ok/0015_use_tree.rast
@@ -8,7 +8,7 @@ [email protected]
8 [email protected] 8 [email protected]
9 [email protected] "foo" 9 [email protected] "foo"
10 [email protected] " " 10 [email protected] " "
11 ALIAS@8..14 11 RENAME@8..14
12 [email protected] "as" 12 [email protected] "as"
13 [email protected] " " 13 [email protected] " "
14 [email protected] 14 [email protected]
@@ -32,7 +32,7 @@ [email protected]
32 [email protected] 32 [email protected]
33 [email protected] "a" 33 [email protected] "a"
34 [email protected] " " 34 [email protected] " "
35 ALIAS@28..32 35 RENAME@28..32
36 [email protected] "as" 36 [email protected] "as"
37 [email protected] " " 37 [email protected] " "
38 [email protected] 38 [email protected]
@@ -55,7 +55,7 @@ [email protected]
55 [email protected] 55 [email protected]
56 [email protected] "foo" 56 [email protected] "foo"
57 [email protected] " " 57 [email protected] " "
58 ALIAS@48..52 58 RENAME@48..52
59 [email protected] "as" 59 [email protected] "as"
60 [email protected] " " 60 [email protected] " "
61 [email protected] 61 [email protected]
diff --git a/crates/ra_syntax/test_data/parser/ok/0030_traits.rast b/crates/ra_syntax/test_data/parser/ok/0030_traits.rast
index 0aadc11a4..63693de4f 100644
--- a/crates/ra_syntax/test_data/parser/ok/0030_traits.rast
+++ b/crates/ra_syntax/test_data/parser/ok/0030_traits.rast
@@ -5,7 +5,7 @@ [email protected]
5 [email protected] 5 [email protected]
6 [email protected] "Runnable" 6 [email protected] "Runnable"
7 [email protected] " " 7 [email protected] " "
8 [email protected] 8 ASSOC_[email protected]
9 [email protected] "{" 9 [email protected] "{"
10 [email protected] "\n " 10 [email protected] "\n "
11 [email protected] 11 [email protected]
@@ -26,7 +26,7 @@ [email protected]
26 [email protected] 26 [email protected]
27 [email protected] "TraitWithExpr" 27 [email protected] "TraitWithExpr"
28 [email protected] " " 28 [email protected] " "
29 [email protected] 29 ASSOC_[email protected]
30 [email protected] "{" 30 [email protected] "{"
31 [email protected] "\n " 31 [email protected] "\n "
32 [email protected] 32 [email protected]
diff --git a/crates/ra_syntax/test_data/parser/ok/0042_ufcs_call_list.rast b/crates/ra_syntax/test_data/parser/ok/0042_ufcs_call_list.rast
index 468982b74..573edc081 100644
--- a/crates/ra_syntax/test_data/parser/ok/0042_ufcs_call_list.rast
+++ b/crates/ra_syntax/test_data/parser/ok/0042_ufcs_call_list.rast
@@ -17,7 +17,7 @@ [email protected]
17 [email protected] 17 [email protected]
18 [email protected] "Foo" 18 [email protected] "Foo"
19 [email protected] " " 19 [email protected] " "
20 [email protected] 20 ASSOC_[email protected]
21 [email protected] "{" 21 [email protected] "{"
22 [email protected] "\n " 22 [email protected] "\n "
23 [email protected] 23 [email protected]
diff --git a/crates/ra_syntax/test_data/parser/ok/0045_block_inner_attrs.rast b/crates/ra_syntax/test_data/parser/ok/0045_block_inner_attrs.rast
index e8b095251..69aa0ba4d 100644
--- a/crates/ra_syntax/test_data/parser/ok/0045_block_inner_attrs.rast
+++ b/crates/ra_syntax/test_data/parser/ok/0045_block_inner_attrs.rast
@@ -98,7 +98,7 @@ [email protected]
98 [email protected] 98 [email protected]
99 [email protected] "Whatever" 99 [email protected] "Whatever"
100 [email protected] " " 100 [email protected] " "
101 [email protected] 101 ASSOC_[email protected]
102 [email protected] "{" 102 [email protected] "{"
103 [email protected] "\n " 103 [email protected] "\n "
104 [email protected] 104 [email protected]
diff --git a/crates/ra_syntax/test_data/parser/ok/0051_parameter_attrs.rast b/crates/ra_syntax/test_data/parser/ok/0051_parameter_attrs.rast
index 816740a7c..919c690de 100644
--- a/crates/ra_syntax/test_data/parser/ok/0051_parameter_attrs.rast
+++ b/crates/ra_syntax/test_data/parser/ok/0051_parameter_attrs.rast
@@ -192,7 +192,7 @@ [email protected]
192 [email protected] 192 [email protected]
193 [email protected] "Foo" 193 [email protected] "Foo"
194 [email protected] " " 194 [email protected] " "
195 [email protected] 195 ASSOC_[email protected]
196 [email protected] "{" 196 [email protected] "{"
197 [email protected] "\n " 197 [email protected] "\n "
198 [email protected] 198 [email protected]
@@ -260,7 +260,7 @@ [email protected]
260 [email protected] 260 [email protected]
261 [email protected] "S" 261 [email protected] "S"
262 [email protected] " " 262 [email protected] " "
263 [email protected] 263 ASSOC_[email protected]
264 [email protected] "{" 264 [email protected] "{"
265 [email protected] "\n " 265 [email protected] "\n "
266 [email protected] 266 [email protected]
diff --git a/crates/ra_syntax/test_data/parser/ok/0063_trait_fn_patterns.rast b/crates/ra_syntax/test_data/parser/ok/0063_trait_fn_patterns.rast
index 886b211d0..40619b46e 100644
--- a/crates/ra_syntax/test_data/parser/ok/0063_trait_fn_patterns.rast
+++ b/crates/ra_syntax/test_data/parser/ok/0063_trait_fn_patterns.rast
@@ -5,7 +5,7 @@ [email protected]
5 [email protected] 5 [email protected]
6 [email protected] "T" 6 [email protected] "T"
7 [email protected] " " 7 [email protected] " "
8 [email protected] 8 ASSOC_[email protected]
9 [email protected] "{" 9 [email protected] "{"
10 [email protected] "\n " 10 [email protected] "\n "
11 [email protected] 11 [email protected]
diff --git a/crates/ra_syntax/test_data/parser/ok/0064_impl_fn_params.rast b/crates/ra_syntax/test_data/parser/ok/0064_impl_fn_params.rast
index a0423806c..7b026e33b 100644
--- a/crates/ra_syntax/test_data/parser/ok/0064_impl_fn_params.rast
+++ b/crates/ra_syntax/test_data/parser/ok/0064_impl_fn_params.rast
@@ -8,7 +8,7 @@ [email protected]
8 [email protected] 8 [email protected]
9 [email protected] "U" 9 [email protected] "U"
10 [email protected] " " 10 [email protected] " "
11 [email protected] 11 ASSOC_[email protected]
12 [email protected] "{" 12 [email protected] "{"
13 [email protected] "\n " 13 [email protected] "\n "
14 [email protected] 14 [email protected]
diff --git a/crates/ra_syntax/test_data/parser/ok/0066_default_const.rast b/crates/ra_syntax/test_data/parser/ok/0066_default_const.rast
index dab0247ee..584b2faf1 100644
--- a/crates/ra_syntax/test_data/parser/ok/0066_default_const.rast
+++ b/crates/ra_syntax/test_data/parser/ok/0066_default_const.rast
@@ -16,7 +16,7 @@ [email protected]
16 [email protected] 16 [email protected]
17 [email protected] "Foo" 17 [email protected] "Foo"
18 [email protected] " " 18 [email protected] " "
19 [email protected] 19 ASSOC_[email protected]
20 [email protected] "{" 20 [email protected] "{"
21 [email protected] "\n " 21 [email protected] "\n "
22 [email protected] 22 [email protected]