about summary refs log tree commit diff
diff options
context:
space:
mode:
authorbjorn3 <17426603+bjorn3@users.noreply.github.com>2024-05-11 16:36:12 +0000
committerbjorn3 <17426603+bjorn3@users.noreply.github.com>2024-05-11 16:36:12 +0000
commit8cf40c46b20d5b3e2f9ce3d4c82fcbcf5c4dec40 (patch)
treec86cc6f3ee14358d3596bb95cc8336e0bc26c7da
parentf437815d919e4636997b7d0a75e7bd7120406372 (diff)
downloadrust-8cf40c46b20d5b3e2f9ce3d4c82fcbcf5c4dec40.tar.gz
rust-8cf40c46b20d5b3e2f9ce3d4c82fcbcf5c4dec40.zip
Don't attempt to polymorphize statics
Fixes rust-lang/rust#124319
-rw-r--r--src/constant.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/constant.rs b/src/constant.rs
index cdf499a22f8..64e83e43d32 100644
--- a/src/constant.rs
+++ b/src/constant.rs
@@ -258,7 +258,7 @@ fn data_id_for_static(
 ) -> DataId {
     let attrs = tcx.codegen_fn_attrs(def_id);
 
-    let instance = Instance::mono(tcx, def_id).polymorphize(tcx);
+    let instance = Instance::mono(tcx, def_id);
     let symbol_name = tcx.symbol_name(instance).name;
 
     if let Some(import_linkage) = attrs.import_linkage {