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 encoding warning on compilation #119

Open
phillord opened this issue Nov 12, 2024 · 1 comment · May be fixed by #120
Open

Fix encoding warning on compilation #119

phillord opened this issue Nov 12, 2024 · 1 comment · May be fixed by #120

Comments

@phillord
Copy link
Owner

Looks likely to be as a result of a change in the linter/compiler.

warning: unexpected `cfg` condition value: `quick-xml/encoding`
   --> src/io/owx/reader.rs:122:11
    |
122 |     #[cfg(feature = "quick-xml/encoding")]
    |           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = note: expected values for `feature` are: `default`, `remote`, and `ureq`
    = help: consider adding `quick-xml/encoding` as a feature in `Cargo.toml`
    = note: see <https://doc.rust-lang.org/nightly/rustc/check-cfg/cargo-specifics.html> for more information about checking conditional configuration
    = note: `#[warn(unexpected_cfgs)]` on by default
@filippodebortoli
Copy link
Collaborator

From the Cargo Book:

Features of dependencies can also be enabled in the [features] table. The syntax is "package-name/feature-name". For example:

[dependencies]
jpeg-decoder = { version = "0.1.20", default-features = false }

[features]
# Enables parallel processing support by enabling the "rayon" feature of jpeg-decoder.
parallel = ["jpeg-decoder/rayon"]

It should be sufficient to add encoding = ["quick-xml/encoding"] in Cargo.toml and then invoke #[cfg(feature = "encoding")].

@filippodebortoli filippodebortoli linked a pull request Nov 13, 2024 that will close this issue
@filippodebortoli filippodebortoli linked a pull request Nov 13, 2024 that will close this issue
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 a pull request may close this issue.

2 participants