Add fixme to remove const derefs side table
diff --git a/gen/build/src/cfg.rs b/gen/build/src/cfg.rs
index 05578df..e0186a3 100644
--- a/gen/build/src/cfg.rs
+++ b/gen/build/src/cfg.rs
@@ -97,6 +97,18 @@
}
thread_local! {
+ // FIXME: If https://github.com/rust-lang/rust/issues/77425 is resolved,
+ // we can delete this thread local side table and instead make each CFG
+ // instance directly own the associated super::Cfg.
+ //
+ // #[allow(const_item_mutation)]
+ // pub const CFG: Cfg = Cfg {
+ // cfg: AtomicPtr::new(ptr::null_mut()),
+ // };
+ // pub struct Cfg {
+ // cfg: AtomicPtr<super::Cfg>,
+ // }
+ //
static CONST_DEREFS: RefCell<HashMap<Handle, Box<super::Cfg<'static>>>> = RefCell::default();
}