diff options
| author | Andrew Kelley <andrew@ziglang.org> | 2020-11-06 14:09:31 -0500 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2020-11-06 14:09:31 -0500 |
| commit | d1b1f053b0fa8bf5bf716bae79fd656ce8aaec27 (patch) | |
| tree | 82795b82ea092ebe4c777ed75db4fe503704c9ad /lib/std/math/complex/sinh.zig | |
| parent | b9391c9564dd56a46fbf83d8c536af1a3ad14678 (diff) | |
| parent | ff14451b4a328ca6862637a88912000d11aa2bf3 (diff) | |
| download | zig-d1b1f053b0fa8bf5bf716bae79fd656ce8aaec27.tar.gz zig-d1b1f053b0fa8bf5bf716bae79fd656ce8aaec27.zip | |
Merge pull request #6941 from LemonBoy/floateqapprox
std: Implement more useful approxEq semantics
Diffstat (limited to 'lib/std/math/complex/sinh.zig')
| -rw-r--r-- | lib/std/math/complex/sinh.zig | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/std/math/complex/sinh.zig b/lib/std/math/complex/sinh.zig index 3242adef79..8c8930c0ba 100644 --- a/lib/std/math/complex/sinh.zig +++ b/lib/std/math/complex/sinh.zig @@ -164,14 +164,14 @@ test "complex.csinh32" { const a = Complex(f32).new(5, 3); const c = sinh(a); - testing.expect(math.approxEq(f32, c.re, -73.460617, epsilon)); - testing.expect(math.approxEq(f32, c.im, 10.472508, epsilon)); + testing.expect(math.approxEqAbs(f32, c.re, -73.460617, epsilon)); + testing.expect(math.approxEqAbs(f32, c.im, 10.472508, epsilon)); } test "complex.csinh64" { const a = Complex(f64).new(5, 3); const c = sinh(a); - testing.expect(math.approxEq(f64, c.re, -73.460617, epsilon)); - testing.expect(math.approxEq(f64, c.im, 10.472508, epsilon)); + testing.expect(math.approxEqAbs(f64, c.re, -73.460617, epsilon)); + testing.expect(math.approxEqAbs(f64, c.im, 10.472508, epsilon)); } |
