summaryrefslogtreecommitdiff
path: root/complex.c
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2015-02-25 02:25:22 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2015-02-25 02:25:22 +0000
commit7b65fb292af0ae16ef42ff174eb52e7e0d07a839 (patch)
treed22f4094252301f8d57f152e803116d0817178cf /complex.c
parent5ac58b272d65cc9921048c076e35df1f42979725 (diff)
complex.c: M_PI in VC
* complex.c (_USE_MATH_DEFINES): needed for M_PI in Microsoft Visual C. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@49732 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'complex.c')
-rw-r--r--complex.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/complex.c b/complex.c
index 9e352a8..efba0b3 100644
--- a/complex.c
+++ b/complex.c
@@ -6,6 +6,10 @@
*/
#include "internal.h"
+#if defined _MSC_VER
+/* Microsoft Visual C does not define M_PI and others by default */
+# define _USE_MATH_DEFINES 1
+#endif
#include <math.h>
#define NDEBUG