diff --git a/src/parser/parser_types.nim b/src/parser/parser_types.nim index 3584eb4..540faeb 100644 --- a/src/parser/parser_types.nim +++ b/src/parser/parser_types.nim @@ -407,7 +407,9 @@ func highlightStreamPosition2(stream: string, position: int): string = let beforeNewline = case (startIndex, ch): + # Always print newline for newline at the stream begin of (-1, '\n'): "\n" + # Don't insert a newline when the character is a newline between newlines of (_, '\n'): "" else: "\n"