Current code was using transmute to get the bit-pattern of f32 and f64.
This PR changes to use .to_bits() instead, which has that exact semantic, is safe and supported since rustc 1.20. It also makes two debug_assert!()s stricter as they were not strict enough when compared to the get_unchecked right next to it.
Current code was using transmute to get the bit-pattern of f32 and f64.
This PR changes to use .to_bits() instead, which has that exact semantic, is safe and supported since rustc 1.20. It also makes two debug_assert!()s stricter as they were not strict enough when compared to the get_unchecked right next to it.
Thanks a lot!