23 lines
969 B
Diff
23 lines
969 B
Diff
Link: https://bugreports.qt.io/browse/PYSIDE-2035
|
|
Subject: libshiboken: Fix build with numpy 1.23.0
|
|
Bug: 148771
|
|
Tags: common
|
|
|
|
diff -rupN a/sources/shiboken2/libshiboken/sbknumpyarrayconverter.cpp b/sources/shiboken2/libshiboken/sbknumpyarrayconverter.cpp
|
|
--- a/sources/shiboken2/libshiboken/sbknumpyarrayconverter.cpp 2023-04-04 23:37:59.108794011 +0300
|
|
+++ b/sources/shiboken2/libshiboken/sbknumpyarrayconverter.cpp 2023-04-04 23:38:54.455375459 +0300
|
|
@@ -116,8 +116,13 @@ std::ostream &operator<<(std::ostream &s
|
|
str << " NPY_ARRAY_NOTSWAPPED";
|
|
if ((flags & NPY_ARRAY_WRITEABLE) != 0)
|
|
str << " NPY_ARRAY_WRITEABLE";
|
|
+#if NPY_VERSION >= 0x00000010 // NPY_1_23_API_VERSION
|
|
+ if ((flags & NPY_ARRAY_WRITEBACKIFCOPY) != 0)
|
|
+ str << " NPY_ARRAY_WRITEBACKIFCOPY";
|
|
+#else
|
|
if ((flags & NPY_ARRAY_UPDATEIFCOPY) != 0)
|
|
str << " NPY_ARRAY_UPDATEIFCOPY";
|
|
+#endif
|
|
} else {
|
|
str << '0';
|
|
}
|