authorgravatar for hello@nektro.netMeghan Denny <hello@nektro.net> 2026-06-08 13:15:37 -07:00
committergravatar for hello@nektro.netMeghan Denny <hello@nektro.net> 2026-06-08 13:15:37 -07:00
log2ada45d2e6c295a556cd8092f860630f07caf0d1
treef033d7c220629e22737de717e5fa1bc902731711
parent5a7d257bf4ea983f504fbdd32b236a93aacff715
signaturebadge-check Signed by SSH key SHA256:4hHJbtBRU58AYXwjL7fkz2fnQHdiye8x1QpTCQ0sHNw

ReverseFields: maintain struct's layout


1 files changed, 1 insertions(+), 1 deletions(-)

src/ReverseFields.zig+1-1
...@@ -12,7 +12,7 @@ pub fn ReverseFields(comptime T: type) type {...@@ -12,7 +12,7 @@ pub fn ReverseFields(comptime T: type) type {
12 names[i] = info.fields[len - 1 - i].name;12 names[i] = info.fields[len - 1 - i].name;
13 types[i] = info.fields[len - 1 - i].type;13 types[i] = info.fields[len - 1 - i].type;
14 }14 }
15 return @Struct(.auto, null, &names, &types, &@splat(.{}));15 return @Struct(info.layout, null, &names, &types, &@splat(.{}));
16}16}
1717
18test {18test {