Tiny fix in lexer

This commit is contained in:
Erez Shinan 2017-05-28 16:09:41 +03:00
parent 40d732ddf5
commit 88242f10d7
1 changed files with 1 additions and 1 deletions

View File

@ -159,10 +159,10 @@ class Lexer(object):
if to_yield:
t = Token(type_, value, lex_pos, line, lex_pos - col_start_pos)
end_col = t.column + len(value)
if t.type in self.callback:
t = self.callback[t.type](t)
end_col = t.column + len(value)
if type_ in newline_types:
newlines = value.count(self.newline_char)
if newlines: