aboutsummaryrefslogtreecommitdiff
path: root/crates/ra_syntax/src/ast/traits.rs
diff options
context:
space:
mode:
Diffstat (limited to 'crates/ra_syntax/src/ast/traits.rs')
-rw-r--r--crates/ra_syntax/src/ast/traits.rs6
1 files changed, 6 insertions, 0 deletions
diff --git a/crates/ra_syntax/src/ast/traits.rs b/crates/ra_syntax/src/ast/traits.rs
index aaf07d731..1c90cf148 100644
--- a/crates/ra_syntax/src/ast/traits.rs
+++ b/crates/ra_syntax/src/ast/traits.rs
@@ -152,3 +152,9 @@ impl<'a> Iterator for CommentIter<'a> {
152 self.iter.by_ref().find_map(|el| el.as_token().and_then(ast::Comment::cast)) 152 self.iter.by_ref().find_map(|el| el.as_token().and_then(ast::Comment::cast))
153 } 153 }
154} 154}
155
156pub trait DefaultTypeParamOwner: AstNode {
157 fn default_type(&self) -> Option<&ast::PathType> {
158 child_opt(self)
159 }
160}