mirror of
https://github.com/ChaiScript/ChaiScript.git
synced 2025-12-07 01:06:54 +08:00
Fix last merge
This commit is contained in:
parent
2818ec67df
commit
476a752a08
@ -1065,12 +1065,9 @@ namespace chaiscript
|
|||||||
if (unicode_size > 0) {
|
if (unicode_size > 0) {
|
||||||
process_unicode();
|
process_unicode();
|
||||||
}
|
}
|
||||||
}
|
} catch (const std::invalid_argument &) {
|
||||||
|
} catch (const exception::eval_error &) {
|
||||||
void finalize_unicode()
|
// Something happened with parsing, we'll catch it later?
|
||||||
{
|
|
||||||
if (unicode_size > 0) {
|
|
||||||
process_unicode();
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -1307,7 +1304,6 @@ namespace chaiscript
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
cparser.finalize_unicode();
|
|
||||||
return cparser.is_interpolated;
|
return cparser.is_interpolated;
|
||||||
}();
|
}();
|
||||||
|
|
||||||
@ -1366,7 +1362,6 @@ namespace chaiscript
|
|||||||
for (auto s = start + 1, end = m_position - 1; s != end; ++s) {
|
for (auto s = start + 1, end = m_position - 1; s != end; ++s) {
|
||||||
cparser.parse(*s, start.line, start.col, *m_filename);
|
cparser.parse(*s, start.line, start.col, *m_filename);
|
||||||
}
|
}
|
||||||
cparser.finalize_unicode();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if (match.size() != 1) {
|
if (match.size() != 1) {
|
||||||
|
|||||||
@ -9,7 +9,7 @@ assert_equal("\xF0\x9F\x8D\x8C", "🍌")
|
|||||||
assert_equal("\U0001F34C", "🍌")
|
assert_equal("\U0001F34C", "🍌")
|
||||||
|
|
||||||
assert_throws("Invalid 16 bit universal character", fun(){ parse("\"\\uD83C\""); });
|
assert_throws("Invalid 16 bit universal character", fun(){ parse("\"\\uD83C\""); });
|
||||||
assert_throws("Incomplete unicode escape sequence", fun(){ parse("\"\\uD83\""); });
|
assert_throws("Incomplete unicode escape sequence", fun(){ parse("\"\\uD83 \""); });
|
||||||
|
|
||||||
assert_equal("\U00024B62", "𤭢")
|
assert_equal("\U00024B62", "𤭢")
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user