summaryrefslogtreecommitdiffstats
path: root/Python/bytecodes.c
diff options
context:
space:
mode:
authorKen Jin <kenjin@python.org>2024-02-29 22:13:38 (GMT)
committerGitHub <noreply@github.com>2024-02-29 22:13:38 (GMT)
commitd01886c5c9e3a62921b304ba7e5145daaa56d3cf (patch)
tree8196c3f28cf0c8dbd12e6d2c04b70f79af7d69ff /Python/bytecodes.c
parentc04a981ff414b101736688773dbe24f824ca32ce (diff)
downloadcpython-d01886c5c9e3a62921b304ba7e5145daaa56d3cf.zip
cpython-d01886c5c9e3a62921b304ba7e5145daaa56d3cf.tar.gz
cpython-d01886c5c9e3a62921b304ba7e5145daaa56d3cf.tar.bz2
gh-115685: Type/values propagate for TO_BOOL in tier 2 (GH-115686)
Diffstat (limited to 'Python/bytecodes.c')
-rw-r--r--Python/bytecodes.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/Python/bytecodes.c b/Python/bytecodes.c
index 1d51509..095982d 100644
--- a/Python/bytecodes.c
+++ b/Python/bytecodes.c
@@ -4043,6 +4043,11 @@ dummy_func(
value = ptr;
}
+ tier2 pure op (_POP_TOP_LOAD_CONST_INLINE_BORROW, (ptr/4, pop -- value)) {
+ Py_DECREF(pop);
+ value = ptr;
+ }
+
tier2 pure op(_LOAD_CONST_INLINE_WITH_NULL, (ptr/4 -- value, null)) {
value = Py_NewRef(ptr);
null = NULL;