Skip to content

Commit 45412c5

Browse files
committed
Use RUSTFLAGS to deny warnings in check.rs.
1 parent ff50391 commit 45412c5

3 files changed

Lines changed: 7 additions & 9 deletions

File tree

Cargo.toml

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -41,9 +41,6 @@ serde = "1.0.228"
4141
toml = "0.9.8"
4242
wildmatch = "2.5.0"
4343

44-
[features]
45-
fatal-warnings = []
46-
4744
[lib]
4845
# Disable libtest benchmarks so we can use criterion flags (see https://bheisler.github.io/criterion.rs/book/faq.html
4946
# and https://github.com/rust-lang/rust/issues/47241).

src/lib.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@
1313
// limitations under the License.
1414

1515
#![no_std]
16-
#![cfg_attr(feature = "fatal-warnings", deny(warnings))]
1716
// Note: If you change this remember to update `README.md`. To do so run `cargo rdme`.
1817
//! `wildcard` is a rust crate for wildcard matching.
1918
//!

tools/check.sh

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -20,11 +20,13 @@ assert_installed "cargo"
2020

2121
trap on_failure ERR
2222

23+
export RUSTFLAGS="-Dwarnings"
24+
2325
function check_basic {
2426
echo 'Building:'
25-
cargo build --features fatal-warnings --all-targets
27+
cargo build --all-targets --all-features
2628
echo 'Testing:'
27-
SHORT_BENCH=1 cargo test --all-features --all-targets --benches
29+
SHORT_BENCH=1 cargo test --all-features --all-targets --benches
2830
# We test property-based tests will a much higher number of testcases. We need to compile this with the release profile,
2931
# otherwise this would be very slow.
3032
echo 'Testing property-based tests for longer:'
@@ -33,11 +35,11 @@ function check_basic {
3335
# doc tests like this.
3436
# See https://github.com/rust-lang/cargo/issues/6669.
3537
echo 'Testing doc:'
36-
cargo test --features fatal-warnings --doc
38+
cargo test --doc --all-features
3739
echo 'Checking the benchmarks:'
38-
cargo bench --features fatal-warnings -- --test
40+
cargo bench --all-features -- --test
3941
echo 'Checking documentation:'
40-
cargo doc --features fatal-warnings --no-deps
42+
cargo doc --no-deps --all-features
4143
}
4244

4345
function check_doc_url_links {

0 commit comments

Comments
 (0)