mirror of
https://github.com/python/cpython.git
synced 2025-08-03 00:23:06 +00:00
gh-113391: fix outdated PyObject_HasAttr docs (#113420)
After #53875: PyObject_HasAttr is not an equivalent of hasattr. PyObject_HasAttrWithError is; it already has the note.
This commit is contained in:
parent
a03ec20bcd
commit
61dd77b04e
1 changed files with 2 additions and 3 deletions
|
@ -47,9 +47,8 @@ Object Protocol
|
|||
|
||||
.. c:function:: int PyObject_HasAttr(PyObject *o, PyObject *attr_name)
|
||||
|
||||
Returns ``1`` if *o* has the attribute *attr_name*, and ``0`` otherwise. This
|
||||
is equivalent to the Python expression ``hasattr(o, attr_name)``. This function
|
||||
always succeeds.
|
||||
Returns ``1`` if *o* has the attribute *attr_name*, and ``0`` otherwise.
|
||||
This function always succeeds.
|
||||
|
||||
.. note::
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue