Function num::signum [−] [src]

pub fn signum<T: Signed>(value: T) -> T

Returns the sign of the number.

For f32 and f64:

For signed integers: