From 4e597feef0595caefa39ab43c813734a1244fa84 Mon Sep 17 00:00:00 2001 From: Rich Felker Date: Sun, 6 May 2012 14:48:20 -0400 Subject: fix unused variable warnings in new nextafter/nexttoward code apparently initializing a variable is not "using" it but assigning to it is "using" it. i don't really like this fix, but it's better than trying to make a bigger cleanup just before a release, and it should work fine (tested against nsz's math tests). --- src/math/nexttowardf.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/math/nexttowardf.c') diff --git a/src/math/nexttowardf.c b/src/math/nexttowardf.c index 821f72a5..e8e6f676 100644 --- a/src/math/nexttowardf.c +++ b/src/math/nexttowardf.c @@ -31,7 +31,8 @@ float nexttowardf(float x, long double y) return x + x; /* raise underflow if ux.value is subnormal or zero */ if (e == 0) { - volatile float z = x*x + ux.value*ux.value; + volatile float z; + z = x*x + ux.value*ux.value; } return ux.value; } -- cgit v1.2.1