commit 084a4e9d986baf52f29235dba2bebe6b041d012b parent d20de89b8e9072816cca8af64c2a97378e048e00 Author: Drew DeVault <sir@cmpwn.com> Date: Thu, 31 Dec 2020 15:54:50 -0500 lex: treat \t as 8 columns Diffstat:
M | src/lex.c | | | 2 | ++ |
1 file changed, 2 insertions(+), 0 deletions(-)
diff --git a/src/lex.c b/src/lex.c @@ -149,6 +149,8 @@ update_lineno(struct location *loc, uint32_t c) if (c == '\n') { loc->lineno++; loc->colno = 0; + } else if (c == '\t') { + loc->colno += 8; } else { loc->colno++; }