Parse long unicode

This commit is contained in:
Thomas Pelletier
2015-05-21 18:52:26 -07:00
parent a8327d781a
commit 222e90a7d3
2 changed files with 23 additions and 0 deletions
+6
View File
@@ -458,6 +458,12 @@ func TestKeyEqualStringUnicodeEscape(t *testing.T) {
token{Position{1, 8}, tokenString, "hello ♥"},
token{Position{1, 21}, tokenEOF, ""},
})
testFlow(t, `foo = "hello \U000003B4"`, []token{
token{Position{1, 1}, tokenKey, "foo"},
token{Position{1, 5}, tokenEqual, "="},
token{Position{1, 8}, tokenString, "hello δ"},
token{Position{1, 25}, tokenEOF, ""},
})
}
func TestLiteralString(t *testing.T) {