You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
e.g. If I have a packed struct with comptime parametized types, I don't want to have things not work when a field is passed as void/u0/struct{}. Instead, the offset should be right where it is (note that this differs from C where a 0-sized field aligns to the next byte boundary)
With the decision in #6706, pointers to zero-sized values are now real pointers. This also means that offset and alignment will behave as described in this issue.
e.g. If I have a packed struct with comptime parametized types, I don't want to have things not work when a field is passed as
void
/u0
/struct{}
. Instead, the offset should be right where it is (note that this differs from C where a 0-sized field aligns to the next byte boundary)Another use case for this is helping to create structs with trailing data:
The text was updated successfully, but these errors were encountered: