1 error: unneeded late initalization
2 --> $DIR/needless_late_init.rs:4:5
7 = note: `-D clippy::needless-late-init` implied by `-D warnings`
10 LL | let a = match n {
12 help: remove the assignments from the `match` arms
18 help: add a semicolon after the `match` expression
23 error: unneeded late initalization
24 --> $DIR/needless_late_init.rs:13:5
29 help: declare `b` here
31 LL | let b = if n == 3 {
33 help: remove the assignments from the branches
39 help: add a semicolon after the `if` expression
44 error: unneeded late initalization
45 --> $DIR/needless_late_init.rs:20:5
50 help: declare `c` here
52 LL | let c = if let Some(n) = Some(5) {
54 help: remove the assignments from the branches
60 help: add a semicolon after the `if` expression
65 error: unneeded late initalization
66 --> $DIR/needless_late_init.rs:27:5
71 help: declare `d` here
73 LL | let d = if true {
75 help: remove the assignments from the branches
81 help: add a semicolon after the `if` expression
86 error: unneeded late initalization
87 --> $DIR/needless_late_init.rs:35:5
92 help: declare `e` here
94 LL | let e = if true {
96 help: remove the assignments from the branches
98 LL ~ format!("{} {}", a, b)
100 LL ~ format!("{}", c)
102 help: add a semicolon after the `if` expression
107 error: unneeded late initalization
108 --> $DIR/needless_late_init.rs:50:5
113 help: declare `a` here
115 LL | let a = match n {
117 help: remove the assignments from the `match` arms
123 help: add a semicolon after the `match` expression
128 error: unneeded late initalization
129 --> $DIR/needless_late_init.rs:67:5
134 help: declare `a` here
136 LL | let a = match n {
138 help: remove the assignments from the `match` arms
144 help: add a semicolon after the `match` expression
149 error: aborting due to 7 previous errors