-
Notifications
You must be signed in to change notification settings - Fork 13k
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
--cap-lints=warn are "ignored" in RUSTDOCFLAGS #67533
Comments
Transferred to |
We are still getting bitten by this. Especially because some projects appear to apply stricter linting settings to their doctests / example code snippets in doc comments than they do in their actual code ... |
IMO, That said, some projects will not follow best practices, so there should still be a way to deal with that. I'm not quite sure what happens here -- doesn't the |
Rollup merge of rust-lang#128780 - GuillaumeGomez:rustflags-doctests, r=rustdoc Add `--doctest-compilation-args` option to add compilation flags to doctest compilation Fixes rust-lang#67533. Tracking issue: rust-lang#134172 It's been something I meant to take a look at for a long time and actually completely forgot... The idea is to allow to give more control over how doctests are compiled to users. To do so, this PR adds a new `--doctest-compilation-args` option which provides extra compilation flags. r? `@notriddle`
Problem
I am trying to package async-std crates for Fedora and that includes running tests for them. I learned that they fail because
#![feature(async_await)]
is used. We are passing--cap-lints=warn
in RUSTFLAGS, but that seems to be not enough. I have tried setting RUSTDOCFLAGS to pass this argument, but that does not seem to be respected.Steps
--cap-lints=warn
in RUSTFLAGS and RUSTDOCFLAGSPossible Solution(s)
I did not look into the code, but I believe it just does not get propagated somewhere.
Notes
Output of
cargo version
:cargo 1.39.0
This is happening on x86_64 on Fedora with its compiler, but I am pretty sure this will happen with rustup compiler too.
The text was updated successfully, but these errors were encountered: