Skip to content

Commit 783b5c6

Browse files
author
Andreas Freimuth
committed
fixup! Fix indentation handling with tabs (Issue: pylint-dev#1148)
1 parent 6cfd504 commit 783b5c6

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

pylint/checkers/format.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -304,8 +304,8 @@ def line_indent(self, idx):
304304
return _get_indent_string(self.line(idx))
305305

306306
def token_indent(self, idx):
307-
return (self.line_indent(idx) +
308-
' ' * (self.start_col(idx) - _get_indent_length(self.line(idx))))
307+
line_indent = self.line_indent(idx)
308+
return (line_indent + ' ' * (self.start_col(idx) - len(line_indent)))
309309

310310

311311
class ContinuedLineState(object):

0 commit comments

Comments
 (0)