2020-01-13 16:41:11 -06:00
|
|
|
error: this boolean expression can be simplified
|
2022-06-30 03:50:09 -05:00
|
|
|
--> $DIR/nonminimal_bool.rs:11:13
|
2020-01-13 16:41:11 -06:00
|
|
|
|
|
|
|
|
LL | let _ = !true;
|
|
|
|
| ^^^^^ help: try: `false`
|
|
|
|
|
|
|
|
|
= note: `-D clippy::nonminimal-bool` implied by `-D warnings`
|
|
|
|
|
|
|
|
error: this boolean expression can be simplified
|
2022-06-30 03:50:09 -05:00
|
|
|
--> $DIR/nonminimal_bool.rs:12:13
|
2020-01-13 16:41:11 -06:00
|
|
|
|
|
|
|
|
LL | let _ = !false;
|
|
|
|
| ^^^^^^ help: try: `true`
|
|
|
|
|
|
|
|
error: this boolean expression can be simplified
|
2022-06-30 03:50:09 -05:00
|
|
|
--> $DIR/nonminimal_bool.rs:13:13
|
2020-01-13 16:41:11 -06:00
|
|
|
|
|
|
|
|
LL | let _ = !!a;
|
|
|
|
| ^^^ help: try: `a`
|
|
|
|
|
|
|
|
error: this boolean expression can be simplified
|
2022-06-30 03:50:09 -05:00
|
|
|
--> $DIR/nonminimal_bool.rs:14:13
|
2020-01-13 16:41:11 -06:00
|
|
|
|
|
|
|
|
LL | let _ = false || a;
|
|
|
|
| ^^^^^^^^^^ help: try: `a`
|
|
|
|
|
|
|
|
error: this boolean expression can be simplified
|
2022-06-30 03:50:09 -05:00
|
|
|
--> $DIR/nonminimal_bool.rs:18:13
|
2020-01-13 16:41:11 -06:00
|
|
|
|
|
|
|
|
LL | let _ = !(!a && b);
|
|
|
|
| ^^^^^^^^^^ help: try: `a || !b`
|
|
|
|
|
|
|
|
error: this boolean expression can be simplified
|
2022-06-30 03:50:09 -05:00
|
|
|
--> $DIR/nonminimal_bool.rs:19:13
|
2020-01-13 16:41:11 -06:00
|
|
|
|
|
|
|
|
LL | let _ = !(!a || b);
|
|
|
|
| ^^^^^^^^^^ help: try: `a && !b`
|
|
|
|
|
|
|
|
error: this boolean expression can be simplified
|
2022-06-30 03:50:09 -05:00
|
|
|
--> $DIR/nonminimal_bool.rs:20:13
|
2020-01-13 16:41:11 -06:00
|
|
|
|
|
|
|
|
LL | let _ = !a && !(b && c);
|
|
|
|
| ^^^^^^^^^^^^^^^ help: try: `!(a || b && c)`
|
|
|
|
|
|
|
|
error: this boolean expression can be simplified
|
2022-06-30 03:50:09 -05:00
|
|
|
--> $DIR/nonminimal_bool.rs:28:13
|
2020-01-13 16:41:11 -06:00
|
|
|
|
|
|
|
|
LL | let _ = a == b && c == 5 && a == b;
|
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^^
|
|
|
|
|
|
|
|
|
help: try
|
|
|
|
|
|
|
|
|
LL | let _ = !(a != b || c != 5);
|
2021-08-11 09:21:33 -05:00
|
|
|
| ~~~~~~~~~~~~~~~~~~~
|
2021-10-01 13:09:31 -05:00
|
|
|
LL | let _ = a == b && c == 5;
|
|
|
|
| ~~~~~~~~~~~~~~~~
|
2020-01-13 16:41:11 -06:00
|
|
|
|
|
|
|
error: this boolean expression can be simplified
|
2022-06-30 03:50:09 -05:00
|
|
|
--> $DIR/nonminimal_bool.rs:29:13
|
2020-01-13 16:41:11 -06:00
|
|
|
|
|
|
|
|
LL | let _ = a == b || c == 5 || a == b;
|
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^^
|
|
|
|
|
|
|
|
|
help: try
|
|
|
|
|
|
|
|
|
LL | let _ = !(a != b && c != 5);
|
2021-08-11 09:21:33 -05:00
|
|
|
| ~~~~~~~~~~~~~~~~~~~
|
2021-10-01 13:09:31 -05:00
|
|
|
LL | let _ = a == b || c == 5;
|
|
|
|
| ~~~~~~~~~~~~~~~~
|
2020-01-13 16:41:11 -06:00
|
|
|
|
|
|
|
error: this boolean expression can be simplified
|
2022-06-30 03:50:09 -05:00
|
|
|
--> $DIR/nonminimal_bool.rs:30:13
|
2020-01-13 16:41:11 -06:00
|
|
|
|
|
|
|
|
LL | let _ = a == b && c == 5 && b == a;
|
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^^
|
|
|
|
|
|
|
|
|
help: try
|
|
|
|
|
|
|
|
|
LL | let _ = !(a != b || c != 5);
|
2021-08-11 09:21:33 -05:00
|
|
|
| ~~~~~~~~~~~~~~~~~~~
|
2021-10-01 13:09:31 -05:00
|
|
|
LL | let _ = a == b && c == 5;
|
|
|
|
| ~~~~~~~~~~~~~~~~
|
2020-01-13 16:41:11 -06:00
|
|
|
|
|
|
|
error: this boolean expression can be simplified
|
2022-06-30 03:50:09 -05:00
|
|
|
--> $DIR/nonminimal_bool.rs:31:13
|
2020-01-13 16:41:11 -06:00
|
|
|
|
|
|
|
|
LL | let _ = a != b || !(a != b || c == d);
|
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
|
|
|
|
|
|
|
|
help: try
|
|
|
|
|
|
|
|
|
LL | let _ = !(a == b && c == d);
|
2021-08-11 09:21:33 -05:00
|
|
|
| ~~~~~~~~~~~~~~~~~~~
|
2021-10-01 13:09:31 -05:00
|
|
|
LL | let _ = a != b || c != d;
|
|
|
|
| ~~~~~~~~~~~~~~~~
|
2020-01-13 16:41:11 -06:00
|
|
|
|
|
|
|
error: this boolean expression can be simplified
|
2022-06-30 03:50:09 -05:00
|
|
|
--> $DIR/nonminimal_bool.rs:32:13
|
2020-01-13 16:41:11 -06:00
|
|
|
|
|
|
|
|
LL | let _ = a != b && !(a != b && c == d);
|
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
|
|
|
|
|
|
|
|
help: try
|
|
|
|
|
|
|
|
|
LL | let _ = !(a == b || c == d);
|
2021-08-11 09:21:33 -05:00
|
|
|
| ~~~~~~~~~~~~~~~~~~~
|
2021-10-01 13:09:31 -05:00
|
|
|
LL | let _ = a != b && c != d;
|
|
|
|
| ~~~~~~~~~~~~~~~~
|
2020-01-13 16:41:11 -06:00
|
|
|
|
2022-09-21 12:02:37 -05:00
|
|
|
error: this boolean expression can be simplified
|
|
|
|
--> $DIR/nonminimal_bool.rs:62:8
|
|
|
|
|
|
|
|
|
LL | if matches!(true, true) && true {
|
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `matches!(true, true)`
|
|
|
|
|
|
|
|
error: aborting due to 13 previous errors
|
2020-01-13 16:41:11 -06:00
|
|
|
|