diff options
| author | Michael Goulet <michael@errs.io> | 2024-05-01 16:03:08 -0400 |
|---|---|---|
| committer | Michael Goulet <michael@errs.io> | 2024-05-02 21:56:14 -0400 |
| commit | 837bde11a2e1796910df8a6196f56c58fac6319c (patch) | |
| tree | 4c796dd608374115be596a27285f91c1386657e1 | |
| parent | 79734f1db8dbe322192dea32c0f6b80ab14c4c1d (diff) | |
| download | rust-837bde11a2e1796910df8a6196f56c58fac6319c.tar.gz rust-837bde11a2e1796910df8a6196f56c58fac6319c.zip | |
Record certainty before evaluating nesteds, so we make candidates
| -rw-r--r-- | compiler/rustc_trait_selection/src/solve/eval_ctxt/canonical.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/compiler/rustc_trait_selection/src/solve/eval_ctxt/canonical.rs b/compiler/rustc_trait_selection/src/solve/eval_ctxt/canonical.rs index 6722abd709c..d6bf2b596ef 100644 --- a/compiler/rustc_trait_selection/src/solve/eval_ctxt/canonical.rs +++ b/compiler/rustc_trait_selection/src/solve/eval_ctxt/canonical.rs @@ -90,6 +90,8 @@ impl<'tcx> EvalCtxt<'_, 'tcx> { &mut self, certainty: Certainty, ) -> QueryResult<'tcx> { + self.inspect.make_canonical_response(certainty); + let goals_certainty = self.try_evaluate_added_goals()?; assert_eq!( self.tainted, @@ -98,8 +100,6 @@ impl<'tcx> EvalCtxt<'_, 'tcx> { previous call to `try_evaluate_added_goals!`" ); - self.inspect.make_canonical_response(certainty); - // When normalizing, we've replaced the expected term with an unconstrained // inference variable. This means that we dropped information which could // have been important. We handle this by instead returning the nested goals |
