C++ library for UTF-8 string handling and validation
UTF-8 with C++ in a Portable Way
utf8cpp$ #include <utf8.h>
// Use utf8::is_valid() to check UTF-8 string validity$ std::string str = "Hello UTF-8: café";
if (utf8::is_valid(str.begin(), str.end())) { /* valid */ }$ std::string utf8_string = "Hello 世界";
for (auto it = utf8_string.begin(); it != utf8_string.end(); utf8::next(it, utf8_string.end())) { /* process codepoint */ }