From: José Fonseca <[email protected]>

Now that this is an inline function, the warning appears all over the
place.
---
 tests/util/piglit-util.h | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/tests/util/piglit-util.h b/tests/util/piglit-util.h
index 90d57d3..099075a 100755
--- a/tests/util/piglit-util.h
+++ b/tests/util/piglit-util.h
@@ -187,6 +187,9 @@ strtod_inf(const char *nptr, char **endptr)
        while (*nptr == ' ' || *nptr == '\t')
                nptr++;
 
+#pragma warning( push )
+#pragma warning( disable : 4056 ) // overflow in floating-point constant 
arithmetic
+#pragma warning( disable : 4756 ) // overflow in constant arithmetic
        if (nptr[0] == 'i' && nptr[1] == 'n' && nptr[2] == 'f') {
                /* +infinity */
                *endptr = (char *) (nptr + 3);
@@ -197,6 +200,8 @@ strtod_inf(const char *nptr, char **endptr)
                *endptr = (char *) (nptr + 4);
                return -INFINITY;
        }
+#pragma warning( pop )
+
        /* fall-through */
 #endif
        return strtod(nptr, endptr);
-- 
2.1.0

_______________________________________________
Piglit mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/piglit

Reply via email to