diff --git a/commons/zenoh-shm/src/api/provider/types.rs b/commons/zenoh-shm/src/api/provider/types.rs index 0466f2a554..03e40793dc 100644 --- a/commons/zenoh-shm/src/api/provider/types.rs +++ b/commons/zenoh-shm/src/api/provider/types.rs @@ -61,7 +61,7 @@ impl AllocAlignment { #[zenoh_macros::unstable_doc] pub fn new(pow: u8) -> Result { match pow { - pow if pow < 64 => Ok(Self { pow }), + pow if pow < usize::BITS as u8 => Ok(Self { pow }), _ => Err(ZLayoutError::IncorrectLayoutArgs), } }