Skip to content

Commit 3493f8c

Browse files
authored
fix docustring on fetch_or
1 parent 0160933 commit 3493f8c

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

library/core/src/sync/atomic.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1151,8 +1151,8 @@ impl AtomicBool {
11511151
/// assert_eq!(foo.fetch_or(false, Ordering::SeqCst), true);
11521152
/// assert_eq!(foo.load(Ordering::SeqCst), true);
11531153
///
1154-
/// let foo = AtomicBool::new(true);
1155-
/// assert_eq!(foo.fetch_or(true, Ordering::SeqCst), true);
1154+
/// let foo = AtomicBool::new(false);
1155+
/// assert_eq!(foo.fetch_or(true, Ordering::SeqCst), false);
11561156
/// assert_eq!(foo.load(Ordering::SeqCst), true);
11571157
///
11581158
/// let foo = AtomicBool::new(false);

0 commit comments

Comments
 (0)