Skip to content

Commit 8c894f3

Browse files
committed
Rename function and move to internal header.
1 parent 83b90c5 commit 8c894f3

File tree

4 files changed

+3
-3
lines changed

4 files changed

+3
-3
lines changed

Include/cpython/object.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -334,7 +334,6 @@ PyAPI_FUNC(PyObject **) _PyObject_GetDictPtr(PyObject *);
334334
PyAPI_FUNC(PyObject *) _PyObject_NextNotImplemented(PyObject *);
335335
PyAPI_FUNC(void) PyObject_CallFinalizer(PyObject *);
336336
PyAPI_FUNC(int) PyObject_CallFinalizerFromDealloc(PyObject *);
337-
int _PyObject_DictEmpty(PyObject *);
338337

339338
/* Same as PyObject_Generic{Get,Set}Attr, but passing the attributes
340339
dict as the last parameter. */

Include/internal/pycore_object.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -190,6 +190,7 @@ PyObject ** _PyObject_DictPointer(PyObject *);
190190
int _PyObject_VisitInstanceAttributes(PyObject *self, visitproc visit, void *arg);
191191
void _PyObject_ClearInstanceAttributes(PyObject *self);
192192
void _PyObject_FreeInstanceAttributes(PyObject *self);
193+
int _PyObject_IsInstanceDictEmpty(PyObject *);
193194

194195
#ifdef __cplusplus
195196
}

Objects/dictobject.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5051,7 +5051,7 @@ _PyObject_GetInstanceAttribute(PyObject *obj, PyDictValues *values,
50515051
}
50525052

50535053
int
5054-
_PyObject_DictEmpty(PyObject *obj)
5054+
_PyObject_IsInstanceDictEmpty(PyObject *obj)
50555055
{
50565056
PyTypeObject *tp = Py_TYPE(obj);
50575057
if (tp->tp_dictoffset == 0) {

Objects/typeobject.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4941,7 +4941,7 @@ _PyObject_GetState(PyObject *obj, int required)
49414941
Py_TYPE(obj)->tp_name);
49424942
return NULL;
49434943
}
4944-
if (_PyObject_DictEmpty(obj)) {
4944+
if (_PyObject_IsInstanceDictEmpty(obj)) {
49454945
state = Py_None;
49464946
Py_INCREF(state);
49474947
}

0 commit comments

Comments
 (0)