From 659c4b9601a634cd50919970684ee46143183238 Mon Sep 17 00:00:00 2001 From: David Mitchell Date: Sat, 16 Nov 2013 00:01:32 +0000 Subject: Revert "make perl core quiet under -Wfloat-equal" A suggested way of avoiding the the warning on nv1 != nv2 by replacing it with (nv1 < nv2 || nv1 > nv2), has too many issues with NaN. [perl #120538]. I haven't found any other way of selectively disabling the warning, so for now I'm just reverting the whole commit. This reverts commit c279c4550ce59702722d0921739b1a1b92701b0d. --- op.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'op.c') diff --git a/op.c b/op.c index 412a5ce787..09af08a2f0 100644 --- a/op.c +++ b/op.c @@ -1532,8 +1532,7 @@ Perl_scalarvoid(pTHX_ OP *o) /* the constants 0 and 1 are permitted as they are conventionally used as dummies in constructs like 1 while some_condition_with_side_effects; */ - else if (SvNIOK(sv) && (NV_eq_nowarn(SvNV(sv), 0.0) || - NV_eq_nowarn(SvNV(sv), 1.0))) + else if (SvNIOK(sv) && (SvNV(sv) == 0.0 || SvNV(sv) == 1.0)) useless = NULL; else if (SvPOK(sv)) { SV * const dsv = newSVpvs(""); -- cgit v1.2.1