Skip to content

Commit 89ac126

Browse files
committed
Fix line number and offset for E125 with multi-line strings; issue #220
1 parent 197043d commit 89ac126

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

pep8.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -560,11 +560,12 @@ def continued_indentation(logical_line, tokens, indent_level, hang_closing,
560560
rel_indent[end[0] - first_row] = rel_indent[row]
561561

562562
if indent_next and expand_indent(line) == indent_level + 4:
563+
pos = (start[0], indent[0] + 4)
563564
if visual_indent:
564565
code = "E129 visually indented line"
565566
else:
566567
code = "E125 continuation line"
567-
yield (last_indent, "%s with same indent as next logical line" % code)
568+
yield pos, "%s with same indent as next logical line" % code
568569

569570

570571
def whitespace_before_parameters(logical_line, tokens):

0 commit comments

Comments
 (0)