Wtf8View
Wtf8View iterates the code points of a WTF-8 encoded string, including surrogate halves.
var wtf8 = (try std.unicode.Wtf8View.init("hi there")).iterator();
while (wtf8.nextCodepointSlice()) |codepoint| {
// note: codepoint could be a surrogate half which is invalid
// UTF-8, avoid printing or otherwise sending/emitting this directly
}
Fields of this type
Fields
- bytes:[]const u8
Functions in this namespace