@@ -5,15 +5,15 @@ LL | -1 % 2;
5
5
| ^^^^^^
6
6
|
7
7
= note: `-D clippy::modulo-arithmetic` implied by `-D warnings`
8
- = note: double check for expected result especially when interoperating with different languages
8
+ = note: double check for expected result especially when interoperating with different languages or consider using `rem_euclid` or similar function
9
9
10
10
error: you are using modulo operator on constants with different signs: `1 % -2`
11
11
--> $DIR/modulo_arithmetic.rs:14:5
12
12
|
13
13
LL | 1 % -2;
14
14
| ^^^^^^
15
15
|
16
- = note: double check for expected result especially when interoperating with different languages
16
+ = note: double check for expected result especially when interoperating with different languages or consider using `rem_euclid` or similar function
17
17
18
18
error: you are using modulo operator on constants with different signs: `-1.600 % 2.100`
19
19
--> $DIR/modulo_arithmetic.rs:15:5
@@ -37,15 +37,15 @@ error: you are using modulo operator on constants with different signs: `-1 % 3`
37
37
LL | (1 - 2) % (1 + 2);
38
38
| ^^^^^^^^^^^^^^^^^
39
39
|
40
- = note: double check for expected result especially when interoperating with different languages
40
+ = note: double check for expected result especially when interoperating with different languages or consider using `rem_euclid` or similar function
41
41
42
42
error: you are using modulo operator on constants with different signs: `3 % -1`
43
43
--> $DIR/modulo_arithmetic.rs:18:5
44
44
|
45
45
LL | (1 + 2) % (1 - 2);
46
46
| ^^^^^^^^^^^^^^^^^
47
47
|
48
- = note: double check for expected result especially when interoperating with different languages
48
+ = note: double check for expected result especially when interoperating with different languages or consider using `rem_euclid` or similar function
49
49
50
50
error: you are using modulo operator on constants with different signs: `-1.200 % 3.400`
51
51
--> $DIR/modulo_arithmetic.rs:19:5
@@ -69,127 +69,127 @@ error: you are using modulo operator on constants with different signs: `-35 % 3
69
69
LL | 35 * (7 - 4 * 2) % (-500 * -600);
70
70
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
71
71
|
72
- = note: double check for expected result especially when interoperating with different languages
72
+ = note: double check for expected result especially when interoperating with different languages or consider using `rem_euclid` or similar function
73
73
74
74
error: you are using modulo operator on constants with different signs: `-1 % 2`
75
75
--> $DIR/modulo_arithmetic.rs:23:5
76
76
|
77
77
LL | -1i8 % 2i8;
78
78
| ^^^^^^^^^^
79
79
|
80
- = note: double check for expected result especially when interoperating with different languages
80
+ = note: double check for expected result especially when interoperating with different languages or consider using `rem_euclid` or similar function
81
81
82
82
error: you are using modulo operator on constants with different signs: `1 % -2`
83
83
--> $DIR/modulo_arithmetic.rs:24:5
84
84
|
85
85
LL | 1i8 % -2i8;
86
86
| ^^^^^^^^^^
87
87
|
88
- = note: double check for expected result especially when interoperating with different languages
88
+ = note: double check for expected result especially when interoperating with different languages or consider using `rem_euclid` or similar function
89
89
90
90
error: you are using modulo operator on constants with different signs: `-1 % 2`
91
91
--> $DIR/modulo_arithmetic.rs:25:5
92
92
|
93
93
LL | -1i16 % 2i16;
94
94
| ^^^^^^^^^^^^
95
95
|
96
- = note: double check for expected result especially when interoperating with different languages
96
+ = note: double check for expected result especially when interoperating with different languages or consider using `rem_euclid` or similar function
97
97
98
98
error: you are using modulo operator on constants with different signs: `1 % -2`
99
99
--> $DIR/modulo_arithmetic.rs:26:5
100
100
|
101
101
LL | 1i16 % -2i16;
102
102
| ^^^^^^^^^^^^
103
103
|
104
- = note: double check for expected result especially when interoperating with different languages
104
+ = note: double check for expected result especially when interoperating with different languages or consider using `rem_euclid` or similar function
105
105
106
106
error: you are using modulo operator on constants with different signs: `-1 % 2`
107
107
--> $DIR/modulo_arithmetic.rs:27:5
108
108
|
109
109
LL | -1i32 % 2i32;
110
110
| ^^^^^^^^^^^^
111
111
|
112
- = note: double check for expected result especially when interoperating with different languages
112
+ = note: double check for expected result especially when interoperating with different languages or consider using `rem_euclid` or similar function
113
113
114
114
error: you are using modulo operator on constants with different signs: `1 % -2`
115
115
--> $DIR/modulo_arithmetic.rs:28:5
116
116
|
117
117
LL | 1i32 % -2i32;
118
118
| ^^^^^^^^^^^^
119
119
|
120
- = note: double check for expected result especially when interoperating with different languages
120
+ = note: double check for expected result especially when interoperating with different languages or consider using `rem_euclid` or similar function
121
121
122
122
error: you are using modulo operator on constants with different signs: `-1 % 2`
123
123
--> $DIR/modulo_arithmetic.rs:29:5
124
124
|
125
125
LL | -1i64 % 2i64;
126
126
| ^^^^^^^^^^^^
127
127
|
128
- = note: double check for expected result especially when interoperating with different languages
128
+ = note: double check for expected result especially when interoperating with different languages or consider using `rem_euclid` or similar function
129
129
130
130
error: you are using modulo operator on constants with different signs: `1 % -2`
131
131
--> $DIR/modulo_arithmetic.rs:30:5
132
132
|
133
133
LL | 1i64 % -2i64;
134
134
| ^^^^^^^^^^^^
135
135
|
136
- = note: double check for expected result especially when interoperating with different languages
136
+ = note: double check for expected result especially when interoperating with different languages or consider using `rem_euclid` or similar function
137
137
138
138
error: you are using modulo operator on constants with different signs: `-1 % 2`
139
139
--> $DIR/modulo_arithmetic.rs:31:5
140
140
|
141
141
LL | -1i128 % 2i128;
142
142
| ^^^^^^^^^^^^^^
143
143
|
144
- = note: double check for expected result especially when interoperating with different languages
144
+ = note: double check for expected result especially when interoperating with different languages or consider using `rem_euclid` or similar function
145
145
146
146
error: you are using modulo operator on constants with different signs: `1 % -2`
147
147
--> $DIR/modulo_arithmetic.rs:32:5
148
148
|
149
149
LL | 1i128 % -2i128;
150
150
| ^^^^^^^^^^^^^^
151
151
|
152
- = note: double check for expected result especially when interoperating with different languages
152
+ = note: double check for expected result especially when interoperating with different languages or consider using `rem_euclid` or similar function
153
153
154
154
error: you are using modulo operator on constants with different signs: `-1 % 2`
155
155
--> $DIR/modulo_arithmetic.rs:33:5
156
156
|
157
157
LL | -1isize % 2isize;
158
158
| ^^^^^^^^^^^^^^^^
159
159
|
160
- = note: double check for expected result especially when interoperating with different languages
160
+ = note: double check for expected result especially when interoperating with different languages or consider using `rem_euclid` or similar function
161
161
162
162
error: you are using modulo operator on constants with different signs: `1 % -2`
163
163
--> $DIR/modulo_arithmetic.rs:34:5
164
164
|
165
165
LL | 1isize % -2isize;
166
166
| ^^^^^^^^^^^^^^^^
167
167
|
168
- = note: double check for expected result especially when interoperating with different languages
168
+ = note: double check for expected result especially when interoperating with different languages or consider using `rem_euclid` or similar function
169
169
170
170
error: you are using modulo operator on types that might have different signs
171
171
--> $DIR/modulo_arithmetic.rs:39:5
172
172
|
173
173
LL | a % b;
174
174
| ^^^^^
175
175
|
176
- = note: double check for expected result especially when interoperating with different languages
176
+ = note: double check for expected result especially when interoperating with different languages or consider using `rem_euclid` or similar function
177
177
178
178
error: you are using modulo operator on types that might have different signs
179
179
--> $DIR/modulo_arithmetic.rs:40:5
180
180
|
181
181
LL | b % a;
182
182
| ^^^^^
183
183
|
184
- = note: double check for expected result especially when interoperating with different languages
184
+ = note: double check for expected result especially when interoperating with different languages or consider using `rem_euclid` or similar function
185
185
186
186
error: you are using modulo operator on types that might have different signs
187
187
--> $DIR/modulo_arithmetic.rs:41:5
188
188
|
189
189
LL | b %= a;
190
190
| ^^^^^^
191
191
|
192
- = note: double check for expected result especially when interoperating with different languages
192
+ = note: double check for expected result especially when interoperating with different languages or consider using `rem_euclid` or similar function
193
193
194
194
error: you are using modulo operator on types that might have different signs
195
195
--> $DIR/modulo_arithmetic.rs:45:5
@@ -245,15 +245,15 @@ error: you are using modulo operator on types that might have different signs
245
245
LL | a % b;
246
246
| ^^^^^
247
247
|
248
- = note: double check for expected result especially when interoperating with different languages
248
+ = note: double check for expected result especially when interoperating with different languages or consider using `rem_euclid` or similar function
249
249
250
250
error: you are using modulo operator on types that might have different signs
251
251
--> $DIR/modulo_arithmetic.rs:58:5
252
252
|
253
253
LL | b %= a;
254
254
| ^^^^^^
255
255
|
256
- = note: double check for expected result especially when interoperating with different languages
256
+ = note: double check for expected result especially when interoperating with different languages or consider using `rem_euclid` or similar function
257
257
258
258
error: aborting due to 32 previous errors
259
259
0 commit comments