From 312994243a224477a75c78344fa6c0406e3b2de2 Mon Sep 17 00:00:00 2001 From: lcnr Date: Tue, 4 Jul 2023 10:34:27 +0200 Subject: [PATCH] extend comment --- compiler/rustc_trait_selection/src/traits/wf.rs | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/compiler/rustc_trait_selection/src/traits/wf.rs b/compiler/rustc_trait_selection/src/traits/wf.rs index b0798ace60dff..ae7236e30f553 100644 --- a/compiler/rustc_trait_selection/src/traits/wf.rs +++ b/compiler/rustc_trait_selection/src/traits/wf.rs @@ -304,6 +304,11 @@ impl<'a, 'tcx> WfPredicates<'a, 'tcx> { fn normalize(self, infcx: &InferCtxt<'tcx>) -> Vec> { // Do not normalize `wf` obligations with the new solver. + // + // The current deep normalization routine with the new solver does not + // handle ambiguity and the new solver correctly deals with unnnormalized goals. + // If the user relies on normalized types, e.g. for `fn implied_outlives_bounds`, + // it is their responsibility to normalize while avoiding ambiguity. if infcx.next_trait_solver() { return self.out; }