We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 9a3b0a0 + 34c75cf commit 7c56c74Copy full SHA for 7c56c74
tests/ui/implicit_saturating_sub.stderr
@@ -1,3 +1,11 @@
1
+error: this arithmetic operation will overflow
2
+ --> $DIR/implicit_saturating_sub.rs:31:25
3
+ |
4
+LL | let mut u_16: u16 = end_16 - start_16;
5
+ | ^^^^^^^^^^^^^^^^^ attempt to subtract with overflow
6
7
+ = note: `#[deny(arithmetic_overflow)]` on by default
8
+
9
error: Implicitly performing saturating subtraction
10
--> $DIR/implicit_saturating_sub.rs:13:5
11
|
@@ -184,5 +192,5 @@ LL | | i_64 -= 1;
184
192
LL | | }
185
193
| |_____^ help: try: `i_64 = i_64.saturating_sub(1);`
186
194
187
-error: aborting due to 23 previous errors
195
+error: aborting due to 24 previous errors
188
196
0 commit comments