fix: 64-bit atomics for platforms with no 64-bit atomics

Closes: #423
This commit is contained in:
NoisyCoil
2024-08-06 17:51:43 +02:00
committed by andy.boot
parent f48fcc790a
commit 489d9ada44
2 changed files with 9 additions and 1 deletions
+6 -1
View File
@@ -3,7 +3,7 @@ use std::{
io::Write,
path::Path,
sync::{
atomic::{AtomicU64, AtomicU8, AtomicUsize, Ordering},
atomic::{AtomicU8, AtomicUsize, Ordering},
mpsc::{self, RecvTimeoutError, Sender},
Arc, RwLock,
},
@@ -11,6 +11,11 @@ use std::{
time::Duration,
};
#[cfg(not(target_has_atomic = "64"))]
use portable_atomic::AtomicU64;
#[cfg(target_has_atomic = "64")]
use std::sync::atomic::AtomicU64;
use crate::display::human_readable_number;
/* -------------------------------------------------------------------------- */