mirror of
https://github.com/python/cpython.git
synced 2025-08-04 00:48:58 +00:00
bpo-43950: use 0-indexed column offsets for bytecode positions (GH-27011)
This commit is contained in:
parent
d33943a6c3
commit
44f91fc802
3 changed files with 19 additions and 22 deletions
|
@ -344,7 +344,7 @@ class CodeTest(unittest.TestCase):
|
|||
# get assigned the first_lineno but they don't have other positions.
|
||||
# There is no easy way of inferring them at that stage, so for now
|
||||
# we don't support it.
|
||||
self.assertTrue(all(positions) or not any(positions))
|
||||
self.assertTrue(positions.count(None) in [0, 4])
|
||||
|
||||
if not any(positions):
|
||||
artificial_instructions.append(instr)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue