Skip to main content

wiwi_memory_usage/impls/
unit.rs

1use crate::macros::impl_memory_usage_size_of;
2
3impl_memory_usage_size_of! {
4	()
5}
6
7#[cfg(test)]
8mod tests {
9	use crate::{
10		MemoryUsage as _,
11		MemoryUsageStatic as _
12	};
13
14	#[test]
15	fn unit_usage() {
16		#[expect(clippy::let_unit_value, reason = "intentional")]
17		let unit = ();
18
19		assert_eq!(unit.memory_usage(), 0);
20		assert_eq!(<()>::MEMORY_USAGE, 0);
21	}
22}