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

Fix cfgs #441

Merged
merged 1 commit into from
Jan 7, 2025
Merged

Fix cfgs #441

merged 1 commit into from
Jan 7, 2025

Conversation

kornelski
Copy link
Contributor

Fixes #440

I've grouped combinations of features for each library as one-liners, so that they can be copy'n'pasted to where they're needed, without having to have a SAT solver in your head.

Unfortunately macros can't wrap struct fields, so cfg-if can't help here.

Verified with cargo-hack that all 239 combinations of feature flags compile okay:

cargo hack --feature-powerset --exclude-no-default-features --skip any_impl,any_zlib check

Copy link
Member

@Byron Byron left a comment

Choose a reason for hiding this comment

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

Thanks so much for your help and for sharing your insights earlier.

This should mean that all currently supported backends remain as they all offer certain benefits.

And when looking at the complexity of the cfg attributes, we'd probably also avoid picking up more backends 😅.

@Byron Byron merged commit d922817 into rust-lang:main Jan 7, 2025
14 checks passed
@kornelski kornelski deleted the cfgs branch January 7, 2025 11:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

zlib-rs and cloudflare_zlib features conflict
2 participants