summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNed Batchelder <ned@nedbatchelder.com>2018-10-02 18:54:15 -0400
committerNed Batchelder <ned@nedbatchelder.com>2018-10-04 11:39:30 -0400
commit5aca5af02423f37ec7f4a3a02849e74c54b5ccf1 (patch)
tree623f99eeeb1836ba576e9e070c7a21f44601bcc5
parent3d8dd2ab07cc6d3149e7308e1e3be194a21364f6 (diff)
downloadpython-coveragepy-git-5aca5af02423f37ec7f4a3a02849e74c54b5ccf1.tar.gz
Python 3.6 changed lnotab to signed bytes
-rw-r--r--coverage/parser.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/coverage/parser.py b/coverage/parser.py
index c9eb793f..bb99cf0d 100644
--- a/coverage/parser.py
+++ b/coverage/parser.py
@@ -409,6 +409,8 @@ class ByteParser(object):
yield (byte_num, line_num)
last_line_num = line_num
byte_num += byte_incr
+ if env.PYVERSION >= (3, 6) and line_incr >= 0x80:
+ line_incr -= 0x100
line_num += line_incr
if line_num != last_line_num:
yield (byte_num, line_num)