mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-09-28 21:05:02 +00:00
Add default type param in TypeParam Node
This commit is contained in:
parent
9901f3e45e
commit
9e4fee8b41
3 changed files with 8 additions and 1 deletions
|
@ -152,3 +152,9 @@ impl<'a> Iterator for CommentIter<'a> {
|
|||
self.iter.by_ref().find_map(|el| el.as_token().and_then(ast::Comment::cast))
|
||||
}
|
||||
}
|
||||
|
||||
pub trait DefaultTypeParamOwner: AstNode {
|
||||
fn default_type(&self) -> Option<&ast::PathType> {
|
||||
child_opt(self)
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue