remove InferCtxt::clear_caches
This commit is contained in:
parent
88b10c1162
commit
f9ba863c4d
2 changed files with 0 additions and 12 deletions
|
@ -1521,15 +1521,6 @@ impl<'tcx> InferCtxt<'tcx> {
|
|||
closure_kind_ty.to_opt_closure_kind()
|
||||
}
|
||||
|
||||
/// Clears the selection, evaluation, and projection caches. This is useful when
|
||||
/// repeatedly attempting to select an `Obligation` while changing only
|
||||
/// its `ParamEnv`, since `FulfillmentContext` doesn't use probing.
|
||||
pub fn clear_caches(&self) {
|
||||
self.selection_cache.clear();
|
||||
self.evaluation_cache.clear();
|
||||
self.inner.borrow_mut().projection_cache().clear();
|
||||
}
|
||||
|
||||
pub fn universe(&self) -> ty::UniverseIndex {
|
||||
self.universe.get()
|
||||
}
|
||||
|
|
|
@ -152,7 +152,6 @@ impl<'tcx> AutoTraitFinder<'tcx> {
|
|||
with {:?}",
|
||||
trait_ref, full_env
|
||||
);
|
||||
infcx.clear_caches();
|
||||
|
||||
// At this point, we already have all of the bounds we need. FulfillmentContext is used
|
||||
// to store all of the necessary region/lifetime bounds in the InferContext, as well as
|
||||
|
@ -255,8 +254,6 @@ impl<'tcx> AutoTraitFinder<'tcx> {
|
|||
let dummy_cause = ObligationCause::dummy();
|
||||
|
||||
while let Some(pred) = predicates.pop_front() {
|
||||
infcx.clear_caches();
|
||||
|
||||
if !already_visited.insert(pred) {
|
||||
continue;
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue