Fix wrong argument in autoderef process
This commit is contained in:
parent
ec1f28f961
commit
8d2f301283
1 changed files with 2 additions and 2 deletions
|
|
@ -114,10 +114,10 @@ impl<'a, 'tcx> Autoderef<'a, 'tcx> {
|
|||
|
||||
let tcx = self.infcx.tcx;
|
||||
|
||||
// <cur_ty as Deref>
|
||||
// <ty as Deref>
|
||||
let trait_ref = TraitRef {
|
||||
def_id: tcx.lang_items().deref_trait()?,
|
||||
substs: tcx.mk_substs_trait(self.cur_ty, &[]),
|
||||
substs: tcx.mk_substs_trait(ty, &[]),
|
||||
};
|
||||
|
||||
let cause = traits::ObligationCause::misc(self.span, self.body_id);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue