Tracking Issue for #![feature(const_float_methods)]
· Issue #130843 · rust-lang/rust (original) (raw)
Feature gate: #![feature(const_float_methods)]
This is a tracking issue for making const
some methods of floating point types.
Public API
// in core
impl {
pub const fn recip(self) -> Self;
pub const fn to_degrees(self) -> Self;
pub const fn to_radians(self) -> Self;
pub const fn max(self, other: Self) -> Self;
pub const fn min(self, other: Self) -> Self;
pub const fn clamp(self, min: Self, max: Self) -> Self;
pub const fn abs(self) -> Self;
pub const fn signum(self) -> Self;
pub const fn copysign(self, sign: Self) -> Self;
}
Steps / History
- Implementation: Make some float methods unstable const fn #130568
- Final comment period (FCP)1
- Stabilization PR
Unresolved Questions
- None yet.