Revert "grammars : don't allow to output unescaped new line in string (#5885)"

This reverts commit b1a4e994fd.
This commit is contained in:
Georgi Gerganov 2024-03-05 15:56:24 +02:00
parent b1a4e994fd
commit 82cb31eb93
No known key found for this signature in database
GPG Key ID: BF970631944C16B7
2 changed files with 2 additions and 2 deletions

View File

@ -15,7 +15,7 @@ array ::=
string ::= string ::=
"\"" ( "\"" (
[^"\\\n] | [^"\\] |
"\\" (["\\/bfnrt] | "u" [0-9a-fA-F] [0-9a-fA-F] [0-9a-fA-F] [0-9a-fA-F]) # escapes "\\" (["\\/bfnrt] | "u" [0-9a-fA-F] [0-9a-fA-F] [0-9a-fA-F] [0-9a-fA-F]) # escapes
)* "\"" ws )* "\"" ws

View File

@ -24,7 +24,7 @@ array ::=
string ::= string ::=
"\"" ( "\"" (
[^"\\\n] | [^"\\] |
"\\" (["\\/bfnrt] | "u" [0-9a-fA-F] [0-9a-fA-F] [0-9a-fA-F] [0-9a-fA-F]) # escapes "\\" (["\\/bfnrt] | "u" [0-9a-fA-F] [0-9a-fA-F] [0-9a-fA-F] [0-9a-fA-F]) # escapes
)* "\"" ws )* "\"" ws