diff options
author | Jeremy A. Kolb <[email protected]> | 2018-11-02 13:59:07 +0000 |
---|---|---|
committer | Aleksey Kladov <[email protected]> | 2018-11-07 15:24:55 +0000 |
commit | 6df71da81f9260890ac42ed992946543d697e57c (patch) | |
tree | 93bc22feff1cd602f2e50bbbb8761a1e0e064c45 | |
parent | 2e2445444abcde9fc2f50c70a8157958f7d5ddd8 (diff) |
Add some more DocCommentsOwner
-rw-r--r-- | crates/ra_syntax/src/ast/generated.rs | 7 | ||||
-rw-r--r-- | crates/ra_syntax/src/grammar.ron | 9 |
2 files changed, 14 insertions, 2 deletions
diff --git a/crates/ra_syntax/src/ast/generated.rs b/crates/ra_syntax/src/ast/generated.rs index 3878c99a8..8cf3222f7 100644 --- a/crates/ra_syntax/src/ast/generated.rs +++ b/crates/ra_syntax/src/ast/generated.rs | |||
@@ -608,6 +608,7 @@ impl<R: TreeRoot<RaTypes>> ConstDefNode<R> { | |||
608 | impl<'a> ast::NameOwner<'a> for ConstDef<'a> {} | 608 | impl<'a> ast::NameOwner<'a> for ConstDef<'a> {} |
609 | impl<'a> ast::TypeParamsOwner<'a> for ConstDef<'a> {} | 609 | impl<'a> ast::TypeParamsOwner<'a> for ConstDef<'a> {} |
610 | impl<'a> ast::AttrsOwner<'a> for ConstDef<'a> {} | 610 | impl<'a> ast::AttrsOwner<'a> for ConstDef<'a> {} |
611 | impl<'a> ast::DocCommentsOwner<'a> for ConstDef<'a> {} | ||
611 | impl<'a> ConstDef<'a> {} | 612 | impl<'a> ConstDef<'a> {} |
612 | 613 | ||
613 | // ContinueExpr | 614 | // ContinueExpr |
@@ -722,6 +723,7 @@ impl<R: TreeRoot<RaTypes>> EnumDefNode<R> { | |||
722 | impl<'a> ast::NameOwner<'a> for EnumDef<'a> {} | 723 | impl<'a> ast::NameOwner<'a> for EnumDef<'a> {} |
723 | impl<'a> ast::TypeParamsOwner<'a> for EnumDef<'a> {} | 724 | impl<'a> ast::TypeParamsOwner<'a> for EnumDef<'a> {} |
724 | impl<'a> ast::AttrsOwner<'a> for EnumDef<'a> {} | 725 | impl<'a> ast::AttrsOwner<'a> for EnumDef<'a> {} |
726 | impl<'a> ast::DocCommentsOwner<'a> for EnumDef<'a> {} | ||
725 | impl<'a> EnumDef<'a> {} | 727 | impl<'a> EnumDef<'a> {} |
726 | 728 | ||
727 | // Expr | 729 | // Expr |
@@ -1886,6 +1888,7 @@ impl<R: TreeRoot<RaTypes>> ModuleNode<R> { | |||
1886 | 1888 | ||
1887 | impl<'a> ast::NameOwner<'a> for Module<'a> {} | 1889 | impl<'a> ast::NameOwner<'a> for Module<'a> {} |
1888 | impl<'a> ast::AttrsOwner<'a> for Module<'a> {} | 1890 | impl<'a> ast::AttrsOwner<'a> for Module<'a> {} |
1891 | impl<'a> ast::DocCommentsOwner<'a> for Module<'a> {} | ||
1889 | impl<'a> Module<'a> { | 1892 | impl<'a> Module<'a> { |
1890 | pub fn item_list(self) -> Option<ItemList<'a>> { | 1893 | pub fn item_list(self) -> Option<ItemList<'a>> { |
1891 | super::child_opt(self) | 1894 | super::child_opt(self) |
@@ -3205,6 +3208,7 @@ impl<R: TreeRoot<RaTypes>> StaticDefNode<R> { | |||
3205 | impl<'a> ast::NameOwner<'a> for StaticDef<'a> {} | 3208 | impl<'a> ast::NameOwner<'a> for StaticDef<'a> {} |
3206 | impl<'a> ast::TypeParamsOwner<'a> for StaticDef<'a> {} | 3209 | impl<'a> ast::TypeParamsOwner<'a> for StaticDef<'a> {} |
3207 | impl<'a> ast::AttrsOwner<'a> for StaticDef<'a> {} | 3210 | impl<'a> ast::AttrsOwner<'a> for StaticDef<'a> {} |
3211 | impl<'a> ast::DocCommentsOwner<'a> for StaticDef<'a> {} | ||
3208 | impl<'a> StaticDef<'a> {} | 3212 | impl<'a> StaticDef<'a> {} |
3209 | 3213 | ||
3210 | // Stmt | 3214 | // Stmt |
@@ -3270,6 +3274,7 @@ impl<R: TreeRoot<RaTypes>> StructDefNode<R> { | |||
3270 | impl<'a> ast::NameOwner<'a> for StructDef<'a> {} | 3274 | impl<'a> ast::NameOwner<'a> for StructDef<'a> {} |
3271 | impl<'a> ast::TypeParamsOwner<'a> for StructDef<'a> {} | 3275 | impl<'a> ast::TypeParamsOwner<'a> for StructDef<'a> {} |
3272 | impl<'a> ast::AttrsOwner<'a> for StructDef<'a> {} | 3276 | impl<'a> ast::AttrsOwner<'a> for StructDef<'a> {} |
3277 | impl<'a> ast::DocCommentsOwner<'a> for StructDef<'a> {} | ||
3273 | impl<'a> StructDef<'a> { | 3278 | impl<'a> StructDef<'a> { |
3274 | pub fn fields(self) -> impl Iterator<Item = NamedFieldDef<'a>> + 'a { | 3279 | pub fn fields(self) -> impl Iterator<Item = NamedFieldDef<'a>> + 'a { |
3275 | super::children(self) | 3280 | super::children(self) |
@@ -3424,6 +3429,7 @@ impl<R: TreeRoot<RaTypes>> TraitDefNode<R> { | |||
3424 | 3429 | ||
3425 | impl<'a> ast::NameOwner<'a> for TraitDef<'a> {} | 3430 | impl<'a> ast::NameOwner<'a> for TraitDef<'a> {} |
3426 | impl<'a> ast::AttrsOwner<'a> for TraitDef<'a> {} | 3431 | impl<'a> ast::AttrsOwner<'a> for TraitDef<'a> {} |
3432 | impl<'a> ast::DocCommentsOwner<'a> for TraitDef<'a> {} | ||
3427 | impl<'a> TraitDef<'a> {} | 3433 | impl<'a> TraitDef<'a> {} |
3428 | 3434 | ||
3429 | // TryExpr | 3435 | // TryExpr |
@@ -3649,6 +3655,7 @@ impl<R: TreeRoot<RaTypes>> TypeDefNode<R> { | |||
3649 | impl<'a> ast::NameOwner<'a> for TypeDef<'a> {} | 3655 | impl<'a> ast::NameOwner<'a> for TypeDef<'a> {} |
3650 | impl<'a> ast::TypeParamsOwner<'a> for TypeDef<'a> {} | 3656 | impl<'a> ast::TypeParamsOwner<'a> for TypeDef<'a> {} |
3651 | impl<'a> ast::AttrsOwner<'a> for TypeDef<'a> {} | 3657 | impl<'a> ast::AttrsOwner<'a> for TypeDef<'a> {} |
3658 | impl<'a> ast::DocCommentsOwner<'a> for TypeDef<'a> {} | ||
3652 | impl<'a> TypeDef<'a> {} | 3659 | impl<'a> TypeDef<'a> {} |
3653 | 3660 | ||
3654 | // TypeParam | 3661 | // TypeParam |
diff --git a/crates/ra_syntax/src/grammar.ron b/crates/ra_syntax/src/grammar.ron index 2ed165c52..1fa25dc4d 100644 --- a/crates/ra_syntax/src/grammar.ron +++ b/crates/ra_syntax/src/grammar.ron | |||
@@ -260,6 +260,7 @@ Grammar( | |||
260 | "NameOwner", | 260 | "NameOwner", |
261 | "TypeParamsOwner", | 261 | "TypeParamsOwner", |
262 | "AttrsOwner", | 262 | "AttrsOwner", |
263 | "DocCommentsOwner" | ||
263 | ], | 264 | ], |
264 | collections: [ | 265 | collections: [ |
265 | ["fields", "NamedFieldDef"] | 266 | ["fields", "NamedFieldDef"] |
@@ -270,10 +271,11 @@ Grammar( | |||
270 | "NameOwner", | 271 | "NameOwner", |
271 | "TypeParamsOwner", | 272 | "TypeParamsOwner", |
272 | "AttrsOwner", | 273 | "AttrsOwner", |
274 | "DocCommentsOwner" | ||
273 | ] ), | 275 | ] ), |
274 | "TraitDef": ( traits: ["NameOwner", "AttrsOwner"] ), | 276 | "TraitDef": ( traits: ["NameOwner", "AttrsOwner", "DocCommentsOwner"] ), |
275 | "Module": ( | 277 | "Module": ( |
276 | traits: ["NameOwner", "AttrsOwner" ], | 278 | traits: ["NameOwner", "AttrsOwner", "DocCommentsOwner" ], |
277 | options: [ "ItemList" ] | 279 | options: [ "ItemList" ] |
278 | ), | 280 | ), |
279 | "ItemList": ( | 281 | "ItemList": ( |
@@ -283,16 +285,19 @@ Grammar( | |||
283 | "NameOwner", | 285 | "NameOwner", |
284 | "TypeParamsOwner", | 286 | "TypeParamsOwner", |
285 | "AttrsOwner", | 287 | "AttrsOwner", |
288 | "DocCommentsOwner" | ||
286 | ] ), | 289 | ] ), |
287 | "StaticDef": ( traits: [ | 290 | "StaticDef": ( traits: [ |
288 | "NameOwner", | 291 | "NameOwner", |
289 | "TypeParamsOwner", | 292 | "TypeParamsOwner", |
290 | "AttrsOwner", | 293 | "AttrsOwner", |
294 | "DocCommentsOwner" | ||
291 | ] ), | 295 | ] ), |
292 | "TypeDef": ( traits: [ | 296 | "TypeDef": ( traits: [ |
293 | "NameOwner", | 297 | "NameOwner", |
294 | "TypeParamsOwner", | 298 | "TypeParamsOwner", |
295 | "AttrsOwner", | 299 | "AttrsOwner", |
300 | "DocCommentsOwner" | ||
296 | ] ), | 301 | ] ), |
297 | "ImplItem": (), | 302 | "ImplItem": (), |
298 | 303 | ||