Merge #5808
5808: Make RacyFlag actually work
r=matklad a=matklad
bors r+
🤖
Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
This commit is contained in:
commit
2a58adf4d3
@ -141,7 +141,7 @@ pub struct RacyFlag(AtomicUsize);
|
||||
|
||||
impl RacyFlag {
|
||||
pub const fn new() -> RacyFlag {
|
||||
RacyFlag(AtomicUsize::new(0))
|
||||
RacyFlag(AtomicUsize::new(!0))
|
||||
}
|
||||
|
||||
pub fn get(&self, init: impl FnMut() -> bool) -> bool {
|
||||
|
Loading…
x
Reference in New Issue
Block a user