mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-27 09:14:20 +00:00
Use compare_exchange_weak
in limit::Limit::check
This commit is contained in:
parent
4aadabc735
commit
78a3cefc45
@ -45,7 +45,7 @@ impl Limit {
|
||||
}
|
||||
if self
|
||||
.max
|
||||
.compare_exchange(old_max, other, Ordering::Relaxed, Ordering::Relaxed)
|
||||
.compare_exchange_weak(old_max, other, Ordering::Relaxed, Ordering::Relaxed)
|
||||
.is_ok()
|
||||
{
|
||||
eprintln!("new max: {}", other);
|
||||
|
Loading…
Reference in New Issue
Block a user