mirror of
https://github.com/rust-lang/rust-analyzer
synced 2025-01-13 05:38:46 +00:00
Refactor hir::Trait
's existing items_with_supertraits(…)
method based on new all_supertraits(…)
method
This commit is contained in:
parent
89a002ef9b
commit
5a9767b115
1 changed files with 1 additions and 2 deletions
|
@ -2714,8 +2714,7 @@ impl Trait {
|
|||
}
|
||||
|
||||
pub fn items_with_supertraits(self, db: &dyn HirDatabase) -> Vec<AssocItem> {
|
||||
let traits = all_super_traits(db.upcast(), self.into());
|
||||
traits.iter().flat_map(|tr| Trait::from(*tr).items(db)).collect()
|
||||
self.all_supertraits(db).into_iter().flat_map(|tr| tr.items(db)).collect()
|
||||
}
|
||||
|
||||
pub fn is_auto(self, db: &dyn HirDatabase) -> bool {
|
||||
|
|
Loading…
Reference in a new issue