]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
bpo-43753: Add Py_Is() and Py_IsNone() functions (GH-25227)
authorVictor Stinner <vstinner@python.org>
Sat, 10 Apr 2021 22:17:39 +0000 (00:17 +0200)
committerGitHub <noreply@github.com>
Sat, 10 Apr 2021 22:17:39 +0000 (00:17 +0200)
commit09bbebea163fe7303264cf4069c51d4d2f22fde4
treeaf9449e38983bab8ebf5a667c149cb0d33e05543
parent6e468cb16bde483ad73c1eb13b20a08d74e30846
bpo-43753: Add Py_Is() and Py_IsNone() functions (GH-25227)

Add the Py_Is(x, y) function to test if the 'x' object is the 'y'
object, the same as "x is y" in Python. Add also the Py_IsNone(),
Py_IsTrue(), Py_IsFalse() functions to test if an object is,
respectively, the None singleton, the True singleton or the False
singleton.
Doc/c-api/structures.rst
Doc/data/stable_abi.dat
Doc/whatsnew/3.10.rst
Include/boolobject.h
Include/object.h
Misc/NEWS.d/next/C API/2021-04-06-20-52-44.bpo-43753.xUsHp1.rst [new file with mode: 0644]
Modules/_testcapimodule.c
Objects/object.c
Python/ceval.c