num_traits

Trait RefNum

source
pub trait RefNum<Base>: NumOps<Base, Base> + for<'r> NumOps<&'r Base, Base> { }
Expand description

The trait for Num references which implement numeric operations, taking the second operand either by value or by reference.

This is automatically implemented for all types which implement the operators. It covers every type implementing the operations though, regardless of it being a reference or related to Num.

Implementors§

source§

impl<T, Base> RefNum<Base> for T
where T: NumOps<Base, Base> + for<'r> NumOps<&'r Base, Base>,