mirror of
https://github.com/allankoechke/rust.git
synced 2026-12-05 01:24:03 +00:00
const and NonZero impl for clamp_magnitude() This PR is implementing the latest proposed changes in Issue rust-lang/rust#148519, making the clamp_magnitude() functions const for all floating point and integer types, as well as adding a clamp_magnitude() to NonZero<$Int>, taking a NonZero<$UInt> as limit parameter.