1 error: statement can be reduced
2 --> $DIR/unnecessary_operation.rs:45:5
4 LL | Tuple(get_number());
5 | ^^^^^^^^^^^^^^^^^^^^ help: replace it with: `get_number();`
7 = note: `-D clippy::unnecessary-operation` implied by `-D warnings`
9 error: statement can be reduced
10 --> $DIR/unnecessary_operation.rs:46:5
12 LL | Struct { field: get_number() };
13 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace it with: `get_number();`
15 error: statement can be reduced
16 --> $DIR/unnecessary_operation.rs:47:5
18 LL | Struct { ..get_struct() };
19 | ^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace it with: `get_struct();`
21 error: statement can be reduced
22 --> $DIR/unnecessary_operation.rs:48:5
24 LL | Enum::Tuple(get_number());
25 | ^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace it with: `get_number();`
27 error: statement can be reduced
28 --> $DIR/unnecessary_operation.rs:49:5
30 LL | Enum::Struct { field: get_number() };
31 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace it with: `get_number();`
33 error: statement can be reduced
34 --> $DIR/unnecessary_operation.rs:50:5
36 LL | 5 + get_number();
37 | ^^^^^^^^^^^^^^^^^ help: replace it with: `5;get_number();`
39 error: statement can be reduced
40 --> $DIR/unnecessary_operation.rs:51:5
43 | ^^^^^^^^^^^^^^^ help: replace it with: `get_number();`
45 error: statement can be reduced
46 --> $DIR/unnecessary_operation.rs:52:5
49 | ^^^^^^^^^^^^^^ help: replace it with: `get_number();`
51 error: statement can be reduced
52 --> $DIR/unnecessary_operation.rs:53:5
54 LL | (5, 6, get_number());
55 | ^^^^^^^^^^^^^^^^^^^^^ help: replace it with: `5;6;get_number();`
57 error: statement can be reduced
58 --> $DIR/unnecessary_operation.rs:54:5
60 LL | box get_number();
61 | ^^^^^^^^^^^^^^^^^ help: replace it with: `get_number();`
63 error: statement can be reduced
64 --> $DIR/unnecessary_operation.rs:55:5
67 | ^^^^^^^^^^^^^^^ help: replace it with: `get_number();`
69 error: statement can be reduced
70 --> $DIR/unnecessary_operation.rs:56:5
73 | ^^^^^^^^^^^^^^^ help: replace it with: `get_number();`
75 error: statement can be reduced
76 --> $DIR/unnecessary_operation.rs:57:5
79 | ^^^^^^^^^^^^^^^^ help: replace it with: `5;get_number();`
81 error: statement can be reduced
82 --> $DIR/unnecessary_operation.rs:58:5
84 LL | [42, get_number()];
85 | ^^^^^^^^^^^^^^^^^^^ help: replace it with: `42;get_number();`
87 error: statement can be reduced
88 --> $DIR/unnecessary_operation.rs:59:5
90 LL | [42, 55][get_number() as usize];
91 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace it with: `[42, 55];get_number() as usize;`
93 error: statement can be reduced
94 --> $DIR/unnecessary_operation.rs:60:5
96 LL | (42, get_number()).1;
97 | ^^^^^^^^^^^^^^^^^^^^^ help: replace it with: `42;get_number();`
99 error: statement can be reduced
100 --> $DIR/unnecessary_operation.rs:61:5
102 LL | [get_number(); 55];
103 | ^^^^^^^^^^^^^^^^^^^ help: replace it with: `get_number();`
105 error: statement can be reduced
106 --> $DIR/unnecessary_operation.rs:62:5
108 LL | [42; 55][get_number() as usize];
109 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace it with: `[42; 55];get_number() as usize;`
111 error: statement can be reduced
112 --> $DIR/unnecessary_operation.rs:63:5
117 | |______^ help: replace it with: `get_number();`
119 error: statement can be reduced
120 --> $DIR/unnecessary_operation.rs:66:5
123 LL | | s: String::from("blah"),
125 | |______^ help: replace it with: `String::from("blah");`
127 error: aborting due to 20 previous errors