From a84dc3b44f60588849b4a772b82abec585f15611 Mon Sep 17 00:00:00 2001 From: eugenesvk Date: Tue, 21 Jan 2025 13:51:44 +0700 Subject: [PATCH] allow leading 0s, but still limit max length to 6 --- draft-marchan-kdl2.md | 2 +- tests/test_cases/input/unicode_escaped_noncanon_fail.kdl | 1 - 2 files changed, 1 insertion(+), 2 deletions(-) delete mode 100644 tests/test_cases/input/unicode_escaped_noncanon_fail.kdl diff --git a/draft-marchan-kdl2.md b/draft-marchan-kdl2.md index d16295e..655e4c3 100644 --- a/draft-marchan-kdl2.md +++ b/draft-marchan-kdl2.md @@ -983,7 +983,7 @@ string-character := [^\\"] - disallowed-literal-code-points ws-escape := '\\' (unicode-space | newline)+ hex-digit := [0-9a-fA-F] -hex-unicode := [\u{0}-\u{10FFFF}] - surrogate // Unicode Scalar Value₁₆ +hex-unicode := [\u{0}-\u{10FFFF}] - surrogate // Unicode Scalar Value₁₆, leading 0s allowed as long as length ≤ 6 surrogate := [\u{D800}-\u{DFFF}] raw-string := '#' raw-string-quotes '#' | '#' raw-string '#' diff --git a/tests/test_cases/input/unicode_escaped_noncanon_fail.kdl b/tests/test_cases/input/unicode_escaped_noncanon_fail.kdl deleted file mode 100644 index 409fac7..0000000 --- a/tests/test_cases/input/unicode_escaped_noncanon_fail.kdl +++ /dev/null @@ -1 +0,0 @@ -no "Non-canonical format for Unicode Scalar Value with extra 0s: \u{00FFFF} instead of \u{FFFF}"