Skip to content
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

refactor(embassy::net): Enable building without actual driver #495

Merged
merged 3 commits into from
Oct 29, 2024

Conversation

chrysn
Copy link
Collaborator

@chrysn chrysn commented Oct 29, 2024

Description

The net module used to not get linted and documented because its code depends on some driver to be present.

This adds an uninhabited dummy driver, which gets selected unless anything else is.

Issues/PRs references

#493 will create a module that should be documented and linted but that depends on net.

There was some prior discussion of this in the riot-rs channel. The alternative to the dummy approach was to gate the #[cfg(feature="net")] part of riot-rs-embassy -- but that would hide that code from the linter, and the linter promptly did find something to enhance.

Change checklist

  • I have cleaned up my commit history and squashed fixup commits.
  • I have followed the Coding Conventions.
  • I have performed a self-review of my own code.
  • I have made corresponding changes to the documentation.

Fixup commits are initally left in because @ROMemories already saw the first of these commits.

@chrysn chrysn marked this pull request as ready for review October 29, 2024 14:49
Copy link
Collaborator

@ROMemories ROMemories left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Couple of nits and we're good!

I'll add the missing doc comments on the network items in a follow-up PR.

src/riot-rs-embassy/src/lib.rs Outdated Show resolved Hide resolved
src/riot-rs-embassy/src/network.rs Outdated Show resolved Hide resolved
@chrysn
Copy link
Collaborator Author

chrysn commented Oct 29, 2024

Thanks, all in and squashed.

@ROMemories ROMemories added this pull request to the merge queue Oct 29, 2024
Merged via the queue into future-proof-iot:main with commit 5b9abee Oct 29, 2024
26 checks passed
@chrysn chrysn deleted the net-linting branch October 29, 2024 15:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants