Overhaul Lib/compiler block ordering. The previous code was filled with

hacks.  The new code is based on issue #2472 posted by Antoine Pitrou.  I
did some further cleanups of the pyassem code and optimized the block
ordering pass.
This commit is contained in:
Neil Schemenauer 2009-02-06 21:08:52 +00:00
parent 0d6705b234
commit 4db626f95d
2 changed files with 97 additions and 159 deletions

View file

@ -671,7 +671,7 @@ class CodeGenerator:
self.startBlock(anchor)
self.emit('POP_BLOCK')
self.setups.pop()
self.startBlock(end)
self.nextBlock(end)
self.emit('LOAD_CONST', None)