-
Notifications
You must be signed in to change notification settings - Fork 7
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 Debug and defmt::Format impls for fieldsets and interrupt enums. #9
Conversation
#[repr(transparent)] | ||
#[derive(Copy, Clone, Eq, PartialEq)] | ||
pub struct Perfctr(pub u32); | ||
impl Perfctr { | ||
#[doc = "Busfabric saturating performance counter 2 Count some event signal from the busfabric arbiters. Write any value to clear. Select an event to count using PERFSEL2"] | ||
#[doc = "Busfabric saturating performance counter 0 Count some event signal from the busfabric arbiters. Write any value to clear. Select an event to count using PERFSEL0"] |
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.
For example: Here 2 was replaced with 0.
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.
yep, this is expected, it's ok
e62169b
to
7f6d97d
Compare
tested build times (ryzen 9 7950x):
tested with defmt doubles the build time, wow! Shows how slow proc macros are, I think it's OK since it's optional, but I'm not sure if enabling thanks! |
@Dirbaio: Hmm good point. My initial goal with this was to get the What do you think about adding a Then the high-level crate can do: [features]
defmt = ["dep:defmt", "pac/defmt-interrupt"] |
i'm not sure if it's worth splitting like that. Someone else will want defmt for spi enums, someone else for gpio enums, we're not going to add maybe the HALs could have a |
I kinda agree, but the reason I think Since the |
This PR regenerates the PAC with the latest
chiptool
and adds adefmt
feature.Follow up for embassy-rs/chiptool#44
Some numbers in the documentation changed apart from the new impls. I think this is due to
chiptool
switching to a BTreeMap instead of a HashMap, to ensure reproducible builds. So I guess this shouldn't happen anymore in the future.