mirror of
https://github.com/nlohmann/json.git
synced 2026-07-07 19:15:10 +00:00
evaluated i-tests (#344)
This commit is contained in:
@@ -8934,6 +8934,11 @@ basic_json_parser_66:
|
||||
// skip the next 10 characters (xxxx\uyyyy)
|
||||
i += 10;
|
||||
}
|
||||
else if (codepoint >= 0xDC00 and codepoint <= 0xDFFF)
|
||||
{
|
||||
// we found a lone low surrogate
|
||||
throw std::invalid_argument("missing high surrogate");
|
||||
}
|
||||
else
|
||||
{
|
||||
// add unicode character(s)
|
||||
|
||||
@@ -8083,6 +8083,11 @@ class basic_json
|
||||
// skip the next 10 characters (xxxx\uyyyy)
|
||||
i += 10;
|
||||
}
|
||||
else if (codepoint >= 0xDC00 and codepoint <= 0xDFFF)
|
||||
{
|
||||
// we found a lone low surrogate
|
||||
throw std::invalid_argument("missing high surrogate");
|
||||
}
|
||||
else
|
||||
{
|
||||
// add unicode character(s)
|
||||
|
||||
Reference in New Issue
Block a user