summaryrefslogtreecommitdiff
path: root/python
diff options
context:
space:
mode:
Diffstat (limited to 'python')
-rw-r--r--python/python-apt.h62
1 files changed, 31 insertions, 31 deletions
diff --git a/python/python-apt.h b/python/python-apt.h
index 940963cf..80ad03bd 100644
--- a/python/python-apt.h
+++ b/python/python-apt.h
@@ -152,37 +152,37 @@ static int import_apt_pkg(void) {
# define PyTagSection_Check(op) PyObject_TypeCheck(op, &PyTagSection_Type)
# define PyVersion_Check(op) PyObject_TypeCheck(op, &PyVersion_Type)
// Exact check macros.
-# define PyAcquire_CheckExact(op) (Py_TYPE(op) == &PyAcquire_Type)
-# define PyAcquireFile_CheckExact(op) (Py_TYPE(op) == &PyAcquireFile_Type)
-# define PyAcquireItem_CheckExact(op) (Py_TYPE(op) == &PyAcquireItem_Type)
-# define PyAcquireItemDesc_CheckExact(op) (Py_TYPE(op) == &PyAcquireItemDesc_Type)
-# define PyAcquireWorker_CheckExact(op) (Py_TYPE(op) == &PyAcquireWorker_Type)
-# define PyActionGroup_CheckExact(op) (Py_TYPE(op) == &PyActionGroup_Type)
-# define PyCache_CheckExact(op) (Py_TYPE(op) == &PyCache_Type)
-# define PyCacheFile_CheckExact(op) (Py_TYPE(op) == &PyCacheFile_Type)
-# define PyCdrom_CheckExact(op) (Py_TYPE(op) == &PyCdrom_Type)
-# define PyConfiguration_CheckExact(op) (Py_TYPE(op) == &PyConfiguration_Type)
-# define PyDepCache_CheckExact(op) (Py_TYPE(op) == &PyDepCache_Type)
-# define PyDependency_CheckExact(op) (Py_TYPE(op) == &PyDependency_Type)
-# define PyDependencyList_CheckExact(op) (Py_TYPE(op) == &PyDependencyList_Type)
-# define PyDescription_CheckExact(op) (Py_TYPE(op) == &PyDescription_Type)
-# define PyHashes_CheckExact(op) (Py_TYPE(op) == &PyHashes_Type)
-# define PyHashString_CheckExact(op) (Py_TYPE(op) == &PyHashString_Type)
-# define PyIndexRecords_CheckExact(op) (Py_TYPE(op) == &PyIndexRecords_Type)
-# define PyMetaIndex_CheckExact(op) (Py_TYPE(op) == &PyMetaIndex_Type)
-# define PyPackage_CheckExact(op) (Py_TYPE(op) == &PyPackage_Type)
-# define PyPackageFile_CheckExact(op) (Py_TYPE(op) == &PyPackageFile_Type)
-# define PyPackageIndexFile_CheckExact(op) (Py_TYPE(op) == &PyPackageIndexFile_Type)
-# define PyPackageList_CheckExact(op) (Py_TYPE(op) == &PyPackageList_Type)
-# define PyPackageManager_CheckExact(op) (Py_TYPE(op) == &PyPackageManager_Type)
-# define PyPackageRecords_CheckExact(op) (Py_TYPE(op) == &PyPackageRecords_Type)
-# define PyPolicy_CheckExact(op) (Py_TYPE(op) == &PyPolicy_Type)
-# define PyProblemResolver_CheckExact(op) (Py_TYPE(op) == &PyProblemResolver_Type)
-# define PySourceList_CheckExact(op) (Py_TYPE(op) == &PySourceList_Type)
-# define PySourceRecords_CheckExact(op) (Py_TYPE(op) == &PySourceRecords_Type)
-# define PyTagFile_CheckExact(op) (Py_TYPE(op) == &PyTagFile_Type)
-# define PyTagSection_CheckExact(op) (Py_TYPE(op) == &PyTagSection_Type)
-# define PyVersion_CheckExact(op) (Py_TYPE(op) == &PyVersion_Type)
+# define PyAcquire_CheckExact(op) (op->op_type == &PyAcquire_Type)
+# define PyAcquireFile_CheckExact(op) (op->op_type == &PyAcquireFile_Type)
+# define PyAcquireItem_CheckExact(op) (op->op_type == &PyAcquireItem_Type)
+# define PyAcquireItemDesc_CheckExact(op) (op->op_type == &PyAcquireItemDesc_Type)
+# define PyAcquireWorker_CheckExact(op) (op->op_type == &PyAcquireWorker_Type)
+# define PyActionGroup_CheckExact(op) (op->op_type == &PyActionGroup_Type)
+# define PyCache_CheckExact(op) (op->op_type == &PyCache_Type)
+# define PyCacheFile_CheckExact(op) (op->op_type == &PyCacheFile_Type)
+# define PyCdrom_CheckExact(op) (op->op_type == &PyCdrom_Type)
+# define PyConfiguration_CheckExact(op) (op->op_type == &PyConfiguration_Type)
+# define PyDepCache_CheckExact(op) (op->op_type == &PyDepCache_Type)
+# define PyDependency_CheckExact(op) (op->op_type == &PyDependency_Type)
+# define PyDependencyList_CheckExact(op) (op->op_type == &PyDependencyList_Type)
+# define PyDescription_CheckExact(op) (op->op_type == &PyDescription_Type)
+# define PyHashes_CheckExact(op) (op->op_type == &PyHashes_Type)
+# define PyHashString_CheckExact(op) (op->op_type == &PyHashString_Type)
+# define PyIndexRecords_CheckExact(op) (op->op_type == &PyIndexRecords_Type)
+# define PyMetaIndex_CheckExact(op) (op->op_type == &PyMetaIndex_Type)
+# define PyPackage_CheckExact(op) (op->op_type == &PyPackage_Type)
+# define PyPackageFile_CheckExact(op) (op->op_type == &PyPackageFile_Type)
+# define PyPackageIndexFile_CheckExact(op) (op->op_type == &PyPackageIndexFile_Type)
+# define PyPackageList_CheckExact(op) (op->op_type == &PyPackageList_Type)
+# define PyPackageManager_CheckExact(op) (op->op_type == &PyPackageManager_Type)
+# define PyPackageRecords_CheckExact(op) (op->op_type == &PyPackageRecords_Type)
+# define PyPolicy_CheckExact(op) (op->op_type == &PyPolicy_Type)
+# define PyProblemResolver_CheckExact(op) (op->op_type == &PyProblemResolver_Type)
+# define PySourceList_CheckExact(op) (op->op_type == &PySourceList_Type)
+# define PySourceRecords_CheckExact(op) (op->op_type == &PySourceRecords_Type)
+# define PyTagFile_CheckExact(op) (op->op_type == &PyTagFile_Type)
+# define PyTagSection_CheckExact(op) (op->op_type == &PyTagSection_Type)
+# define PyVersion_CheckExact(op) (op->op_type == &PyVersion_Type)
// Get the underlying C++ reference or pointer from the Python object.
# define PyAcquire_ToCpp GetCpp<pkgAcquire*>