summaryrefslogtreecommitdiff
path: root/coverage/parser.py
diff options
context:
space:
mode:
authorNed Batchelder <ned@nedbatchelder.com>2009-10-27 07:19:45 -0400
committerNed Batchelder <ned@nedbatchelder.com>2009-10-27 07:19:45 -0400
commit934778095e46933f06251d6b27d2d37ec8ac7538 (patch)
tree9f7bebaeb2bcfb8c3f537943ac42b63863733777 /coverage/parser.py
parentb9948256ed3ba8f3f944f1066cc05ef45a42e92e (diff)
downloadpython-coveragepy-934778095e46933f06251d6b27d2d37ec8ac7538.tar.gz
Didn't deal with internal returns properly.
Diffstat (limited to 'coverage/parser.py')
-rw-r--r--coverage/parser.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/coverage/parser.py b/coverage/parser.py
index 2914485..6f15b12 100644
--- a/coverage/parser.py
+++ b/coverage/parser.py
@@ -376,20 +376,20 @@ class ByteParser(object):
if bc.op in OPS_CODE_END:
# The opcode can exit the code object.
chunk.exits.add(-1)
- elif bc.op in OPS_PUSH_BLOCK:
+ if bc.op in OPS_PUSH_BLOCK:
# The opcode adds a block to the block_stack.
block_stack.append((bc.op, bc.jump_to))
- elif bc.op in OPS_POP_BLOCK:
+ if bc.op in OPS_POP_BLOCK:
# The opcode pops a block from the block stack.
block_stack.pop()
- elif bc.op in OPS_CHUNK_END:
+ if bc.op in OPS_CHUNK_END:
# This opcode forces the end of the chunk.
if bc.op == OP_BREAK_LOOP:
# A break is implicit: jump where the top of the
# block_stack points.
chunk.exits.add(block_stack[-1][1])
chunk = None
- elif bc.op == OP_END_FINALLY:
+ if bc.op == OP_END_FINALLY:
if block_stack:
# A break that goes through a finally will jump to whatever
# block is on top of the stack.