We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
cargo dev fmt
1 parent 2b93d2c commit 1f36d4dCopy full SHA for 1f36d4d
clippy_lints/src/exit.rs
@@ -43,7 +43,9 @@ declare_lint_pass!(Exit => [EXIT]);
43
44
impl<'tcx> LateLintPass<'tcx> for Exit {
45
fn check_expr(&mut self, cx: &LateContext<'tcx>, e: &'tcx Expr<'_>) {
46
- if cx.sess().is_test_crate() { return; }
+ if cx.sess().is_test_crate() {
47
+ return;
48
+ }
49
50
if let ExprKind::Call(path_expr, [_]) = e.kind
51
&& let ExprKind::Path(ref path) = path_expr.kind
tests/ui/exit4.rs
@@ -5,4 +5,4 @@
5
6
fn main() {
7
std::process::exit(0)
8
-}
+}
0 commit comments