Fix character skipping after a surrogate pair
In a string the first character following a surrogate pair is skipped by the lexer, but the rest of the string is parsed as usual.
This commit is contained in:
parent
3948630374
commit
ec7a1d8347
3 changed files with 9 additions and 4 deletions
|
@ -10205,4 +10205,9 @@ TEST_CASE("regression tests")
|
|||
j["string"] = bytes;
|
||||
CHECK(j["string"] == "\u0007\u0007");
|
||||
}
|
||||
|
||||
SECTION("character following a surrogate pair is skipped")
|
||||
{
|
||||
CHECK(json::parse("\"\\ud80c\\udc60abc\"").get<json::string_t>() == u8"\U00013060abc");
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue