Comment by int_19h
3 months ago
If you want an unsafe union, that's what StructLayout.Explicit and FieldOffset is for - a struct with all fields placed at offset 0 is exactly the same as a C union.
3 months ago
If you want an unsafe union, that's what StructLayout.Explicit and FieldOffset is for - a struct with all fields placed at offset 0 is exactly the same as a C union.
No comments yet
Contribute on Hacker News ↗