From 9d44e9eb7ce65d1ae13db56c56713de4f4ef95bd Mon Sep 17 00:00:00 2001 From: Ariel Ben-Yehuda Date: Fri, 28 Sep 2018 23:20:16 +0300 Subject: enable using the evaluation cache on predicates with LBRs There is no reason not to do it. --- src/librustc/traits/fulfill.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/librustc/traits/fulfill.rs b/src/librustc/traits/fulfill.rs index 8258b54104d..e6bf02cd73e 100644 --- a/src/librustc/traits/fulfill.rs +++ b/src/librustc/traits/fulfill.rs @@ -292,7 +292,7 @@ impl<'a, 'b, 'gcx, 'tcx> ObligationProcessor for FulfillProcessor<'a, 'b, 'gcx, ty::Predicate::Trait(ref data) => { let trait_obligation = obligation.with(data.clone()); - if data.is_global() && !data.has_late_bound_regions() { + if data.is_global() { // no type variables present, can use evaluation for better caching. // FIXME: consider caching errors too. if self.selcx.infcx().predicate_must_hold(&obligation) { -- cgit 1.4.1-3-g733a5