diff --git a/src/storage.rs b/src/storage.rs index 6559446..ffff95f 100644 --- a/src/storage.rs +++ b/src/storage.rs @@ -168,7 +168,7 @@ impl From>> for Heap { // Convert `value` to boxed slice of length equals to `value.capacity()` // except for zero-sized types - for them length will be `value.len()` because `Vec::capacity` for ZST is undefined // (see ). - if size_of::() != 0 { + if std::mem::size_of::() != 0 { unsafe { value.set_len(value.capacity()) }; } Self::from(value.into_boxed_slice())