]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
gh-107082: Remove debug hack from get_first_executor in test_capi.test_misc (#107085)
authorGuido van Rossum <guido@python.org>
Sun, 23 Jul 2023 01:22:33 +0000 (18:22 -0700)
committerGitHub <noreply@github.com>
Sun, 23 Jul 2023 01:22:33 +0000 (18:22 -0700)
(Even though it doesn't look like it fixes gh-107082 -- see discussion there -- it still removes debug code that should never have been committed.)

Lib/test/test_capi/test_misc.py

index dc155cc99961c4759487c370d255c2776db6a7d4..0d3f93941e8205912eb9a572e7d93c5589e15897 100644 (file)
@@ -2436,7 +2436,7 @@ def get_first_executor(func):
     co_code = code.co_code
     JUMP_BACKWARD = opcode.opmap["JUMP_BACKWARD"]
     for i in range(0, len(co_code), 2):
-        if co_code[i] == JUMP_BACKWARD or 1:
+        if co_code[i] == JUMP_BACKWARD:
             try:
                 return _testinternalcapi.get_executor(code, i)
             except ValueError: