equal
deleted
inserted
replaced
150 coldelta = 0 |
150 coldelta = 0 |
151 coloffset = -1 |
151 coloffset = -1 |
152 if not insideignoreblock: |
152 if not insideignoreblock: |
153 ignorenextline = ( |
153 ignorenextline = ( |
154 tokens[i - 1].type == token.COMMENT |
154 tokens[i - 1].type == token.COMMENT |
155 and tokens[i - 1].string == "#no-py3-transform" |
155 and tokens[i - 1].string == "# no-py3-transform" |
156 ) |
156 ) |
157 continue |
157 continue |
158 |
158 |
159 if t.type == token.COMMENT: |
159 if t.type == token.COMMENT: |
160 if t.string == "#py3-transform: off": |
160 if t.string == "# py3-transform: off": |
161 insideignoreblock = True |
161 insideignoreblock = True |
162 if t.string == "#py3-transform: on": |
162 if t.string == "# py3-transform: on": |
163 insideignoreblock = False |
163 insideignoreblock = False |
164 |
164 |
165 if ignorenextline or insideignoreblock: |
165 if ignorenextline or insideignoreblock: |
166 yield adjusttokenpos(t, coloffset) |
166 yield adjusttokenpos(t, coloffset) |
167 continue |
167 continue |