Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
Use Py_TYPE() rather than o->ob_type.
  • Loading branch information
nascheme committed Oct 20, 2020
commit 053162dbcc41e0b6c139e29cd559e17e2a8bb174
2 changes: 1 addition & 1 deletion Objects/unionobject.c
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ unionobject_dealloc(PyObject *self)
unionobject *alias = (unionobject *)self;

Py_XDECREF(alias->args);
self->ob_type->tp_free(self);
Py_TYPE(self)->tp_free(self);
}

static Py_hash_t
Expand Down
2 changes: 1 addition & 1 deletion Python/ceval.c
Original file line number Diff line number Diff line change
Expand Up @@ -3186,7 +3186,7 @@ _PyEval_EvalFrameDefault(PyThreadState *tstate, PyFrameObject *f, int throwflag)

descr = _PyType_Lookup(type, name);
if (descr == NULL ||
descr->ob_type->tp_descr_get == NULL ||
Py_TYPE(descr)->tp_descr_get == NULL ||
!PyDescr_IsData(descr))
{
dictptr = (PyObject **) ((char *)owner + type->tp_dictoffset);
Expand Down