pubstructUsage(libc::statvfs);// Note that x86 returns `u32` values while x86-64 returns `u64`s, so we convert
// everything to `u64` for consistency.
#[expect(clippy::useless_conversion)]implUsage{pub(crate)fnnew(vfs:libc::statvfs)->Self{Self(vfs)}/// Returns the total number of bytes available.
pubfntotal(&self)->u64{u64::from(self.0.f_blocks)*u64::from(self.0.f_frsize)}/// Returns the available number of bytes used. Note this is not necessarily
/// the same as [`Usage::free`].
pubfnavailable(&self)->u64{u64::from(self.0.f_bfree)*u64::from(self.0.f_frsize)}#[expect(dead_code)]/// Returns the total number of bytes used. Equal to `total - available` on
/// Unix.
pubfnused(&self)->u64{let avail_to_root =u64::from(self.0.f_bfree)*u64::from(self.0.f_frsize);self.total()- avail_to_root
}/// Returns the total number of bytes free. Note this is not necessarily the
/// same as [`Usage::available`].
pubfnfree(&self)->u64{u64::from(self.0.f_bavail)*u64::from(self.0.f_frsize)}}