Tracking issue for the #![feature(const_float_bits_conv)] feature gate, which makes the following methods on f32 and f64 const fn:
- formerly
#![feature(float_bits_conv)]
- formerly
#![feature(float_to_from_bytes)]
to_bytes_be
to_bytes_le
to_bytes_ne
from_bytes_be
from_bytes_le
from_bytes_ne
These require transmute within a const fn to stabilize, and–unlike the recently stabilized #![feature(const_int_conversion)]–do not have a const-stable alternate implementation. Nevertheless, these may be useful for nightly users.
Stabilization is blocked on #57241.
Tracking issue for the
#![feature(const_float_bits_conv)]feature gate, which makes the following methods onf32andf64const fn:#![feature(float_bits_conv)]to_bitsfrom_bits#![feature(float_to_from_bytes)]to_bytes_beto_bytes_leto_bytes_nefrom_bytes_befrom_bytes_lefrom_bytes_neThese require
transmutewithin aconst fnto stabilize, and–unlike the recently stabilized#![feature(const_int_conversion)]–do not have a const-stable alternate implementation. Nevertheless, these may be useful for nightly users.Stabilization is blocked on #57241.