Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/tests/lib/libm use isinf instead of isinff. this doesn't int...
details: https://anonhg.NetBSD.org/src/rev/cf089d0ddcdf
branches: trunk
changeset: 350772:cf089d0ddcdf
user: maya <maya%NetBSD.org@localhost>
date: Fri Jan 20 21:15:56 2017 +0000
description:
use isinf instead of isinff. this doesn't introduce a functional change -
isinf works for float as well, and is more portable.
from Ngie Cooper in PR bin/51838
diffstat:
tests/lib/libm/t_pow.c | 18 +++++++++---------
1 files changed, 9 insertions(+), 9 deletions(-)
diffs (71 lines):
diff -r b4e04ba3c6b7 -r cf089d0ddcdf tests/lib/libm/t_pow.c
--- a/tests/lib/libm/t_pow.c Fri Jan 20 19:21:01 2017 +0000
+++ b/tests/lib/libm/t_pow.c Fri Jan 20 21:15:56 2017 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: t_pow.c,v 1.4 2015/09/08 05:24:27 dholland Exp $ */
+/* $NetBSD: t_pow.c,v 1.5 2017/01/20 21:15:56 maya Exp $ */
/*-
* Copyright (c) 2011 The NetBSD Foundation, Inc.
@@ -29,7 +29,7 @@
* POSSIBILITY OF SUCH DAMAGE.
*/
#include <sys/cdefs.h>
-__RCSID("$NetBSD: t_pow.c,v 1.4 2015/09/08 05:24:27 dholland Exp $");
+__RCSID("$NetBSD: t_pow.c,v 1.5 2017/01/20 21:15:56 maya Exp $");
#include <atf-c.h>
#include <math.h>
@@ -379,12 +379,12 @@
*/
z = powf(x, 3.0);
- if (isinff(z) == 0 || signbit(z) == 0)
+ if (isinf(z) == 0 || signbit(z) == 0)
atf_tc_fail_nonfatal("powf(-Inf, 3.0) != -Inf");
z = powf(x, 4.0);
- if (isinff(z) == 0 || signbit(z) != 0)
+ if (isinf(z) == 0 || signbit(z) != 0)
atf_tc_fail_nonfatal("powf(-Inf, 4.0) != +Inf");
/*
@@ -421,7 +421,7 @@
*/
z = powf(0.1, y);
- if (isinff(z) == 0 || signbit(z) != 0)
+ if (isinf(z) == 0 || signbit(z) != 0)
atf_tc_fail_nonfatal("powf(0.1, -Inf) != +Inf");
z = powf(1.1, y);
@@ -452,7 +452,7 @@
z = powf(x, 2.0);
- if (isinff(z) == 0 || signbit(z) != 0)
+ if (isinf(z) == 0 || signbit(z) != 0)
atf_tc_fail_nonfatal("powf(+Inf, 2.0) != +Inf");
}
@@ -478,7 +478,7 @@
z = powf(1.1, y);
- if (isinff(z) == 0 || signbit(z) != 0)
+ if (isinf(z) == 0 || signbit(z) != 0)
atf_tc_fail_nonfatal("powf(1.1, +Inf) != +Inf");
}
@@ -496,8 +496,8 @@
/*
* If x is -1.0, and y is +-Inf, 1.0 shall be returned.
*/
- ATF_REQUIRE(isinff(infp) != 0);
- ATF_REQUIRE(isinff(infn) != 0);
+ ATF_REQUIRE(isinf(infp) != 0);
+ ATF_REQUIRE(isinf(infn) != 0);
if (powf(-1.0, infp) != 1.0) {
atf_tc_expect_fail("PR lib/45372");
Home |
Main Index |
Thread Index |
Old Index