summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorRoland Scheidegger <sroland@vmware.com>2015-07-29 22:20:04 +0200
committerRoland Scheidegger <sroland@vmware.com>2015-07-29 22:20:04 +0200
commit2b916c6e47862d82b5545e962ebb83b811904c3b (patch)
treed242c40f1bfb4160e8a8f038fe11b60ffe35d617 /include
parente933d545997de9e50a8ed5247722c1c786bf4858 (diff)
c99_math: (trivial) implement exp2 for MSVC too
Unsurprisingly doesn't build otherwise with old msvc.
Diffstat (limited to 'include')
-rw-r--r--include/c99_math.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/include/c99_math.h b/include/c99_math.h
index 0ca5a73b58a..8a67fb133d6 100644
--- a/include/c99_math.h
+++ b/include/c99_math.h
@@ -146,6 +146,12 @@ exp2f(float f)
return powf(2.0f, f);
}
+static inline double
+exp2(double d)
+{
+ return pow(2.0, d);
+}
+
#endif /* C99 */