Closed GoogleCodeExporter closed 9 years ago
This is because no instructions are generated for the second pass statement.
If you look at the module dissassembly for function test() it is:
Disassembly of test:
2 0 LOAD_CONST 1 ('test')
3 PRINT_ITEM
4 PRINT_NEWLINE
3 5 LOAD_CONST 0 (None)
8 RETURN_VALUE
Now change the function to:
def test():
pass #breakpoint1 (does not work)
print 'test'
The breakpoint in the pass statement will not work. If you look at the
dissassembly you will see that no instructions are generated for line 2:
Disassembly of test:
3 0 LOAD_CONST 1 ('test')
3 PRINT_ITEM
4 PRINT_NEWLINE
5 LOAD_CONST 0 (None)
8 RETURN_VALUE
For a breakpoint to work the specific line needs to generate some python
instructions.
Original comment by pyscripter
on 22 Dec 2010 at 6:26
Thanks for explain. I usually use this technique to set breakpoint AFTER
previous instruction. I should find another method :)
Original comment by al.sko...@gmail.com
on 22 Dec 2010 at 10:47
Original issue reported on code.google.com by
al.sko...@gmail.com
on 22 Dec 2010 at 4:05