11error: this let-binding has unit value
2- --> $DIR/let_unit.rs:14 :5
2+ --> $DIR/let_unit.rs:15 :5
33 |
44LL | let _x = println!("x");
55 | ^^^^^^^^^^^^^^^^^^^^^^^ help: omit the `let` binding: `println!("x");`
66 |
77 = note: `-D clippy::let-unit-value` implied by `-D warnings`
88
99error: this let-binding has unit value
10- --> $DIR/let_unit.rs:18 :9
10+ --> $DIR/let_unit.rs:19 :9
1111 |
1212LL | let _a = ();
1313 | ^^^^^^^^^^^^ help: omit the `let` binding: `();`
1414
1515error: this let-binding has unit value
16- --> $DIR/let_unit.rs:53 :5
16+ --> $DIR/let_unit.rs:54 :5
1717 |
1818LL | / let _ = v
1919LL | | .into_iter()
@@ -36,55 +36,55 @@ LL + .unwrap();
3636 |
3737
3838error: this let-binding has unit value
39- --> $DIR/let_unit.rs:80 :5
39+ --> $DIR/let_unit.rs:81 :5
4040 |
4141LL | let x: () = f(); // Lint.
4242 | ^^^^-^^^^^^^^^^^
4343 | |
4444 | help: use a wild (`_`) binding: `_`
4545
4646error: this let-binding has unit value
47- --> $DIR/let_unit.rs:83 :5
47+ --> $DIR/let_unit.rs:84 :5
4848 |
4949LL | let x: () = f2(0i32); // Lint.
5050 | ^^^^-^^^^^^^^^^^^^^^^
5151 | |
5252 | help: use a wild (`_`) binding: `_`
5353
5454error: this let-binding has unit value
55- --> $DIR/let_unit.rs:85 :5
55+ --> $DIR/let_unit.rs:86 :5
5656 |
5757LL | let _: () = f3(()); // Lint
5858 | ^^^^^^^^^^^^^^^^^^^ help: omit the `let` binding: `f3(());`
5959
6060error: this let-binding has unit value
61- --> $DIR/let_unit.rs:86 :5
61+ --> $DIR/let_unit.rs:87 :5
6262 |
6363LL | let x: () = f3(()); // Lint
6464 | ^^^^^^^^^^^^^^^^^^^ help: omit the `let` binding: `f3(());`
6565
6666error: this let-binding has unit value
67- --> $DIR/let_unit.rs:88 :5
67+ --> $DIR/let_unit.rs:89 :5
6868 |
6969LL | let _: () = f4(vec![()]); // Lint
7070 | ^^^^^^^^^^^^^^^^^^^^^^^^^ help: omit the `let` binding: `f4(vec![()]);`
7171
7272error: this let-binding has unit value
73- --> $DIR/let_unit.rs:89 :5
73+ --> $DIR/let_unit.rs:90 :5
7474 |
7575LL | let x: () = f4(vec![()]); // Lint
7676 | ^^^^^^^^^^^^^^^^^^^^^^^^^ help: omit the `let` binding: `f4(vec![()]);`
7777
7878error: this let-binding has unit value
79- --> $DIR/let_unit.rs:98 :5
79+ --> $DIR/let_unit.rs:99 :5
8080 |
8181LL | let x: () = if true { f() } else { f2(0) }; // Lint
8282 | ^^^^-^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
8383 | |
8484 | help: use a wild (`_`) binding: `_`
8585
8686error: this let-binding has unit value
87- --> $DIR/let_unit.rs:109 :5
87+ --> $DIR/let_unit.rs:110 :5
8888 |
8989LL | / let _: () = match Some(0) {
9090LL | | None => f2(1),
0 commit comments