add work-around for #2164
This commit is contained in:
parent
a272ca2cf7
commit
820f322b86
@ -34,10 +34,12 @@ unsafe impl<T> Sync for EvilSend<T> {}
|
||||
// multiple times
|
||||
fn static_atomic(val: i32) -> &'static AtomicI32 {
|
||||
let ret = Box::leak(Box::new(AtomicI32::new(val)));
|
||||
ret.store(val, Relaxed); // work around https://github.com/rust-lang/miri/issues/2164
|
||||
ret
|
||||
}
|
||||
fn static_atomic_bool(val: bool) -> &'static AtomicBool {
|
||||
let ret = Box::leak(Box::new(AtomicBool::new(val)));
|
||||
ret.store(val, Relaxed); // work around https://github.com/rust-lang/miri/issues/2164
|
||||
ret
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user