mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-09-30 22:01:37 +00:00
Substitution::prefix -> subst_prefix
I probably want to get rid of this function completely later.
This commit is contained in:
parent
2a83645e1b
commit
b67148daea
4 changed files with 15 additions and 11 deletions
|
@ -964,8 +964,10 @@ impl<'a> InferenceContext<'a> {
|
|||
if let AssocContainerId::TraitId(trait_) = f.lookup(self.db.upcast()).container
|
||||
{
|
||||
// construct a TraitRef
|
||||
let substs =
|
||||
parameters.prefix(generics(self.db.upcast(), trait_.into()).len());
|
||||
let substs = crate::subst_prefix(
|
||||
&*parameters,
|
||||
generics(self.db.upcast(), trait_.into()).len(),
|
||||
);
|
||||
self.push_obligation(
|
||||
TraitRef { trait_id: to_chalk_trait_id(trait_), substitution: substs }
|
||||
.cast(&Interner),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue