Skip to content

Commit

Permalink
enable using the evaluation cache on predicates with LBRs
Browse files Browse the repository at this point in the history
There is no reason not to do it.
  • Loading branch information
arielb1 committed Oct 1, 2018
1 parent 53a4b39 commit 9d44e9e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/librustc/traits/fulfill.rs
Expand Up @@ -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) {
Expand Down

0 comments on commit 9d44e9e

Please sign in to comment.