-
Notifications
You must be signed in to change notification settings - Fork 226
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
inherent gpio methods #1284
inherent gpio methods #1284
Conversation
Thanks for the PR. We're still discussing what we're going to do regarding the various I think given our current implementations that this PR is completely reasonable, however I think I would prefer to come to a decision regarding |
3bded44
to
aba68bc
Compare
Maybe we could split this PR into two bits, the inherent infallible methods on the GPIO structs and the eh trait refactoring? Imo the inherent infallible methods we can accept now, before figuring out what to do with the traits. |
I like the idea of putting the hal implementations into modules |
Rebased. |
I very much don't, but guess I won't be too stubborn about it. I'd like some guarantee that all of the other modules implementing these traits will be updated, because otherwise I have a feeling I will have to do this myself. |
Is problem in |
I personally like to have it in modules - I don't like to have it in different files t.b.h. |
At the end of the day it's largely just a matter of consistency, I guess my personal preferences don't matter as much (I seem to be in the minority as is often the case, anyway). I've been putting a lot of work into trying to make our code base more consistent (this is still ongoing), and this feels like a step backwards unless these changes are made for all applicable modules. I think it's reasonable for contributors to expect our drivers to be structured in similar ways, and I can see having only one or two driver like this causing confusion (or, we'll have to explain to contributors constantly what is expected in this regard). Given the above, it follows that we should also split out modules for all other third-party trait packages, and this seems tedious and like a lot of work for essentially zero tangible gain. But, I won't argue any more about this I suppose. Just my $0.02 |
Is now better? |
0fed74b
to
2c9f9fb
Compare
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.
From my perspective, this LGTM. I'm a big fan of the infallible inherent methods, and I'm indifferent about the module layout, though I think cfg gated modules in the same file is a nice compromise between the two approaches.
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.
LGTM
3e957bf
to
913a63a
Compare
Rebased. |
Sorry @burrbull, could you also update the tests inside |
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!
See #1273 (comment)