Merge pull request #625 from Catamantaloedis/hint_spin_loop

Replace deprecated std::sync::atomic::spin_loop_hint()
This commit is contained in:
Ashley Mannix 2024-03-30 10:20:55 +10:00 committed by GitHub
commit 28d734b0c4
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -1384,9 +1384,7 @@ where
}
INITIALIZING => {
while STATE.load(Ordering::SeqCst) == INITIALIZING {
// TODO: replace with `hint::spin_loop` once MSRV is 1.49.0.
#[allow(deprecated)]
std::sync::atomic::spin_loop_hint();
std::hint::spin_loop();
}
Err(SetLoggerError(()))
}