summaryrefslogtreecommitdiffstats
path: root/Objects/unionobject.c
diff options
context:
space:
mode:
Diffstat (limited to 'Objects/unionobject.c')
-rw-r--r--Objects/unionobject.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/Objects/unionobject.c b/Objects/unionobject.c
index 32aa507..0535036 100644
--- a/Objects/unionobject.c
+++ b/Objects/unionobject.c
@@ -34,7 +34,7 @@ is_generic_alias_in_args(PyObject *args) {
Py_ssize_t nargs = PyTuple_GET_SIZE(args);
for (Py_ssize_t iarg = 0; iarg < nargs; iarg++) {
PyObject *arg = PyTuple_GET_ITEM(args, iarg);
- if (Py_TYPE(arg) == &Py_GenericAliasType) {
+ if (PyObject_TypeCheck(arg, &Py_GenericAliasType)) {
return 0;
}
}