utf8: avoid wraparound warning for view construction

This commit is contained in:
Danny Robson 2019-01-18 17:18:31 +11:00
parent 111bceb013
commit c533b4103e

View File

@ -131,7 +131,7 @@ malformed (cruft::TAP::logger &tap)
for (uint8_t c = 0x80; c <= 0xbf; ++c) {
try {
const auto v = c;
cruft::utf8::decode (cruft::view { &v, &v+1 });
cruft::utf8::decode (cruft::view { &v, 1 });
success = false;
break;
} catch (...) { ; }