aboutsummaryrefslogtreecommitdiffstats
path: root/sources/pyside2/PySide2/QtCore/glue
diff options
context:
space:
mode:
authorFriedemann Kleint <Friedemann.Kleint@qt.io>2018-07-24 12:58:53 +0200
committerFriedemann Kleint <Friedemann.Kleint@qt.io>2018-07-24 12:59:22 +0200
commit2c3cbe854f921068346ee78f7dda841116230ede (patch)
treeacb00b4202ffaab3b565348a530f3ae0f919a555 /sources/pyside2/PySide2/QtCore/glue
parent0cf22cc9f74594252bd744d6aee77cd3ee3ae0e8 (diff)
parente24392c76e5cfdd2d6d51bd853b106db2bc4cb80 (diff)
Merge remote-tracking branch 'origin/5.11' into dev
Diffstat (limited to 'sources/pyside2/PySide2/QtCore/glue')
-rw-r--r--sources/pyside2/PySide2/QtCore/glue/qbytearray_mgetitem.cpp2
-rw-r--r--sources/pyside2/PySide2/QtCore/glue/qbytearray_msetitem.cpp10
2 files changed, 6 insertions, 6 deletions
diff --git a/sources/pyside2/PySide2/QtCore/glue/qbytearray_mgetitem.cpp b/sources/pyside2/PySide2/QtCore/glue/qbytearray_mgetitem.cpp
index f1d5a6bf..9612f41b 100644
--- a/sources/pyside2/PySide2/QtCore/glue/qbytearray_mgetitem.cpp
+++ b/sources/pyside2/PySide2/QtCore/glue/qbytearray_mgetitem.cpp
@@ -82,6 +82,6 @@ if (PyIndex_Check(_key)) {
} else {
PyErr_Format(PyExc_TypeError,
"list indices must be integers or slices, not %.200s",
- PepType((Py_TYPE(_key)))->tp_name);
+ Py_TYPE(_key)->tp_name);
return NULL;
}
diff --git a/sources/pyside2/PySide2/QtCore/glue/qbytearray_msetitem.cpp b/sources/pyside2/PySide2/QtCore/glue/qbytearray_msetitem.cpp
index 6745fc96..1349f40f 100644
--- a/sources/pyside2/PySide2/QtCore/glue/qbytearray_msetitem.cpp
+++ b/sources/pyside2/PySide2/QtCore/glue/qbytearray_msetitem.cpp
@@ -67,7 +67,7 @@ if (PyIndex_Check(_key)) {
PyErr_SetString(PyExc_ValueError, "bytearray must be of size 1");
return -1;
}
- } else if (PepType(Py_TYPE(_value)) == PepType(SbkPySide2_QtCoreTypes[SBK_QBYTEARRAY_IDX])) {
+ } else if (reinterpret_cast<PyTypeObject *>(Py_TYPE(_value)) == reinterpret_cast<PyTypeObject *>(SbkPySide2_QtCoreTypes[SBK_QBYTEARRAY_IDX])) {
if (PyObject_Length(_value) != 1) {
PyErr_SetString(PyExc_ValueError, "QByteArray must be of size 1");
return -1;
@@ -109,15 +109,15 @@ if (PyIndex_Check(_key)) {
if (_value == NULL || _value == Py_None) {
ba = QByteArray();
value_length = 0;
- } else if (!(PyBytes_Check(_value) || PyByteArray_Check(_value) || PepType(Py_TYPE(_value)) == PepType(SbkPySide2_QtCoreTypes[SBK_QBYTEARRAY_IDX]))) {
- PyErr_Format(PyExc_TypeError, "bytes, bytearray or QByteArray is required, not %.200s", PepType(Py_TYPE(_value))->tp_name);
+ } else if (!(PyBytes_Check(_value) || PyByteArray_Check(_value) || reinterpret_cast<PyTypeObject *>(Py_TYPE(_value)) == reinterpret_cast<PyTypeObject *>(SbkPySide2_QtCoreTypes[SBK_QBYTEARRAY_IDX]))) {
+ PyErr_Format(PyExc_TypeError, "bytes, bytearray or QByteArray is required, not %.200s", Py_TYPE(_value)->tp_name);
return -1;
} else {
value_length = PyObject_Length(_value);
}
if (step != 1 && value_length != slicelength) {
- PyErr_Format(PyExc_ValueError, "attempt to assign %s of size %d to extended slice of size %d",PepType(Py_TYPE(_value))->tp_name, value_length, slicelength);
+ PyErr_Format(PyExc_ValueError, "attempt to assign %s of size %d to extended slice of size %d",Py_TYPE(_value)->tp_name, value_length, slicelength);
return -1;
}
@@ -151,7 +151,7 @@ if (PyIndex_Check(_key)) {
}
} else {
PyErr_Format(PyExc_TypeError, "QBytearray indices must be integers or slices, not %.200s",
- PepType(Py_TYPE(_key))->tp_name);
+ Py_TYPE(_key)->tp_name);
return -1;
}