about summary refs log tree commit diff
path: root/compiler/rustc_codegen_ssa/src
diff options
context:
space:
mode:
authorlcnr <rust@lcnr.de>2024-11-19 20:10:42 +0100
committerlcnr <rust@lcnr.de>2024-11-19 21:36:23 +0100
commit7a90e84f4d760cb49035f1446d4c6cfb3993aad2 (patch)
treebdb6b4df31aab75b58021f6e6d228db0ec3ae6fa /compiler/rustc_codegen_ssa/src
parentb9dea31ea96b6eef91ab26307b0870783d4931ef (diff)
downloadrust-7a90e84f4d760cb49035f1446d4c6cfb3993aad2.tar.gz
rust-7a90e84f4d760cb49035f1446d4c6cfb3993aad2.zip
`InterpCx` store `TypingEnv` instead of a `ParamEnv`
Diffstat (limited to 'compiler/rustc_codegen_ssa/src')
-rw-r--r--compiler/rustc_codegen_ssa/src/mir/intrinsic.rs5
1 files changed, 1 insertions, 4 deletions
diff --git a/compiler/rustc_codegen_ssa/src/mir/intrinsic.rs b/compiler/rustc_codegen_ssa/src/mir/intrinsic.rs
index c35d0b90706..299b98c0a4f 100644
--- a/compiler/rustc_codegen_ssa/src/mir/intrinsic.rs
+++ b/compiler/rustc_codegen_ssa/src/mir/intrinsic.rs
@@ -146,10 +146,7 @@ impl<'a, 'tcx, Bx: BuilderMethods<'a, 'tcx>> FunctionCx<'a, 'tcx, Bx> {
             | sym::type_id
             | sym::type_name
             | sym::variant_count => {
-                let value = bx
-                    .tcx()
-                    .const_eval_instance(ty::ParamEnv::reveal_all(), instance, span)
-                    .unwrap();
+                let value = bx.tcx().const_eval_instance(bx.typing_env(), instance, span).unwrap();
                 OperandRef::from_const(bx, value, ret_ty).immediate_or_packed_pair(bx)
             }
             sym::arith_offset => {