We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 3790f4a commit 0caac69Copy full SHA for 0caac69
src/lazy_static.rs
@@ -93,10 +93,10 @@ macro_rules! lazy_static {
93
fn require_share<T: Share>(_: &T) { }
94
95
unsafe {
96
- static mut s: *$T = 0 as *$T;
+ static mut s: *const $T = 0 as *const $T;
97
static mut ONCE: Once = ONCE_INIT;
98
ONCE.doit(|| {
99
- s = transmute::<Box<$T>, *$T>(box() ($e));
+ s = transmute::<Box<$T>, *const $T>(box() ($e));
100
});
101
let static_ref = &*s;
102
require_share(static_ref);
0 commit comments