diff options
| author | Ryan Liptak <squeek502@hotmail.com> | 2024-02-03 14:29:54 -0800 |
|---|---|---|
| committer | Ryan Liptak <squeek502@hotmail.com> | 2024-02-24 14:04:59 -0800 |
| commit | 80508b98c26051cec9f96aceabea03df80e72942 (patch) | |
| tree | 10c48a68e41507a1b841b9ed451819ef6637a4ba /src/main.zig | |
| parent | 4ee1309a8d261360c5b80a9533535231b60780f5 (diff) | |
| download | zig-80508b98c26051cec9f96aceabea03df80e72942.tar.gz zig-80508b98c26051cec9f96aceabea03df80e72942.zip | |
Update deprecated `std.unicode` function usages
Diffstat (limited to 'src/main.zig')
| -rw-r--r-- | src/main.zig | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/main.zig b/src/main.zig index 584a34eeee..db739ebce7 100644 --- a/src/main.zig +++ b/src/main.zig @@ -5756,7 +5756,7 @@ fn readSourceFileToEndAlloc( // If the file starts with a UTF-16 little endian BOM, translate it to UTF-8 if (mem.startsWith(u8, source_code, "\xff\xfe")) { const source_code_utf16_le = mem.bytesAsSlice(u16, source_code); - const source_code_utf8 = std.unicode.utf16leToUtf8AllocZ(allocator, source_code_utf16_le) catch |err| switch (err) { + const source_code_utf8 = std.unicode.utf16LeToUtf8AllocZ(allocator, source_code_utf16_le) catch |err| switch (err) { error.DanglingSurrogateHalf => error.UnsupportedEncoding, error.ExpectedSecondSurrogateHalf => error.UnsupportedEncoding, error.UnexpectedSecondSurrogateHalf => error.UnsupportedEncoding, |
