Opt into c2rust per item#66
Merged
Merged
Conversation
While this will initially break everything, later commits can go through the actually used parts and make them opt-in.
f578aa8 to
8f8e257
Compare
8f8e257 to
460f257
Compare
chrysn
added a commit
to chrysn-pull-requests/RIOT
that referenced
this pull request
May 1, 2026
chrysn
added a commit
to RIOT-OS/rust-riot-wrappers
that referenced
this pull request
May 12, 2026
… as I'm not sure whether the -sys tests really cover all the same tests (should all move to murdock)
chrysn
added a commit
to chrysn-pull-requests/RIOT
that referenced
this pull request
May 12, 2026
chrysn
added a commit
to chrysn-pull-requests/RIOT
that referenced
this pull request
May 12, 2026
Member
Author
|
I've given this some testing through RIOT-OS/rust-riot-wrappers#154 and trying it on the riot-examples, so I think this is the right path -- and now that 0.8 is in main, it is becoming mergeable. The implementation is not too confidence-inspiring (creating a single non-static function just to pull the static functions into the translation), but it kind'a fits the style of the c2rust parts in that … well, it works even though it's not pretty. The bindgen patch doesn't really fit with the rest (although it fits the theme of making things work for native again); are reviewers OK with that or should I split the PR? |
maribu
approved these changes
May 13, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
#55 and its sibling #65 are limited by even IWYU pulling in lots of idioms.
Maybe we can get rid of what was probably a mistake in 2020: including everything (which was done because the items we need are all static functions or macros, and there's no "public" declaration).