|
1 |
| -error: assign operation detected |
2 |
| - --> $DIR/assign_ops.rs:8:5 |
| 1 | +error: manual implementation of an assign operation |
| 2 | + --> $DIR/assign_ops.rs:5:5 |
3 | 3 | |
|
4 |
| -8 | i += 2; |
5 |
| - | ^^^^^^ help: replace it with: `i = i + 2` |
| 4 | +5 | a = a + 1; |
| 5 | + | ^^^^^^^^^ help: replace it with: `a += 1` |
6 | 6 | |
|
7 |
| - = note: `-D assign-ops` implied by `-D warnings` |
8 |
| - |
9 |
| -error: assign operation detected |
10 |
| - --> $DIR/assign_ops.rs:9:5 |
11 |
| - | |
12 |
| -9 | i += 2 + 17; |
13 |
| - | ^^^^^^^^^^^ help: replace it with: `i = i + 2 + 17` |
14 |
| - |
15 |
| -error: assign operation detected |
16 |
| - --> $DIR/assign_ops.rs:10:5 |
17 |
| - | |
18 |
| -10 | i -= 6; |
19 |
| - | ^^^^^^ help: replace it with: `i = i - 6` |
20 |
| - |
21 |
| -error: assign operation detected |
22 |
| - --> $DIR/assign_ops.rs:11:5 |
23 |
| - | |
24 |
| -11 | i -= 2 - 1; |
25 |
| - | ^^^^^^^^^^ help: replace it with: `i = i - (2 - 1)` |
26 |
| - |
27 |
| -error: assign operation detected |
28 |
| - --> $DIR/assign_ops.rs:12:5 |
29 |
| - | |
30 |
| -12 | i *= 5; |
31 |
| - | ^^^^^^ help: replace it with: `i = i * 5` |
32 |
| - |
33 |
| -error: assign operation detected |
34 |
| - --> $DIR/assign_ops.rs:13:5 |
35 |
| - | |
36 |
| -13 | i *= 1+5; |
37 |
| - | ^^^^^^^^ help: replace it with: `i = i * (1+5)` |
38 |
| - |
39 |
| -error: assign operation detected |
40 |
| - --> $DIR/assign_ops.rs:14:5 |
41 |
| - | |
42 |
| -14 | i /= 32; |
43 |
| - | ^^^^^^^ help: replace it with: `i = i / 32` |
44 |
| - |
45 |
| -error: assign operation detected |
46 |
| - --> $DIR/assign_ops.rs:15:5 |
47 |
| - | |
48 |
| -15 | i /= 32 | 5; |
49 |
| - | ^^^^^^^^^^^ help: replace it with: `i = i / (32 | 5)` |
50 |
| - |
51 |
| -error: assign operation detected |
52 |
| - --> $DIR/assign_ops.rs:16:5 |
53 |
| - | |
54 |
| -16 | i /= 32 / 5; |
55 |
| - | ^^^^^^^^^^^ help: replace it with: `i = i / (32 / 5)` |
56 |
| - |
57 |
| -error: assign operation detected |
58 |
| - --> $DIR/assign_ops.rs:17:5 |
59 |
| - | |
60 |
| -17 | i %= 42; |
61 |
| - | ^^^^^^^ help: replace it with: `i = i % 42` |
62 |
| - |
63 |
| -error: assign operation detected |
64 |
| - --> $DIR/assign_ops.rs:18:5 |
65 |
| - | |
66 |
| -18 | i >>= i; |
67 |
| - | ^^^^^^^ help: replace it with: `i = i >> i` |
68 |
| - |
69 |
| -error: assign operation detected |
70 |
| - --> $DIR/assign_ops.rs:19:5 |
71 |
| - | |
72 |
| -19 | i <<= 9 + 6 - 7; |
73 |
| - | ^^^^^^^^^^^^^^^ help: replace it with: `i = i << (9 + 6 - 7)` |
74 |
| - |
75 |
| -error: assign operation detected |
76 |
| - --> $DIR/assign_ops.rs:20:5 |
77 |
| - | |
78 |
| -20 | i += 1 << 5; |
79 |
| - | ^^^^^^^^^^^ help: replace it with: `i = i + (1 << 5)` |
| 7 | + = note: `-D assign-op-pattern` implied by `-D warnings` |
80 | 8 |
|
81 | 9 | error: manual implementation of an assign operation
|
82 |
| - --> $DIR/assign_ops.rs:27:5 |
83 |
| - | |
84 |
| -27 | a = a + 1; |
85 |
| - | ^^^^^^^^^ help: replace it with: `a += 1` |
86 |
| - | |
87 |
| - = note: `-D assign-op-pattern` implied by `-D warnings` |
88 |
| - |
89 |
| -error: manual implementation of an assign operation |
90 |
| - --> $DIR/assign_ops.rs:28:5 |
91 |
| - | |
92 |
| -28 | a = 1 + a; |
93 |
| - | ^^^^^^^^^ help: replace it with: `a += 1` |
| 10 | + --> $DIR/assign_ops.rs:6:5 |
| 11 | + | |
| 12 | +6 | a = 1 + a; |
| 13 | + | ^^^^^^^^^ help: replace it with: `a += 1` |
94 | 14 |
|
95 | 15 | error: manual implementation of an assign operation
|
96 |
| - --> $DIR/assign_ops.rs:29:5 |
97 |
| - | |
98 |
| -29 | a = a - 1; |
99 |
| - | ^^^^^^^^^ help: replace it with: `a -= 1` |
| 16 | + --> $DIR/assign_ops.rs:7:5 |
| 17 | + | |
| 18 | +7 | a = a - 1; |
| 19 | + | ^^^^^^^^^ help: replace it with: `a -= 1` |
100 | 20 |
|
101 | 21 | error: manual implementation of an assign operation
|
102 |
| - --> $DIR/assign_ops.rs:30:5 |
103 |
| - | |
104 |
| -30 | a = a * 99; |
105 |
| - | ^^^^^^^^^^ help: replace it with: `a *= 99` |
| 22 | + --> $DIR/assign_ops.rs:8:5 |
| 23 | + | |
| 24 | +8 | a = a * 99; |
| 25 | + | ^^^^^^^^^^ help: replace it with: `a *= 99` |
106 | 26 |
|
107 | 27 | error: manual implementation of an assign operation
|
108 |
| - --> $DIR/assign_ops.rs:31:5 |
109 |
| - | |
110 |
| -31 | a = 42 * a; |
111 |
| - | ^^^^^^^^^^ help: replace it with: `a *= 42` |
| 28 | + --> $DIR/assign_ops.rs:9:5 |
| 29 | + | |
| 30 | +9 | a = 42 * a; |
| 31 | + | ^^^^^^^^^^ help: replace it with: `a *= 42` |
112 | 32 |
|
113 | 33 | error: manual implementation of an assign operation
|
114 |
| - --> $DIR/assign_ops.rs:32:5 |
| 34 | + --> $DIR/assign_ops.rs:10:5 |
115 | 35 | |
|
116 |
| -32 | a = a / 2; |
| 36 | +10 | a = a / 2; |
117 | 37 | | ^^^^^^^^^ help: replace it with: `a /= 2`
|
118 | 38 |
|
119 | 39 | error: manual implementation of an assign operation
|
120 |
| - --> $DIR/assign_ops.rs:33:5 |
| 40 | + --> $DIR/assign_ops.rs:11:5 |
121 | 41 | |
|
122 |
| -33 | a = a % 5; |
| 42 | +11 | a = a % 5; |
123 | 43 | | ^^^^^^^^^ help: replace it with: `a %= 5`
|
124 | 44 |
|
125 | 45 | error: manual implementation of an assign operation
|
126 |
| - --> $DIR/assign_ops.rs:34:5 |
| 46 | + --> $DIR/assign_ops.rs:12:5 |
127 | 47 | |
|
128 |
| -34 | a = a & 1; |
| 48 | +12 | a = a & 1; |
129 | 49 | | ^^^^^^^^^ help: replace it with: `a &= 1`
|
130 | 50 |
|
131 | 51 | error: manual implementation of an assign operation
|
132 |
| - --> $DIR/assign_ops.rs:40:5 |
| 52 | + --> $DIR/assign_ops.rs:18:5 |
133 | 53 | |
|
134 |
| -40 | s = s + "bla"; |
| 54 | +18 | s = s + "bla"; |
135 | 55 | | ^^^^^^^^^^^^^ help: replace it with: `s += "bla"`
|
136 | 56 |
|
137 |
| -error: aborting due to 22 previous errors |
| 57 | +error: aborting due to 9 previous errors |
138 | 58 |
|
0 commit comments