about summary refs log tree commit diff
path: root/compiler/rustc_data_structures/src
diff options
context:
space:
mode:
authorMatthias Krüger <matthias.krueger@famsik.de>2024-03-04 22:16:30 +0100
committerGitHub <noreply@github.com>2024-03-04 22:16:30 +0100
commit706fe0b7d8bedf66e09f52698dd8e7e92e765754 (patch)
treea5bbcabeb44b9e9e8b1cce85965196e25be6a923 /compiler/rustc_data_structures/src
parent7606c13961ddc1174b70638e934df0439b7dc515 (diff)
parentd0873c7a11e71a46ad58c1d152fb0599281d98df (diff)
downloadrust-706fe0b7d8bedf66e09f52698dd8e7e92e765754.tar.gz
rust-706fe0b7d8bedf66e09f52698dd8e7e92e765754.zip
Rollup merge of #120976 - matthiaskrgr:constify_TL_statics, r=lcnr
constify a couple thread_local statics
Diffstat (limited to 'compiler/rustc_data_structures/src')
-rw-r--r--compiler/rustc_data_structures/src/sync/worker_local.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/compiler/rustc_data_structures/src/sync/worker_local.rs b/compiler/rustc_data_structures/src/sync/worker_local.rs
index 50a614a1b02..07a361ba260 100644
--- a/compiler/rustc_data_structures/src/sync/worker_local.rs
+++ b/compiler/rustc_data_structures/src/sync/worker_local.rs
@@ -42,7 +42,7 @@ pub struct Registry(Arc<RegistryData>);
 thread_local! {
     /// The registry associated with the thread.
     /// This allows the `WorkerLocal` type to clone the registry in its constructor.
-    static REGISTRY: OnceCell<Registry> = OnceCell::new();
+    static REGISTRY: OnceCell<Registry> = const { OnceCell::new() };
 }
 
 struct ThreadData {