diff --git a/compiler/rustc_middle/src/ty/normalize_erasing_regions.rs b/compiler/rustc_middle/src/ty/normalize_erasing_regions.rs index 48a62b6460467..668ace42724e1 100644 --- a/compiler/rustc_middle/src/ty/normalize_erasing_regions.rs +++ b/compiler/rustc_middle/src/ty/normalize_erasing_regions.rs @@ -27,6 +27,7 @@ impl<'tcx> TyCtxt<'tcx> { value, param_env, ); + debug_assert_eq!(param_env.reveal(), ty::Reveal::All); // Erase first before we do the real query -- this keeps the // cache from being too polluted.