nimpretty: fixes #8078
This commit is contained in:
parent
e3a0415650
commit
3ee53a7c8e
3 changed files with 17 additions and 1 deletions
|
|
@ -1148,7 +1148,7 @@ proc skip(L: var TLexer, tok: var TToken) =
|
|||
break
|
||||
tok.strongSpaceA = 0
|
||||
when defined(nimpretty):
|
||||
if buf[pos] == '#': commentIndent = indent
|
||||
if buf[pos] == '#' and tok.line < 0: commentIndent = indent
|
||||
if buf[pos] > ' ' and (buf[pos] != '#' or buf[pos+1] == '#'):
|
||||
tok.indent = indent
|
||||
L.currLineIndent = indent
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue