Skip to main content

in_range_max

Function in_range_max 

Source
pub fn in_range_max(offset: u64, len: u64, max: u64) -> bool
Expand description

Returns true if the range [offset, offset + len) is fully inside [0, max).

Returns false on arithmetic overflow or if out of bounds.