mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-09-29 05:15:04 +00:00
Save a bit on empty item trees by deduplicating them
This commit is contained in:
parent
3168ab5b99
commit
5548aecdca
8 changed files with 76 additions and 43 deletions
|
@ -1896,7 +1896,7 @@ impl InferenceContext<'_> {
|
|||
if let TyKind::FnDef(fn_def, parameters) = callable_ty.kind(Interner) {
|
||||
let def: CallableDefId = from_chalk(self.db, *fn_def);
|
||||
let generic_predicates =
|
||||
self.db.generic_predicates(GenericDefId::from(self.db.upcast(), def));
|
||||
self.db.generic_predicates(GenericDefId::from_callable(self.db.upcast(), def));
|
||||
for predicate in generic_predicates.iter() {
|
||||
let (predicate, binders) = predicate
|
||||
.clone()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue