-
-
Notifications
You must be signed in to change notification settings - Fork 54
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add support for specifying the ID's endianness #337
base: master
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the submission, could you add tests?
You've peaked my interest, is this a public data-format? Sounds funky. |
deku-derive/src/lib.rs
Outdated
@@ -203,6 +207,8 @@ impl DekuData { | |||
Err(cerror(data.id_type.span(), "`type` only supported on enum")) | |||
} else if data.id.is_some() { | |||
Err(cerror(data.id.span(), "`id` only supported on enum")) | |||
} else if data.id_endian.is_some() { | |||
Err(cerror(data.id.span(), "`endian_id` only supported on enum")) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think the error message should say id_endian
?
I've not stared at Miri output much before, but the failures I examined do not appear to be related to the changes I made. |
Yah, we really should disable those, or just disable the ones we know fail? Miri doesn't really like bitvec, and I don't think those issues will be fixed anytime soon. |
Doesn't propagate any further down the dependency tree, *only* affects ID parsing.
I've got a need to specify the endianness of a discriminator, without having that propagate to substructures. Hence this little change.
Great crate, BTW; well-documented and easy to use!