Closed GreasySlug closed 2 years ago
Describe the bug
I am concerned about the behavior of \ in lexical analysis
\
The \ itself is not escaped.
Reproducible code
cargo run -- --mode lex
>>> a = "\"" [Symbol a, Equal =, StrLit "\"", EOF ]
however
>>>a = "\\" Error[#0000]: File <stdin>, line 1 1│ a = "\\" ^^^^ SyntaxError: the string is not closed by "
The following works well.
>>> a = "\\"" [Symbol a, Equal =, StrLit "\\"", EOF ] >>> a = "\ " [Symbol a, Equal =, StrLit "\ ", EOF ]
Describe the bug
I am concerned about the behavior of
\
in lexical analysisThe
\
itself is not escaped.Reproducible code
however
The following works well.