]> git.lizzy.rs Git - rust.git/blob - tests/ui/swap.stderr
Merge pull request #1748 from luisbg/empty_lines
[rust.git] / tests / ui / swap.stderr
1 error: this looks like you are swapping elements of `foo` manually
2   --> $DIR/swap.rs:11:5
3    |
4 11 | /     let temp = foo[0];
5 12 | |     foo[0] = foo[1];
6 13 | |     foo[1] = temp;
7    | |_________________^ help: try `foo.swap(0, 1)`
8    |
9    = note: #[deny(manual_swap)] implied by #[deny(clippy)]
10 note: lint level defined here
11   --> $DIR/swap.rs:4:9
12    |
13 4  | #![deny(clippy)]
14    |         ^^^^^^
15
16 error: this looks like you are swapping elements of `foo` manually
17   --> $DIR/swap.rs:20:5
18    |
19 20 | /     let temp = foo[0];
20 21 | |     foo[0] = foo[1];
21 22 | |     foo[1] = temp;
22    | |_________________^ help: try `foo.swap(0, 1)`
23    |
24    = note: #[deny(manual_swap)] implied by #[deny(clippy)]
25
26 error: this looks like you are swapping elements of `foo` manually
27   --> $DIR/swap.rs:29:5
28    |
29 29 | /     let temp = foo[0];
30 30 | |     foo[0] = foo[1];
31 31 | |     foo[1] = temp;
32    | |_________________^ help: try `foo.swap(0, 1)`
33    |
34    = note: #[deny(manual_swap)] implied by #[deny(clippy)]
35
36 error: this looks like you are swapping `a` and `b` manually
37   --> $DIR/swap.rs:47:7
38    |
39 47 |       ; let t = a;
40    |  _______^
41 48 | |     a = b;
42 49 | |     b = t;
43    | |_________^ help: try `std::mem::swap(&mut a, &mut b)`
44    |
45    = note: #[deny(manual_swap)] implied by #[deny(clippy)]
46    = note: or maybe you should use `std::mem::replace`?
47
48 error: this looks like you are swapping `c.0` and `a` manually
49   --> $DIR/swap.rs:56:7
50    |
51 56 |       ; let t = c.0;
52    |  _______^
53 57 | |     c.0 = a;
54 58 | |     a = t;
55    | |_________^ help: try `std::mem::swap(&mut c.0, &mut a)`
56    |
57    = note: #[deny(manual_swap)] implied by #[deny(clippy)]
58    = note: or maybe you should use `std::mem::replace`?
59
60 error: this looks like you are trying to swap `a` and `b`
61   --> $DIR/swap.rs:44:5
62    |
63 44 | /     a = b;
64 45 | |     b = a;
65    | |_________^ help: try `std::mem::swap(&mut a, &mut b)`
66    |
67    = note: #[deny(almost_swapped)] implied by #[deny(clippy)]
68 note: lint level defined here
69   --> $DIR/swap.rs:4:9
70    |
71 4  | #![deny(clippy)]
72    |         ^^^^^^
73    = note: or maybe you should use `std::mem::replace`?
74
75 error: this looks like you are trying to swap `c.0` and `a`
76   --> $DIR/swap.rs:53:5
77    |
78 53 | /     c.0 = a;
79 54 | |     a = c.0;
80    | |___________^ help: try `std::mem::swap(&mut c.0, &mut a)`
81    |
82    = note: #[deny(almost_swapped)] implied by #[deny(clippy)]
83    = note: or maybe you should use `std::mem::replace`?
84
85 error: aborting due to 7 previous errors
86