pub fn wtf8ToUtf8LossyAllocZ(allocator: Allocator, wtf8: []const u8) error allocator: Allocatorwtf8: []const u81903
1904
1905
1906
1907
1908
1909
1910pub fn wtf8ToUtf8LossyAllocZ(allocator: Allocator, wtf8: []const u8) error{ InvalidWtf8, OutOfMemory }![:0]u8 {
const utf8 = try allocator.allocSentinel(u8, wtf8.len, 0);
errdefer allocator.free(utf8);
try wtf8ToUtf8Lossy(utf8, wtf8);
return utf8;
}