pub fn int<I, F>(x: F) -> Option<I>Expand description
x, a whole float, as an integer of type I. None where x is NaN or infinite, or lies outside I. For i64 and u32, a magnitude beyond 2^51 - 1 also gives None, and so does i32::MIN from an f32. A fraction gives an integer next to it, or None.