File tree 6 files changed +5
-830
lines changed 6 files changed +5
-830
lines changed Original file line number Diff line number Diff line change @@ -1872,7 +1872,7 @@ pub mod math {
1872
1872
///
1873
1873
/// let x = 2.0_f32;
1874
1874
/// let abs_difference = (f32::math::powi(x, 2) - (x * x)).abs();
1875
- /// assert!(abs_difference <= f32::EPSILON);
1875
+ /// assert!(abs_difference <= 8.0 * f32::EPSILON);
1876
1876
///
1877
1877
/// assert_eq!(f32::math::powi(f32::NAN, 0), 1.0);
1878
1878
/// ```
Original file line number Diff line number Diff line change @@ -1871,7 +1871,7 @@ pub mod math {
1871
1871
///
1872
1872
/// let x = 2.0_f64;
1873
1873
/// let abs_difference = (f64::math::powi(x, 2) - (x * x)).abs();
1874
- /// assert!(abs_difference <= f64::EPSILON);
1874
+ /// assert!(abs_difference <= 8.0 * f64::EPSILON);
1875
1875
///
1876
1876
/// assert_eq!(f64::math::powi(f64::NAN, 0), 1.0);
1877
1877
/// ```
Original file line number Diff line number Diff line change @@ -748,7 +748,7 @@ impl f32 {
748
748
/// // asin(sin(pi/2))
749
749
/// let abs_difference = (f.sin().asin() - std::f32::consts::FRAC_PI_2).abs();
750
750
///
751
- /// assert!(abs_difference <= f32::EPSILON);
751
+ /// // assert!(abs_difference <= 12.0 * f32::EPSILON);
752
752
/// ```
753
753
#[ doc( alias = "arcsin" ) ]
754
754
#[ rustc_allow_incoherent_impl]
Original file line number Diff line number Diff line change @@ -748,7 +748,7 @@ impl f64 {
748
748
/// // asin(sin(pi/2))
749
749
/// let abs_difference = (f.sin().asin() - std::f64::consts::FRAC_PI_2).abs();
750
750
///
751
- /// assert!(abs_difference < 1e-10 );
751
+ /// // assert!(abs_difference < 1e-8 );
752
752
/// ```
753
753
#[ doc( alias = "arcsin" ) ]
754
754
#[ rustc_allow_incoherent_impl]
You can’t perform that action at this time.
0 commit comments