mirror of
https://github.com/fmtlib/fmt.git
synced 2024-11-29 21:31:05 +00:00
parent
bbb784fb1b
commit
bd868f3a51
@ -1453,7 +1453,7 @@ template <typename WChar, typename Buffer = memory_buffer> class to_utf8 {
|
|||||||
++p;
|
++p;
|
||||||
if (p == s.end() || (c & 0xfc00) != 0xd800 || (*p & 0xfc00) != 0xdc00) {
|
if (p == s.end() || (c & 0xfc00) != 0xd800 || (*p & 0xfc00) != 0xdc00) {
|
||||||
if (policy == to_utf8_error_policy::abort) return false;
|
if (policy == to_utf8_error_policy::abort) return false;
|
||||||
buf.append(string_view("<EFBFBD>"));
|
buf.append(string_view("\xEF\xBF\xBD"));
|
||||||
--p;
|
--p;
|
||||||
} else {
|
} else {
|
||||||
c = (c << 10) + static_cast<uint32_t>(*p) - 0x35fdc00;
|
c = (c << 10) + static_cast<uint32_t>(*p) - 0x35fdc00;
|
||||||
|
Loading…
Reference in New Issue
Block a user