Quoting Daurnimator (2021-11-14 19:00:47) > Some misc notes: > > - I recall issues with using zig structs, as there is no way to e.g. > little-endian integer type > - Zig doesn't have anonymous fields > - Things would be nicer with https://github.com/ziglang/zig/issues/6478
Yeah, I would not try to map capnproto structs directly to language-native structs, except as part of an up-front parsing API for performance-insensitive use. The normal thing is to just define wrapper types with accessors. Note that even with control over layout, a struct's data section can be shorter or longer than what the compiled schema suggests, so you still end up needing to do a bounds check. -Ian -- You received this message because you are subscribed to the Google Groups "Cap'n Proto" group. To unsubscribe from this group and stop receiving emails from it, send an email to capnproto+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/capnproto/163693481988.21999.7071930045347154952%40localhost.localdomain.