diff options
Diffstat (limited to 'crates/ra_syntax/src/ast/traits.rs')
-rw-r--r-- | crates/ra_syntax/src/ast/traits.rs | 12 |
1 files changed, 3 insertions, 9 deletions
diff --git a/crates/ra_syntax/src/ast/traits.rs b/crates/ra_syntax/src/ast/traits.rs index a8f2454fd..3a56b1674 100644 --- a/crates/ra_syntax/src/ast/traits.rs +++ b/crates/ra_syntax/src/ast/traits.rs | |||
@@ -9,12 +9,6 @@ use crate::{ | |||
9 | SyntaxToken, T, | 9 | SyntaxToken, T, |
10 | }; | 10 | }; |
11 | 11 | ||
12 | pub trait TypeAscriptionOwner: AstNode { | ||
13 | fn ascribed_type(&self) -> Option<ast::TypeRef> { | ||
14 | support::child(self.syntax()) | ||
15 | } | ||
16 | } | ||
17 | |||
18 | pub trait NameOwner: AstNode { | 12 | pub trait NameOwner: AstNode { |
19 | fn name(&self) -> Option<ast::Name> { | 13 | fn name(&self) -> Option<ast::Name> { |
20 | support::child(self.syntax()) | 14 | support::child(self.syntax()) |
@@ -44,13 +38,13 @@ pub trait ArgListOwner: AstNode { | |||
44 | } | 38 | } |
45 | 39 | ||
46 | pub trait ModuleItemOwner: AstNode { | 40 | pub trait ModuleItemOwner: AstNode { |
47 | fn items(&self) -> AstChildren<ast::ModuleItem> { | 41 | fn items(&self) -> AstChildren<ast::Item> { |
48 | support::children(self.syntax()) | 42 | support::children(self.syntax()) |
49 | } | 43 | } |
50 | } | 44 | } |
51 | 45 | ||
52 | pub trait TypeParamsOwner: AstNode { | 46 | pub trait GenericParamsOwner: AstNode { |
53 | fn type_param_list(&self) -> Option<ast::TypeParamList> { | 47 | fn generic_param_list(&self) -> Option<ast::GenericParamList> { |
54 | support::child(self.syntax()) | 48 | support::child(self.syntax()) |
55 | } | 49 | } |
56 | 50 | ||