Author: tkreuzer
Date: Wed Feb 16 12:53:21 2011
New Revision: 50731
URL:
http://svn.reactos.org/svn/reactos?rev=50731&view=rev
Log:
[WINE]
Add math.h for wine code, with NAN and INFINITY as portable constants.
Added:
branches/cmake-bringup/include/reactos/wine/math.h (with props)
Added: branches/cmake-bringup/include/reactos/wine/math.h
URL:
http://svn.reactos.org/svn/reactos/branches/cmake-bringup/include/reactos/w…
==============================================================================
--- branches/cmake-bringup/include/reactos/wine/math.h (added)
+++ branches/cmake-bringup/include/reactos/wine/math.h [iso-8859-1] Wed Feb 16 12:53:21
2011
@@ -1,0 +1,26 @@
+#ifndef __WINE_MATH_H_
+#define __WINE_MATH_H_
+
+#include <crt/math.h>
+
+#ifdef _MSC_VER
+__forceinline float _NaN()
+{
+ unsigned long NaN = 0x7fc00000;
+ return *(float*)&NaN;
+}
+#define NAN _NaN()
+
+__forceinline float _Infinity()
+{
+ unsigned long Infinity = 0x7f800000;
+ return *(float*)&Infinity;
+}
+#define INFINITY _Infinity()
+
+#else
+#define NAN (0.0f / 0.0f)
+#define INFINITY (1.0F/0.0F)
+#endif
+
+#endif /* __WINE_MATH_H_ */
Propchange: branches/cmake-bringup/include/reactos/wine/math.h
------------------------------------------------------------------------------
svn:eol-style = native