Function agde::utils::iusize_add_saturating
source ยท pub fn iusize_add_saturating(a: usize, b: isize) -> usize
Expand description
a+b
but with better overflow properties than (a as isize + b) as usize
.
Saturates the output to 0 if a-b < 0