This would change the way you could define record descriptors. It brings a couple of benefits:
- Ability to document fields with actual docstrings
- Type hinting support for IDE’s
Note: adjust the documentation accordingly
This needs research into the how. keep in mind what we learned form cstruct V4 - regarding code generation.
In cstruct data classes have methods e.g. comparison operators, look at cstruct techniques how to implement these.
The solution needs to flatten the structure: data class def becomes the record descriptor. instances of the data class becomes the records