mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-09-26 20:09:19 +00:00
visibility owner
This commit is contained in:
parent
d7ca7b8aac
commit
0a80d9685a
3 changed files with 64 additions and 4 deletions
|
@ -30,6 +30,12 @@ pub trait NameOwner<'a>: AstNode<'a> {
|
|||
}
|
||||
}
|
||||
|
||||
pub trait VisibilityOwner<'a>: AstNode<'a> {
|
||||
fn visibility(self) -> Option<Visibility<'a>> {
|
||||
child_opt(self)
|
||||
}
|
||||
}
|
||||
|
||||
pub trait LoopBodyOwner<'a>: AstNode<'a> {
|
||||
fn loop_body(self) -> Option<Block<'a>> {
|
||||
child_opt(self)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue