authorgravatar for hello@nektro.netMeghan Denny <hello@nektro.net> 2026-06-04 20:12:22 -07:00
committergravatar for hello@nektro.netMeghan Denny <hello@nektro.net> 2026-06-04 20:12:22 -07:00
log5a7d257bf4ea983f504fbdd32b236a93aacff715
tree06bba0f7a79f0b4a2d45d98c14d320c4a309e002
parentdb70f7e35558c0df34cce0497ec0eea8e984d30d
signaturebadge-check Signed by SSH key SHA256:4hHJbtBRU58AYXwjL7fkz2fnQHdiye8x1QpTCQ0sHNw

update to zig 0.16.0

ran the tests this time

7 files changed, 11 insertions(+), 10 deletions(-)

src/FieldUnion.zig+3-3
......@@ -5,9 +5,9 @@ const expectSimilarType = extras.expectSimilarType;
55
66pub fn FieldUnion(comptime T: type) type {
77 const fields = std.meta.fields(T);
8 var names: [fields.fields.len][]const u8 = undefined;
9 var types: [fields.fields.len]type = undefined;
10 var attrs: [fields.fields.len]std.builtin.Type.UnionField.Attributes = undefined;
8 var names: [fields.len][]const u8 = undefined;
9 var types: [fields.len]type = undefined;
10 var attrs: [fields.len]std.builtin.Type.UnionField.Attributes = undefined;
1111
1212 inline for (fields, 0..) |field, i| {
1313 names[i] = field.name;
src/FlippedInt.zig+1-1
......@@ -9,7 +9,7 @@ pub fn FlippedInt(comptime T: type) type {
99 .signed => .unsigned,
1010 .unsigned => .signed,
1111 },
12 info.signedness,
12 info.bits,
1313 );
1414}
1515
src/ManyArrayList.zig+2-2
......@@ -10,8 +10,8 @@ pub fn ManyArrayList(T: type) type {
1010 pub fn init(allocator: std.mem.Allocator) @This() {
1111 return .{
1212 .allocator = allocator,
13 .list = .{},
14 .lengths = .{},
13 .list = .empty,
14 .lengths = .empty,
1515 };
1616 }
1717
src/StructOfArrays.zig+1
......@@ -12,6 +12,7 @@ pub fn StructOfArrays(len: usize, T: type) type {
1212 names[i] = item.name;
1313 types[i] = [len]item.type;
1414 }
15 if (info.is_tuple) return @Tuple(&types);
1516 return @Struct(.auto, null, &names, &types, &@splat(.{}));
1617}
1718
src/StructOfSlices.zig+1
......@@ -12,6 +12,7 @@ pub fn StructOfSlices(T: type) type {
1212 names[i] = item.name;
1313 types[i] = []const item.type;
1414 }
15 if (info.is_tuple) return @Tuple(&types);
1516 return @Struct(.auto, null, &names, &types, &@splat(.{}));
1617}
1718
src/join.zig+3-3
......@@ -14,13 +14,13 @@ pub fn join(input: anytype) Join(@TypeOf(input)) {
1414}
1515
1616pub fn Join(comptime T: type) type {
17 var names: [][]const u8 = &.{};
18 var types: []type = &.{};
17 var names: []const []const u8 = &.{};
18 var types: []const type = &.{};
1919 inline for (std.meta.fields(T)) |item| {
2020 inline for (std.meta.fields(item.type)) |f| {
2121 names = names ++ &[_][]const u8{f.name};
2222 types = types ++ &[_]type{f.type};
2323 }
2424 }
25 return @Struct(.auto, null, &names, &types, &@splat(.{}));
25 return @Struct(.auto, null, names, types[0..], &@splat(.{}));
2626}
src/omit.zig-1
......@@ -31,5 +31,4 @@ pub fn Omit(T: type, field_name: []const u8) type {
3131 i += 1;
3232 }
3333 return @Struct(.auto, null, &names, &types, &attrs);
34 // return @Type(.{ .@"struct" = .{ .layout = .auto, .fields = &fields, .decls = &.{}, .is_tuple = false } });
3534}