Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Delete unused_PyType_GetMRO from typeobject.c #145500

Closed
Labels
type-refactorCode refactoring (with no changes in behavior)
@colesbury

Description

@colesbury

The function is unused and not publicly visible (i.e, notPyAPI_FUNC). I also did a sanity check of:

PyObject*
_PyType_GetMRO(PyTypeObject*self)
{
#ifdefPy_GIL_DISABLED
PyObject*mro=_Py_atomic_load_ptr_relaxed(&self->tp_mro);
if (mro==NULL) {
returnNULL;
}
if (_Py_TryIncrefCompare(&self->tp_mro,mro)) {
returnmro;
}
BEGIN_TYPE_LOCK();
mro=lookup_tp_mro(self);
Py_XINCREF(mro);
END_TYPE_LOCK();
returnmro;
#else
returnPy_XNewRef(lookup_tp_mro(self));
#endif
}

Linked PRs

Metadata

Metadata

Assignees

No one assigned

    Labels

    type-refactorCode refactoring (with no changes in behavior)

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions


      [8]ページ先頭

      ©2009-2026 Movatter.jp