technocreatives / dbc-codegen

Generate Rust structs for messages from a dbc (CAN bus definition) file.
Apache License 2.0
48 stars 27 forks source link

Implement From and Into for enums #30

Closed marcelbuesing closed 3 years ago

marcelbuesing commented 3 years ago

The basic idea is to allow extraction of raw values from enums. So my hope was there would be actually some magic blanket implementation for Into. If there is a better way to avoid explicitly generating Into implementations please let me know.

killercup commented 3 years ago

rebased on main and merged as b58eb62e627f0215032259c78a45f2852fad3a8e :)

marcelbuesing commented 3 years ago

Thanks for also integrating the float matching changes !