You may know the default Rust operations like +, - and so on. But there are more functions that may suit you better in rare cases. In the following I call the default operations the “normal” operations and the argument rhs(function(rhs)).

Functionreturnsnotes
normalT
tryResult<T>Computes self + rhs, returning an Error if an overflow occured
checkedOption<T>Computes self + rhs, returning None if an overflow occurred
uncheckedTComputes assuming an over/underflow cannot occur(Results in undefined behaviour upon overflow)
saturatingTComputes self + rhs, saturating at the numeric bounds instead of overflowing
wrappingT“wraps” around the boundary, same as with modulo T::max
overflowingTOverflows instead of panicking upon an overflow