Trait opendp::traits::CheckedSub [−][src]
pub trait CheckedSub: Sized {
fn checked_sub(&self, v: &Self) -> Option<Self>;
}
Expand description
Performs subtraction that returns none if overflowing.
Required methods
fn checked_sub(&self, v: &Self) -> Option<Self>
fn checked_sub(&self, v: &Self) -> Option<Self>
Checked subtraction.
Returns Some(self - v)
if the result does not overflow, else None