]> git.lizzy.rs Git - rust.git/blob - tests/ui/temporary_assignment.stderr
Auto merge of #5522 - CrazyRoka:match_vec_item, r=phansch
[rust.git] / tests / ui / temporary_assignment.stderr
1 error: assignment to temporary
2   --> $DIR/temporary_assignment.rs:47:5
3    |
4 LL |     Struct { field: 0 }.field = 1;
5    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
6    |
7    = note: `-D clippy::temporary-assignment` implied by `-D warnings`
8
9 error: assignment to temporary
10   --> $DIR/temporary_assignment.rs:48:5
11    |
12 LL | /     MultiStruct {
13 LL | |         structure: Struct { field: 0 },
14 LL | |     }
15 LL | |     .structure
16 LL | |     .field = 1;
17    | |______________^
18
19 error: assignment to temporary
20   --> $DIR/temporary_assignment.rs:53:5
21    |
22 LL |     ArrayStruct { array: [0] }.array[0] = 1;
23    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
24
25 error: assignment to temporary
26   --> $DIR/temporary_assignment.rs:54:5
27    |
28 LL |     (0, 0).0 = 1;
29    |     ^^^^^^^^^^^^
30
31 error: assignment to temporary
32   --> $DIR/temporary_assignment.rs:56:5
33    |
34 LL |     A.0 = 2;
35    |     ^^^^^^^
36
37 error: assignment to temporary
38   --> $DIR/temporary_assignment.rs:57:5
39    |
40 LL |     B.field = 2;
41    |     ^^^^^^^^^^^
42
43 error: assignment to temporary
44   --> $DIR/temporary_assignment.rs:58:5
45    |
46 LL |     C.structure.field = 2;
47    |     ^^^^^^^^^^^^^^^^^^^^^
48
49 error: assignment to temporary
50   --> $DIR/temporary_assignment.rs:59:5
51    |
52 LL |     D.array[0] = 2;
53    |     ^^^^^^^^^^^^^^
54
55 error: aborting due to 8 previous errors
56