Skip to content

Commit

Permalink
Auto merge of rust-lang#114042 - liushuyu:ubuntu/i586-fpmath, r=worki…
Browse files Browse the repository at this point in the history
…ngjubilee

core library: Disable fpmath tests for i586 ...

This patch disables the floating-point epsilon test for i586 since x87 registers are too imprecise and can't produce the expected results.
  • Loading branch information
bors committed Oct 5, 2023
2 parents 90f3a6f + 40a52cf commit cf9fd95
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion library/core/src/num/f32.rs
Original file line number Diff line number Diff line change
Expand Up @@ -858,7 +858,7 @@ impl f32 {
/// let angle = std::f32::consts::PI;
///
/// let abs_difference = (angle.to_degrees() - 180.0).abs();
///
/// # #[cfg(any(not(target_arch = "x86"), target_feature = "sse2"))]
/// assert!(abs_difference <= f32::EPSILON);
/// ```
#[must_use = "this returns the result of the operation, \
Expand Down

0 comments on commit cf9fd95

Please sign in to comment.