move handling of strings to parser (#962)

This commit is contained in:
Islon Scherer
2025-02-19 17:19:48 +01:00
committed by GitHub
parent ee23a8c3f4
commit 2ffd201172
25 changed files with 408 additions and 543 deletions
@@ -1,5 +1,5 @@
–– Pkl Error ––
Unexpected end of file.
Missing `"""` delimiter.
x | res2 = 42
^
@@ -1,5 +1,5 @@
–– Pkl Error ––
Unexpected end of file.
Missing `"""` delimiter.
x | res1 = """
^
@@ -1,5 +1,5 @@
–– Pkl Error ––
Unexpected end of file.
Missing `"` delimiter.
x | res1 = "
^
@@ -1,5 +1,5 @@
–– Pkl Error ––
Unexpected end of file.
Missing `"""` delimiter.
x |
^
@@ -1,5 +1,5 @@
–– Pkl Error ––
Unexpected end of file.
Missing `"""#` delimiter.
x |
^
@@ -1,8 +1,8 @@
–– Pkl Error ––
Invalid Unicode escape sequence `\u{12x}`.
Valid Unicode escape sequences are \u{0} to \u{10FFFF} (1-6 hexadecimal characters).
x | res1 = "\u{12x}"
^^^^^^^
at invalidUnicodeEscape#res1 (file:///$snippetsDir/input/errors/invalidUnicodeEscape.pkl)
Valid Unicode escape sequences are \u{0} to \u{10FFFF} (1-6 hexadecimal characters).
at invalidUnicodeEscape (file:///$snippetsDir/input/errors/invalidUnicodeEscape.pkl)
@@ -1,5 +1,5 @@
–– Pkl Error ––
Unexpected end of file.
Missing `"""` delimiter.
x | res1 = """some string
^
@@ -1,5 +1,5 @@
–– Pkl Error ––
Unexpected end of file.
Missing `"""` delimiter.
x | res2 = 2
^
@@ -1,5 +1,5 @@
–– Pkl Error ––
Unexpected end of file.
Missing `"""` delimiter.
x | res1 = """some string"
^
@@ -3,4 +3,4 @@ Line must match or exceed indentation of the String's last line.
x | mismatched indent
^^^^^^^^^^^^^^^^^
at parser8#res1 (file:///$snippetsDir/input/errors/parser8.pkl)
at parser8 (file:///$snippetsDir/input/errors/parser8.pkl)
@@ -3,4 +3,4 @@ Line must match or exceed indentation of the String's last line.
x | mismatched indent
^^^^^^^^^^^^^^^^^
at parser9#res1 (file:///$snippetsDir/input/errors/parser9.pkl)
at parser9 (file:///$snippetsDir/input/errors/parser9.pkl)