2020-01-13 22:41:11 +00:00
|
|
|
error: this boolean expression can be simplified
|
2023-12-16 16:40:32 +00:00
|
|
|
--> $DIR/nonminimal_bool.rs:18:13
|
2020-01-13 22:41:11 +00:00
|
|
|
|
|
|
|
|
LL | let _ = !true;
|
|
|
|
| ^^^^^ help: try: `false`
|
|
|
|
|
|
|
|
|
= note: `-D clippy::nonminimal-bool` implied by `-D warnings`
|
2023-08-01 12:02:21 +00:00
|
|
|
= help: to override `-D warnings` add `#[allow(clippy::nonminimal_bool)]`
|
2020-01-13 22:41:11 +00:00
|
|
|
|
|
|
|
error: this boolean expression can be simplified
|
2023-12-16 16:40:32 +00:00
|
|
|
--> $DIR/nonminimal_bool.rs:21:13
|
2020-01-13 22:41:11 +00:00
|
|
|
|
|
|
|
|
LL | let _ = !false;
|
|
|
|
| ^^^^^^ help: try: `true`
|
|
|
|
|
|
|
|
error: this boolean expression can be simplified
|
2023-12-16 16:40:32 +00:00
|
|
|
--> $DIR/nonminimal_bool.rs:23:13
|
2020-01-13 22:41:11 +00:00
|
|
|
|
|
|
|
|
LL | let _ = !!a;
|
|
|
|
| ^^^ help: try: `a`
|
|
|
|
|
|
|
|
error: this boolean expression can be simplified
|
2023-12-16 16:40:32 +00:00
|
|
|
--> $DIR/nonminimal_bool.rs:25:13
|
2020-01-13 22:41:11 +00:00
|
|
|
|
|
|
|
|
LL | let _ = false || a;
|
|
|
|
| ^^^^^^^^^^ help: try: `a`
|
|
|
|
|
|
|
|
error: this boolean expression can be simplified
|
2023-12-16 16:40:32 +00:00
|
|
|
--> $DIR/nonminimal_bool.rs:30:13
|
2020-01-13 22:41:11 +00:00
|
|
|
|
|
|
|
|
LL | let _ = !(!a && b);
|
|
|
|
| ^^^^^^^^^^ help: try: `a || !b`
|
|
|
|
|
|
|
|
error: this boolean expression can be simplified
|
2023-12-16 16:40:32 +00:00
|
|
|
--> $DIR/nonminimal_bool.rs:32:13
|
2020-01-13 22:41:11 +00:00
|
|
|
|
|
|
|
|
LL | let _ = !(!a || b);
|
|
|
|
| ^^^^^^^^^^ help: try: `a && !b`
|
|
|
|
|
|
|
|
error: this boolean expression can be simplified
|
2023-12-16 16:40:32 +00:00
|
|
|
--> $DIR/nonminimal_bool.rs:34:13
|
2020-01-13 22:41:11 +00:00
|
|
|
|
|
|
|
|
LL | let _ = !a && !(b && c);
|
|
|
|
| ^^^^^^^^^^^^^^^ help: try: `!(a || b && c)`
|
|
|
|
|
|
|
|
error: this boolean expression can be simplified
|
2023-12-16 16:40:32 +00:00
|
|
|
--> $DIR/nonminimal_bool.rs:43:13
|
2020-01-13 22:41:11 +00:00
|
|
|
|
|
|
|
|
LL | let _ = a == b && c == 5 && a == b;
|
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^^
|
|
|
|
|
|
|
|
|
help: try
|
|
|
|
|
|
|
|
|
LL | let _ = !(a != b || c != 5);
|
2021-08-11 14:21:33 +00:00
|
|
|
| ~~~~~~~~~~~~~~~~~~~
|
2021-10-01 18:09:31 +00:00
|
|
|
LL | let _ = a == b && c == 5;
|
|
|
|
| ~~~~~~~~~~~~~~~~
|
2020-01-13 22:41:11 +00:00
|
|
|
|
|
|
|
error: this boolean expression can be simplified
|
2023-12-16 16:40:32 +00:00
|
|
|
--> $DIR/nonminimal_bool.rs:45:13
|
2020-01-13 22:41:11 +00:00
|
|
|
|
|
|
|
|
LL | let _ = a == b || c == 5 || a == b;
|
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^^
|
|
|
|
|
|
|
|
|
help: try
|
|
|
|
|
|
|
|
|
LL | let _ = !(a != b && c != 5);
|
2021-08-11 14:21:33 +00:00
|
|
|
| ~~~~~~~~~~~~~~~~~~~
|
2021-10-01 18:09:31 +00:00
|
|
|
LL | let _ = a == b || c == 5;
|
|
|
|
| ~~~~~~~~~~~~~~~~
|
2020-01-13 22:41:11 +00:00
|
|
|
|
|
|
|
error: this boolean expression can be simplified
|
2023-12-16 16:40:32 +00:00
|
|
|
--> $DIR/nonminimal_bool.rs:47:13
|
2020-01-13 22:41:11 +00:00
|
|
|
|
|
|
|
|
LL | let _ = a == b && c == 5 && b == a;
|
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^^
|
|
|
|
|
|
|
|
|
help: try
|
|
|
|
|
|
|
|
|
LL | let _ = !(a != b || c != 5);
|
2021-08-11 14:21:33 +00:00
|
|
|
| ~~~~~~~~~~~~~~~~~~~
|
2021-10-01 18:09:31 +00:00
|
|
|
LL | let _ = a == b && c == 5;
|
|
|
|
| ~~~~~~~~~~~~~~~~
|
2020-01-13 22:41:11 +00:00
|
|
|
|
|
|
|
error: this boolean expression can be simplified
|
2023-12-16 16:40:32 +00:00
|
|
|
--> $DIR/nonminimal_bool.rs:49:13
|
2020-01-13 22:41:11 +00:00
|
|
|
|
|
|
|
|
LL | let _ = a != b || !(a != b || c == d);
|
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
|
|
|
|
|
|
|
|
help: try
|
|
|
|
|
|
|
|
|
LL | let _ = !(a == b && c == d);
|
2021-08-11 14:21:33 +00:00
|
|
|
| ~~~~~~~~~~~~~~~~~~~
|
2021-10-01 18:09:31 +00:00
|
|
|
LL | let _ = a != b || c != d;
|
|
|
|
| ~~~~~~~~~~~~~~~~
|
2020-01-13 22:41:11 +00:00
|
|
|
|
|
|
|
error: this boolean expression can be simplified
|
2023-12-16 16:40:32 +00:00
|
|
|
--> $DIR/nonminimal_bool.rs:51:13
|
2020-01-13 22:41:11 +00:00
|
|
|
|
|
|
|
|
LL | let _ = a != b && !(a != b && c == d);
|
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
|
|
|
|
|
|
|
|
help: try
|
|
|
|
|
|
|
|
|
LL | let _ = !(a == b || c == d);
|
2021-08-11 14:21:33 +00:00
|
|
|
| ~~~~~~~~~~~~~~~~~~~
|
2021-10-01 18:09:31 +00:00
|
|
|
LL | let _ = a != b && c != d;
|
|
|
|
| ~~~~~~~~~~~~~~~~
|
2020-01-13 22:41:11 +00:00
|
|
|
|
2022-09-21 17:02:37 +00:00
|
|
|
error: this boolean expression can be simplified
|
2023-12-16 16:40:32 +00:00
|
|
|
--> $DIR/nonminimal_bool.rs:82:8
|
2022-09-21 17:02:37 +00:00
|
|
|
|
|
|
|
|
LL | if matches!(true, true) && true {
|
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `matches!(true, true)`
|
|
|
|
|
|
|
|
error: aborting due to 13 previous errors
|
2020-01-13 22:41:11 +00:00
|
|
|
|