make the new intrinsics safe
This commit is contained in:
parent
04e7a10af6
commit
d1b34acb3b
6 changed files with 16 additions and 12 deletions
|
@ -129,7 +129,7 @@ impl f128 {
|
|||
#[unstable(feature = "f128", issue = "116909")]
|
||||
#[must_use = "method returns a new number and does not mutate the original value"]
|
||||
pub fn round_ties_even(self) -> f128 {
|
||||
unsafe { intrinsics::round_ties_even_f128(self) }
|
||||
intrinsics::round_ties_even_f128(self)
|
||||
}
|
||||
|
||||
/// Returns the integer part of `self`.
|
||||
|
|
|
@ -129,7 +129,7 @@ impl f16 {
|
|||
#[unstable(feature = "f16", issue = "116909")]
|
||||
#[must_use = "method returns a new number and does not mutate the original value"]
|
||||
pub fn round_ties_even(self) -> f16 {
|
||||
unsafe { intrinsics::round_ties_even_f16(self) }
|
||||
intrinsics::round_ties_even_f16(self)
|
||||
}
|
||||
|
||||
/// Returns the integer part of `self`.
|
||||
|
|
|
@ -125,7 +125,7 @@ impl f32 {
|
|||
#[stable(feature = "round_ties_even", since = "1.77.0")]
|
||||
#[inline]
|
||||
pub fn round_ties_even(self) -> f32 {
|
||||
unsafe { intrinsics::round_ties_even_f32(self) }
|
||||
intrinsics::round_ties_even_f32(self)
|
||||
}
|
||||
|
||||
/// Returns the integer part of `self`.
|
||||
|
|
|
@ -125,7 +125,7 @@ impl f64 {
|
|||
#[stable(feature = "round_ties_even", since = "1.77.0")]
|
||||
#[inline]
|
||||
pub fn round_ties_even(self) -> f64 {
|
||||
unsafe { intrinsics::round_ties_even_f64(self) }
|
||||
intrinsics::round_ties_even_f64(self)
|
||||
}
|
||||
|
||||
/// Returns the integer part of `self`.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue