mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-09-27 12:29:21 +00:00
Use chalk_ir::AssocTypeId
This commit is contained in:
parent
dfafcd926a
commit
19664e276a
10 changed files with 87 additions and 76 deletions
|
@ -18,6 +18,7 @@ use crate::{
|
|||
lower::lower_to_chalk_mutability,
|
||||
method_resolution, op,
|
||||
primitive::{self, UintTy},
|
||||
to_assoc_type_id,
|
||||
traits::{FnTrait, InEnvironment},
|
||||
utils::{generics, variant_data, Generics},
|
||||
AdtId, Binders, CallableDefId, FnPointer, FnSig, Interner, Obligation, OpaqueTyId, Rawness,
|
||||
|
@ -97,8 +98,10 @@ impl<'a> InferenceContext<'a> {
|
|||
});
|
||||
if self.db.trait_solve(krate, goal.value).is_some() {
|
||||
self.obligations.push(implements_fn_trait);
|
||||
let output_proj_ty =
|
||||
crate::ProjectionTy { associated_ty: output_assoc_type, parameters: substs };
|
||||
let output_proj_ty = crate::ProjectionTy {
|
||||
associated_ty: to_assoc_type_id(output_assoc_type),
|
||||
parameters: substs,
|
||||
};
|
||||
let return_ty = self.normalize_projection_ty(output_proj_ty);
|
||||
Some((arg_tys, return_ty))
|
||||
} else {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue