diff options
| author | Joseph Richey <joerichey@google.com> | 2020-11-04 03:27:30 -0800 |
|---|---|---|
| committer | flip1995 <philipp.krones@embecosm.com> | 2020-11-08 12:38:10 +0100 |
| commit | 3579b7de24df6a617322ec07eae98618ef57e5ee (patch) | |
| tree | bcc08d1920c4f6ffa36c9fb0bd321bb28303fe8f | |
| parent | c6a91df838b17a2366346db664072d7914ab241a (diff) | |
| download | rust-3579b7de24df6a617322ec07eae98618ef57e5ee.tar.gz rust-3579b7de24df6a617322ec07eae98618ef57e5ee.zip | |
Update clippy_lints/src/loops.rs
Fix NITs Co-authored-by: Philipp Krones <hello@philkrones.com>
| -rw-r--r-- | clippy_lints/src/loops.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/clippy_lints/src/loops.rs b/clippy_lints/src/loops.rs index 2a53210efe3..b246245af24 100644 --- a/clippy_lints/src/loops.rs +++ b/clippy_lints/src/loops.rs @@ -547,9 +547,9 @@ impl<'tcx> LateLintPass<'tcx> for Loops { if block.stmts.is_empty() && block.expr.is_none() && !is_in_panic_handler(cx, expr) { let msg = "empty `loop {}` wastes CPU cycles"; let help = if is_no_std_crate(cx.tcx.hir().krate()) { - "You should either use `panic!()` or add a call pausing or sleeping the thread to the loop body." + "you should either use `panic!()` or add a call pausing or sleeping the thread to the loop body" } else { - "You should either use `panic!()` or add `std::thread::sleep(..);` to the loop body." + "you should either use `panic!()` or add `std::thread::sleep(..);` to the loop body" }; span_lint_and_help(cx, EMPTY_LOOP, expr.span, msg, None, help); } |
