pragmagic/vscode-nim

'\n' not considered as legal

Closed this issue · 3 comments

In the following code

import strutils
const c = '\n'
doAssert c in Whitespace
doAssert '\l' == c

The \n is marked wrongly in an error color like GitHub does too.

This error returns by nim compiler, I guess You need to ask this question in https://github.com/nim-lang/Nim

Ok, I just meant the red color inside vscode for new line char. For const c = '\t' it works. Does the information about the color comes from nimsuggest?

I thought it could be changed like this: #75

GULPF commented

@Tim-St is right, this is an error in the syntax definition. I've sent out a PR: #101