diff --git a/Cargo.toml b/Cargo.toml index 2b5f598c2c..f22503416b 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -251,13 +251,12 @@ void = "1.0.2" zstd = "0.13.1" [workspace.lints.rust] -future-incompatible = "deny" -nonstandard-style = "deny" -rust-2018-idioms = "deny" +future-incompatible = "warn" +nonstandard-style = "warn" +rust-2018-idioms = "warn" # See [here](https://github.com/taiki-e/cargo-llvm-cov/issues/370) for a discussion on why this is # needed (from rust 1.80). unexpected_cfgs = { level = "warn", check-cfg = ['cfg(coverage_nightly)'] } -warnings = "deny" [workspace.lints.clippy] -as_conversions = "deny" +as_conversions = "warn" diff --git a/scripts/clippy.sh b/scripts/clippy.sh deleted file mode 100755 index 3eaef6844c..0000000000 --- a/scripts/clippy.sh +++ /dev/null @@ -1,8 +0,0 @@ -#!/bin/bash - -# TODO: Revert clippy::unwrap_used to -D after fixing all the unwraps. -cargo clippy --all-targets --all-features $@ -- \ - -D future-incompatible \ - -D nonstandard-style \ - -D rust-2018-idioms \ - -D unused \ diff --git a/scripts/run_tests.py b/scripts/run_tests.py index 6f20328809..8efd79a5f3 100755 --- a/scripts/run_tests.py +++ b/scripts/run_tests.py @@ -24,7 +24,7 @@ class BaseCommand(Enum): DOC = "doc" def cmd(self, crates: Set[str]) -> List[str]: - package_args = [] + package_args = ["-Dwarnings"] # Don't remove `-Dwarnings`, otherwise warnings will merge. for package in crates: package_args.extend(["--package", package]) @@ -44,7 +44,7 @@ def cmd(self, crates: Set[str]) -> List[str]: return ["scripts/rust_fmt.sh"] + fmt_args + ["--", "--check"] elif self == BaseCommand.CLIPPY: clippy_args = package_args if len(package_args) > 0 else ["--workspace"] - return ["scripts/clippy.sh"] + clippy_args + return ["cargo", "clippy"] + clippy_args elif self == BaseCommand.DOC: doc_args = package_args if len(package_args) > 0 else ["--workspace"] return ["cargo", "doc", "-r", "--document-private-items", "--no-deps"] + doc_args