aboutsummaryrefslogtreecommitdiff
path: root/crates/ra_syntax/src/ast/traits.rs
diff options
context:
space:
mode:
authorZac Pullar-Strecker <[email protected]>2020-07-31 03:12:44 +0100
committerZac Pullar-Strecker <[email protected]>2020-07-31 03:12:44 +0100
commitf05d7b41a719d848844b054a16477b29d0f063c6 (patch)
tree0a8a0946e8aef2ce64d4c13d0035ba41cce2daf3 /crates/ra_syntax/src/ast/traits.rs
parent73ff610e41959e3e7c78a2b4b25b086883132956 (diff)
parent6b7cb8b5ab539fc4333ce34bc29bf77c976f232a (diff)
Merge remote-tracking branch 'upstream/master' into 503-hover-doc-links
Hasn't fixed tests yet.
Diffstat (limited to 'crates/ra_syntax/src/ast/traits.rs')
-rw-r--r--crates/ra_syntax/src/ast/traits.rs12
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
12pub trait TypeAscriptionOwner: AstNode {
13 fn ascribed_type(&self) -> Option<ast::TypeRef> {
14 support::child(self.syntax())
15 }
16}
17
18pub trait NameOwner: AstNode { 12pub 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
46pub trait ModuleItemOwner: AstNode { 40pub 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
52pub trait TypeParamsOwner: AstNode { 46pub 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