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
1 changed files with 1 additions and 1 deletions
|
@ -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…
Add table
Reference in a new issue