summaryrefslogtreecommitdiffstats
path: root/src/glsl/s_expression.cpp
diff options
context:
space:
mode:
authorMatt Turner <[email protected]>2015-01-12 22:35:53 -0800
committerMatt Turner <[email protected]>2015-03-25 15:06:48 -0700
commit871f1080d0f7b7444458de40b67de7938c220922 (patch)
tree59ad923405b65252c602dcca15f95612baff3132 /src/glsl/s_expression.cpp
parent5dc573e5de0eb49bc8622558789ebc4adf03926c (diff)
glsl: Use INFINITY instead of std::numeric_limits<float>::infinity().
Reviewed-by: Jose Fonseca <[email protected]>
Diffstat (limited to 'src/glsl/s_expression.cpp')
-rw-r--r--src/glsl/s_expression.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/glsl/s_expression.cpp b/src/glsl/s_expression.cpp
index 7eaa491e291..f82e155a6b6 100644
--- a/src/glsl/s_expression.cpp
+++ b/src/glsl/s_expression.cpp
@@ -23,8 +23,8 @@
*/
#include <assert.h>
-#include <limits>
#include <stdio.h>
+#include <math.h>
#include "s_expression.h"
s_symbol::s_symbol(const char *str, size_t n)
@@ -70,7 +70,7 @@ read_atom(void *ctx, const char *&src, char *&symbol_buffer)
// requires strtof to parse '+INF' as +Infinity, but we still support some
// non-C99-compliant compilers (e.g. MSVC).
if (n == 4 && strncmp(src, "+INF", 4) == 0) {
- expr = new(ctx) s_float(std::numeric_limits<float>::infinity());
+ expr = new(ctx) s_float(INFINITY);
} else {
// Check if the atom is a number.
char *float_end = NULL;