add comment to visit_ct_substs
This commit is contained in:
parent
71d7550350
commit
806c7281ec
2 changed files with 6 additions and 3 deletions
|
@ -881,9 +881,7 @@ impl TypeRelation<'tcx> for ConstInferUnifier<'_, 'tcx> {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
ty::Infer(ty::IntVar(_) | ty::FloatVar(_)) => {
|
ty::Infer(ty::IntVar(_) | ty::FloatVar(_)) => Ok(t),
|
||||||
Ok(t)
|
|
||||||
}
|
|
||||||
_ => relate::super_relate_tys(self, t, t),
|
_ => relate::super_relate_tys(self, t, t),
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -33,6 +33,11 @@ pub trait TypeRelation<'tcx>: Sized {
|
||||||
/// relation. Just affects error messages.
|
/// relation. Just affects error messages.
|
||||||
fn a_is_expected(&self) -> bool;
|
fn a_is_expected(&self) -> bool;
|
||||||
|
|
||||||
|
/// Whether we should look into the substs of unevaluated constants
|
||||||
|
/// even if `feature(const_evaluatable_checked)` is active.
|
||||||
|
///
|
||||||
|
/// This is needed in `combine` to prevent accidentially creating
|
||||||
|
/// infinite types as we abuse `TypeRelation` to walk a type there.
|
||||||
fn visit_ct_substs(&self) -> bool {
|
fn visit_ct_substs(&self) -> bool {
|
||||||
false
|
false
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue