Skip to content

Commit 0d61e6e

Browse files
committed
Fix typo in core::sync::atomic::compiler_fence example
1 parent a87fb18 commit 0d61e6e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

library/core/src/sync/atomic.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -2714,7 +2714,7 @@ pub fn fence(order: Ordering) {
27142714
/// Without `compiler_fence`, the `assert_eq!` in following code
27152715
/// is *not* guaranteed to succeed, despite everything happening in a single thread.
27162716
/// To see why, remember that the compiler is free to swap the stores to
2717-
/// `IMPORTANT_VARIABLE` and `IS_READ` since they are both
2717+
/// `IMPORTANT_VARIABLE` and `IS_READY` since they are both
27182718
/// `Ordering::Relaxed`. If it does, and the signal handler is invoked right
27192719
/// after `IS_READY` is updated, then the signal handler will see
27202720
/// `IS_READY=1`, but `IMPORTANT_VARIABLE=0`.

0 commit comments

Comments
 (0)