MSVC: quick fix for int complex test failing in C++, do not use std::complex<int>
authordalcinl <none@none>
Mon, 3 May 2010 01:22:36 +0000 (22:22 -0300)
committerdalcinl <none@none>
Mon, 3 May 2010 01:22:36 +0000 (22:22 -0300)
tests/run/complex_int_T446.pyx
tests/run/complex_int_T446_fix.h [new file with mode: 0644]

index c9ee5519e789416fb5b27b3c83eb04d46ae66124..f2f2ef02a0b976ffcb87327bca3a496b168534c8 100644 (file)
@@ -1,5 +1,8 @@
 import cython
 
+cdef extern from "complex_int_T446_fix.h":
+    pass
+
 def test_arith(int complex a, int complex b):
     """
     >>> test_arith(4, 2)
diff --git a/tests/run/complex_int_T446_fix.h b/tests/run/complex_int_T446_fix.h
new file mode 100644 (file)
index 0000000..c6d11d1
--- /dev/null
@@ -0,0 +1,3 @@
+#if defined _MSC_VER && defined __cplusplus
+#define CYTHON_CCOMPLEX 0
+#endif