-
Notifications
You must be signed in to change notification settings - Fork 240
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 derive for the GPIO structures #861
Conversation
Older versions contain a soundness bug.
…tate spi: remove undesired parameter to `set_format`
Adding more Could you apply the same changes to rp235x-hal? It would be great if we could keep the two hal implementations as similar as possible. |
CI failed due to a new warning in rustc 1.82.0. |
Since rust 1.82.0, addr_of is no longer unsafe: rust-lang/rust#125834 Just removing the unsafe statement would break builds with older versions of rust. Instead, allow the unused_unsafe lint.
Fix warning with rust 1.82.0
Update critical-section dependency to version 1.2.0
@robamu can you rebase? |
I can do that |
This PR picked up a lot of unrelated commits. Maybe we can fix it by doing a rebase when we merge. The diff itself looks fine. |
I think the pull request looks a bit strange because @robamu merged with main instead of rebasing. Git should handle that fine. Worst case the history will have a few unnecessary branch points, but yes, "rebase and merge" should avoid even that. |
This is a port of rp-rs#861 to rp235x-hal
Is there a general problem adding these derives to more structures? I am trying to use a driver for a LCD display, and I can not unwrap the returned result structure because Debug is not implemented by the pin structures used by the driver. This applies to both the concrete pins and the downgraded pins.
These were only the derives I needed to pass both dyn pins and concrete pins to the driver. There are probably a lot more structures where t his derive could be added.