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
Is there any way to add custom derives to the helper struct? Adding __BindgenBitfieldUnit to with-derive-custom-struct doesn't seem to do anything, no matter how I tweak the regex to describe the template.
I would absolutely believe that this is not possible, in which case I would stick with a manually defined struct definition in rust.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
I have a bindgen cli question regarding structs that have bitfields.
Let's say I have a C struct that uses bitfields, e.g.
The generated rust code defines a helper struct that looks like this:
Is there any way to add custom derives to the helper struct? Adding
__BindgenBitfieldUnit
towith-derive-custom-struct
doesn't seem to do anything, no matter how I tweak the regex to describe the template.I would absolutely believe that this is not possible, in which case I would stick with a manually defined struct definition in rust.
Beta Was this translation helpful? Give feedback.
All reactions