-
Notifications
You must be signed in to change notification settings - Fork 12.9k
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
tarpaulin
and check-cfg
#127271
Comments
@barafael I tried reproducing the issue locally but I'm unable to do so. I created a new Cargo project added [package]
name = "my_lib"
version = "0.1.0"
edition = "2021"
[dependencies]
+ [lints.rust]
+ unexpected_cfgs = { level = "warn", check-cfg = ['cfg(tarpaulin_include)'] } and the re-did Did you check on |
This is "tarpaulin".
And this adds "tarpaulin_include" , not "tarpaulin". |
correct, my bad. It's #![cfg(not(tarpaulin_include))] |
@Urgau never mind, I got confused, all works as expected. Thanks! |
Some of the crates I'm developing use
as recommended here: Ignoring Code in Files (Tarpaulin Readme)
It seems other projects do this too: GitHub Code Search
The recommended Cargo Toml section:
does not fix this.
Neither does:
because:
Maybe this should be done differently on tarpaulin's side, or I can just edit my build.rs. But maybe this should be supported.
Originally posted by @barafael in #124800 (comment)
The text was updated successfully, but these errors were encountered: