diff options
Diffstat (limited to 'src/relax.rs')
-rw-r--r-- | src/relax.rs | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/relax.rs b/src/relax.rs index 6d9a690..8842f80 100644 --- a/src/relax.rs +++ b/src/relax.rs @@ -23,7 +23,10 @@ pub struct Spin; impl RelaxStrategy for Spin { #[inline(always)] fn relax() { - core::hint::spin_loop(); + // Use the deprecated spin_loop_hint() to ensure that we don't get + // a higher MSRV than we need to. + #[allow(deprecated)] + core::sync::atomic::spin_loop_hint(); } } |