diff options
author | Timothy Flynn <trflynn89@pm.me> | 2021-08-11 09:58:08 -0400 |
---|---|---|
committer | Linus Groh <mail@linusgroh.de> | 2021-08-15 11:43:45 +0100 |
commit | 2e4b6fd1ac0e768393b2d66fa1f404b059e08ca5 (patch) | |
tree | e04cb9d1dd3ab99d5daa456a8596c673eb2597d1 /Tests | |
parent | e887314472b827c4fcdcc22f09aaeaf69e6d2e4c (diff) | |
download | serenity-2e4b6fd1ac0e768393b2d66fa1f404b059e08ca5.zip |
LibRegex: Ensure escaped code points are exactly 4 digits in length
Diffstat (limited to 'Tests')
-rw-r--r-- | Tests/LibRegex/Regex.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/Tests/LibRegex/Regex.cpp b/Tests/LibRegex/Regex.cpp index fc72472d36..3a4f26a348 100644 --- a/Tests/LibRegex/Regex.cpp +++ b/Tests/LibRegex/Regex.cpp @@ -503,6 +503,8 @@ TEST_CASE(ECMA262_parse) { "(?", regex::Error::InvalidCaptureGroup }, { "\\u1234", regex::Error::NoError, regex::ECMAScriptFlags::Unicode }, { "[\\u1234]", regex::Error::NoError, regex::ECMAScriptFlags::Unicode }, + { "\\u1", regex::Error::InvalidPattern, regex::ECMAScriptFlags::Unicode }, + { "[\\u1]", regex::Error::InvalidPattern, regex::ECMAScriptFlags::Unicode }, { ",(?", regex::Error::InvalidCaptureGroup }, // #4583 { "{1}", regex::Error::InvalidPattern }, { "{1,2}", regex::Error::InvalidPattern }, |