1
0
mirror of https://github.com/vlang/v.git synced 2023-08-10 21:13:21 +03:00

toml: ignore CRLF just like LF in line comments, support VTEST_HIDE_OK=1 in tests.

This commit is contained in:
Delyan Angelov
2022-01-02 18:13:43 +02:00
parent b4111451bf
commit ee858568ff
7 changed files with 242 additions and 180 deletions

View File

@@ -345,7 +345,7 @@ fn (mut s Scanner) ignore_line() ?string {
util.printdbg(@MOD + '.' + @STRUCT + '.' + @FN, 'skipping "${byte(c).ascii_str()} / $c"')
if s.at_crlf() {
util.printdbg(@MOD + '.' + @STRUCT + '.' + @FN, 'letting `\\r\\n` slip through')
return s.text[start..s.pos + 1]
break
}
}
return s.text[start..s.pos]