fork/rust

git clone https://git.julia.blue/fork/rust

borsAuto merge of #103046 - JanBeh:PR_clarify_cmp_terminology, r=workingjubilee3bcad65fbf6

master
1.6 KiB53 linesraw
1error: you are trying to use classic C overflow conditions that will fail in Rust
2  --> $DIR/overflow_check_conditional.rs:5:8
3   |
4LL |     if a + b < a {}
5   |        ^^^^^^^^^
6   |
7   = note: `-D clippy::overflow-check-conditional` implied by `-D warnings`
8   = help: to override `-D warnings` add `#[allow(clippy::overflow_check_conditional)]`
9
10error: you are trying to use classic C overflow conditions that will fail in Rust
11  --> $DIR/overflow_check_conditional.rs:8:8
12   |
13LL |     if a > a + b {}
14   |        ^^^^^^^^^
15
16error: you are trying to use classic C overflow conditions that will fail in Rust
17  --> $DIR/overflow_check_conditional.rs:10:8
18   |
19LL |     if a + b < b {}
20   |        ^^^^^^^^^
21
22error: you are trying to use classic C overflow conditions that will fail in Rust
23  --> $DIR/overflow_check_conditional.rs:12:8
24   |
25LL |     if b > a + b {}
26   |        ^^^^^^^^^
27
28error: you are trying to use classic C underflow conditions that will fail in Rust
29  --> $DIR/overflow_check_conditional.rs:14:8
30   |
31LL |     if a - b > b {}
32   |        ^^^^^^^^^
33
34error: you are trying to use classic C underflow conditions that will fail in Rust
35  --> $DIR/overflow_check_conditional.rs:16:8
36   |
37LL |     if b < a - b {}
38   |        ^^^^^^^^^
39
40error: you are trying to use classic C underflow conditions that will fail in Rust
41  --> $DIR/overflow_check_conditional.rs:18:8
42   |
43LL |     if a - b > a {}
44   |        ^^^^^^^^^
45
46error: you are trying to use classic C underflow conditions that will fail in Rust
47  --> $DIR/overflow_check_conditional.rs:20:8
48   |
49LL |     if a < a - b {}
50   |        ^^^^^^^^^
51
52error: aborting due to 8 previous errors
53