Skip to content
Myr

Ignore logic_bug Clippy lint in test

Before adoption: this commit came in with the history the project adopted, so no landing records it.

error: this boolean expression contains a logic bug --> tests/test_ensure.rs:96:30 | 96 | let test = || Ok(ensure!(false == true && false)); | ^^^^^^^^^^^^^^^^^^^^^^ help: it would look like the following: `false` | = note: `-D clippy::logic-bug` implied by `-D clippy::all` help: this expression can be optimized out by applying boolean operations to the outer expression --> tests/test_ensure.rs:96:30 | 96 | let test = || Ok(ensure!(false == true && false)); | ^^^^^^^^^^^^^ = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#logic_bug

authored by David Tolnay · committed by David Tolnay · parent f4956a1 · Browse files · 1 file+1 added−0 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

1 file+1 added−0 removed

  • tests:+1 added−0 removed

1 file+1 added−0 removed

modified:tests/test_ensure.rs+1 added
3 unmodified lines
4 clippy::ifs_same_cond,5 clippy::items_after_statements,6 clippy::let_and_return,7 clippy::let_underscore_drop,8 clippy::logic_bug,9 clippy::match_bool,10 clippy::never_loop,11 clippy::redundant_closure_call,12 clippy::redundant_pattern_matching,
673 unmodified lines