summaryrefslogtreecommitdiff
path: root/coverage/parser.py
diff options
context:
space:
mode:
authorNed Batchelder <ned@nedbatchelder.com>2010-07-01 21:37:10 -0400
committerNed Batchelder <ned@nedbatchelder.com>2010-07-01 21:37:10 -0400
commitf6f6c6600f37ff34174142d13ca770b832cd8731 (patch)
tree436dff2d61b9378ff13e4ae61d30be5978fbe5a9 /coverage/parser.py
parente92644ca7aebdf024f5f0b88571d8f0b777df356 (diff)
downloadpython-coveragepy-git-f6f6c6600f37ff34174142d13ca770b832cd8731.tar.gz
Python 3.2 has a new opcode: SETUP_WITH
Diffstat (limited to 'coverage/parser.py')
-rw-r--r--coverage/parser.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/coverage/parser.py b/coverage/parser.py
index 8285d433..9bce98ad 100644
--- a/coverage/parser.py
+++ b/coverage/parser.py
@@ -265,7 +265,9 @@ OPS_CHUNK_END = _opcode_set(
OPS_CHUNK_BEGIN = _opcode_set('JUMP_ABSOLUTE', 'JUMP_FORWARD')
# Opcodes that push a block on the block stack.
-OPS_PUSH_BLOCK = _opcode_set('SETUP_LOOP', 'SETUP_EXCEPT', 'SETUP_FINALLY')
+OPS_PUSH_BLOCK = _opcode_set(
+ 'SETUP_LOOP', 'SETUP_EXCEPT', 'SETUP_FINALLY', 'SETUP_WITH'
+ )
# Block types for exception handling.
OPS_EXCEPT_BLOCKS = _opcode_set('SETUP_EXCEPT', 'SETUP_FINALLY')