diff options
author | 2023-04-14 03:58:38 -0700 | |
---|---|---|
committer | 2023-04-14 03:58:38 -0700 | |
commit | f6a4516d667f7cf000fb2e3123d29079a5ced272 (patch) | |
tree | 4f108bdbd550f6bc05e5e06814c8b271e8ce8d13 /src/string_immutable.zig | |
parent | 6c69c2b36462100792bb3d1b23aba8afbee0253f (diff) | |
download | bun-f6a4516d667f7cf000fb2e3123d29079a5ced272.tar.gz bun-f6a4516d667f7cf000fb2e3123d29079a5ced272.tar.zst bun-f6a4516d667f7cf000fb2e3123d29079a5ced272.zip |
Upgrade Zig (#2656)
* Upgrade Zig
* Don't add `d` files in github actions
* Revert "Don't add `d` files in github actions"
This reverts commit 446e2dd6743da08ec4136233fdc9179dbbf58fca.
---------
Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com>
Diffstat (limited to 'src/string_immutable.zig')
-rw-r--r-- | src/string_immutable.zig | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/src/string_immutable.zig b/src/string_immutable.zig index 44d64dc49..887d819a1 100644 --- a/src/string_immutable.zig +++ b/src/string_immutable.zig @@ -24,7 +24,7 @@ pub inline fn contains(self: string, str: string) bool { } pub fn toUTF16Literal(comptime str: []const u8) []const u16 { - comptime { + return comptime brk: { comptime var output: [str.len]u16 = undefined; for (str, 0..) |c, i| { @@ -34,9 +34,8 @@ pub fn toUTF16Literal(comptime str: []const u8) []const u16 { const Static = struct { pub const literal: []const u16 = output[0..]; }; - - return Static.literal; - } + break :brk Static.literal; + }; } const OptionalUsize = std.meta.Int(.unsigned, @bitSizeOf(usize) - 1); |