mirror of
https://github.com/davidhalter/jedi.git
synced 2026-02-25 21:07:13 +08:00
In every case of a new line the tokenize position should be correct.
This commit is contained in:
@@ -293,7 +293,7 @@ def generate_tokens(readline, use_exact_op_types=False):
|
|||||||
typ = OP
|
typ = OP
|
||||||
yield typ, token, spos, prefix
|
yield typ, token, spos, prefix
|
||||||
|
|
||||||
if new_line:
|
if new_line or additional_prefix[-1:] == '\n':
|
||||||
end_pos = lnum + 1, 0
|
end_pos = lnum + 1, 0
|
||||||
else:
|
else:
|
||||||
end_pos = lnum, max
|
end_pos = lnum, max
|
||||||
|
|||||||
Reference in New Issue
Block a user