fork/rust

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

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

master
2.4 KiB76 linesraw
1error: `splitn` called with `0` splits
2  --> $DIR/suspicious_splitn.rs:10:13
3   |
4LL |     let _ = "a,b".splitn(0, ',');
5   |             ^^^^^^^^^^^^^^^^^^^^
6   |
7   = note: the resulting iterator will always return `None`
8   = note: `-D clippy::suspicious-splitn` implied by `-D warnings`
9   = help: to override `-D warnings` add `#[allow(clippy::suspicious_splitn)]`
10
11error: `rsplitn` called with `0` splits
12  --> $DIR/suspicious_splitn.rs:13:13
13   |
14LL |     let _ = "a,b".rsplitn(0, ',');
15   |             ^^^^^^^^^^^^^^^^^^^^^
16   |
17   = note: the resulting iterator will always return `None`
18
19error: `splitn` called with `1` split
20  --> $DIR/suspicious_splitn.rs:16:13
21   |
22LL |     let _ = "a,b".splitn(1, ',');
23   |             ^^^^^^^^^^^^^^^^^^^^
24   |
25   = note: the resulting iterator will always return the entire string followed by `None`
26
27error: `splitn` called with `0` splits
28  --> $DIR/suspicious_splitn.rs:19:13
29   |
30LL |     let _ = [0, 1, 2].splitn(0, |&x| x == 1);
31   |             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
32   |
33   = note: the resulting iterator will always return `None`
34
35error: `splitn_mut` called with `0` splits
36  --> $DIR/suspicious_splitn.rs:22:13
37   |
38LL |     let _ = [0, 1, 2].splitn_mut(0, |&x| x == 1);
39   |             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
40   |
41   = note: the resulting iterator will always return `None`
42
43error: `splitn` called with `1` split
44  --> $DIR/suspicious_splitn.rs:25:13
45   |
46LL |     let _ = [0, 1, 2].splitn(1, |&x| x == 1);
47   |             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
48   |
49   = note: the resulting iterator will always return the entire slice followed by `None`
50
51error: `rsplitn_mut` called with `1` split
52  --> $DIR/suspicious_splitn.rs:28:13
53   |
54LL |     let _ = [0, 1, 2].rsplitn_mut(1, |&x| x == 1);
55   |             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
56   |
57   = note: the resulting iterator will always return the entire slice followed by `None`
58
59error: `splitn` called with `1` split
60  --> $DIR/suspicious_splitn.rs:33:13
61   |
62LL |     let _ = "a,b".splitn(X + 1, ',');
63   |             ^^^^^^^^^^^^^^^^^^^^^^^^
64   |
65   = note: the resulting iterator will always return the entire string followed by `None`
66
67error: `splitn` called with `0` splits
68  --> $DIR/suspicious_splitn.rs:36:13
69   |
70LL |     let _ = "a,b".splitn(X, ',');
71   |             ^^^^^^^^^^^^^^^^^^^^
72   |
73   = note: the resulting iterator will always return `None`
74
75error: aborting due to 9 previous errors
76