NumberLike

Trait NumberLike 

Source
pub trait NumberLike<T>:
    Copy
    + Neg<Output = T>
    + Add<Output = T>
    + Sub<Output = T>
    + Mul<Output = T>
    + Div<Output = T> { }
Expand description

Represents types that can be used in formula engines.

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.

Implementors§

Source§

impl<T, U> NumberLike<T> for U
where U: Copy + Neg<Output = T> + Add<Output = T> + Sub<Output = T> + Mul<Output = T> + Div<Output = T>,

Implement the NumberLike trait for all types that implement the required traits.