pub trait SafeSub: Sized {
// Required methods
fn checked_sub(&self, r: &Self) -> Option<Self>;
fn saturating_sub(&self, r: &Self) -> Self;
fn wrapping_sub(&self, r: &Self) -> Self;
}Required Methods§
fn checked_sub(&self, r: &Self) -> Option<Self>
fn saturating_sub(&self, r: &Self) -> Self
fn wrapping_sub(&self, r: &Self) -> Self
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.