I know about offset_of in field_offset - Rust , which for structs, allows me to get the offset of arbitrary fields.
Is there something similar for enum? I want to be able to extract:
the 'tag' bits, representing which 'arm' of the enum we go with
for each 'arm' of the enum, somehow extract the offset of the tuple elements
Is there someway to pull this data? (I'm okay with crates, macros, procedural macros, etc ...)
[ imagine you want C to be able to read a Rust enum ]