summaryrefslogtreecommitdiff
path: root/numpy/core/src
diff options
context:
space:
mode:
authorCharles Harris <charlesr.harris@gmail.com>2023-04-04 14:01:04 -0400
committerGitHub <noreply@github.com>2023-04-04 14:01:04 -0400
commitbba99dbd606d173a12c7de1867e2337de17c60e9 (patch)
tree6742cbb1be6ebd33297757dd86847c55a3c30d2b /numpy/core/src
parent7f1ce595cee3df09be57abde68e14688516dbe04 (diff)
parentd183edf54e3c74c52471c694068ec7fcc5f7aa34 (diff)
downloadnumpy-bba99dbd606d173a12c7de1867e2337de17c60e9.tar.gz
Merge pull request #23521 from seiko2plus/cpp_2017
ENH: Raise C++ standard to C++17
Diffstat (limited to 'numpy/core/src')
-rw-r--r--numpy/core/src/npymath/npy_math_private.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/numpy/core/src/npymath/npy_math_private.h b/numpy/core/src/npymath/npy_math_private.h
index a474b3de3..20c94f98a 100644
--- a/numpy/core/src/npymath/npy_math_private.h
+++ b/numpy/core/src/npymath/npy_math_private.h
@@ -21,6 +21,7 @@
#include <Python.h>
#ifdef __cplusplus
#include <cmath>
+#include <complex>
using std::isgreater;
using std::isless;
#else
@@ -494,8 +495,9 @@ do { \
* Microsoft C defines _MSC_VER
* Intel compiler does not use MSVC complex types, but defines _MSC_VER by
* default.
+ * since c++17 msvc is no longer support them.
*/
-#if defined(_MSC_VER) && !defined(__INTEL_COMPILER)
+#if !defined(__cplusplus) && defined(_MSC_VER) && !defined(__INTEL_COMPILER)
typedef union {
npy_cdouble npy_z;
_Dcomplex c99_z;