-
Couldn't load subscription status.
- Fork 4
Add no_std support to remaining crates
#65
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
Conversation
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.
I've added a little more structure to how ShuffleOps brings in architecture specific optimisations. This helps with feature flags and should be easier to maintain.
❤️
texel/src/image/raw.rs
Outdated
|
|
||
| /// Methods specifically with a dynamic layout. | ||
| impl<B> RawImage<B, DynLayout> { | ||
| #[expect(dead_code)] |
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.
Actually I don't expect this, this is an artifact of ongoing development work and should get linted as a nit that it needs to go, or be used (before the next release). Same with the Yuv420p` layout and so on. Rather have those as a separate PR (please amend the commit instead of just adding one on top, to avoid merge conflicts with my branch that does touch some of these lints).
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.
Tried editing that particular commit directly but I think that didn't work as you'd like. If there's any issues with the history as-is just let me know and I can re-open this PR on a clean branch instead.
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.
I can also squash-and-merge so no worries, it'd just have been neater.
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.
So if you're not comfortable with that workflow in git before you can also just add commits and let me know to squash. We lose the history of individual commits but should be the same result.
|
Thank you a lot for the feedback on no_std needs. Went ahead and did the minor nits. All the activity around me at RustWeek is making me uncharacteristically wired. |
Objective
no_stdsupport improves compatibility with the Rust ecosystem, in everything from Rust-for-Linux through to embedded and high-compatibility WASM.Solution
no_stdtoimage-canvasno_stdtoimage-drmlibmdependency toimage-canvasfor float operations withoutstd. This is a high-quality library provided byrust-langthemselves.runtime-featuresfeature toimage-canvasfor performing runtime feature detection (requiresstd).std.Notes
ShuffleOpsbrings in architecture specific optimisations. This helps with feature flags and should be easier to maintain.libmfeature as I suspect it may be required even more-so in the future of this crate. The alternative of inlining apowfimplementation or additional conditional compilation seems undesirable to me.