Skip to main content

clamp_add

Function clamp_add 

Source
pub fn clamp_add(a: i64, b: i64) -> i64
Expand description

Performs saturating addition on i64.

This implements a clamping policy in the case of overflow, returning i64::MIN or i64::MAX.