]> git.proxmox.com Git - rustc.git/blob - src/tools/clippy/tests/ui/len_zero.stderr
New upstream version 1.52.1+dfsg1
[rustc.git] / src / tools / clippy / tests / ui / len_zero.stderr
1 error: length comparison to zero
2 --> $DIR/len_zero.rs:61:8
3 |
4 LL | if x.len() == 0 {
5 | ^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `x.is_empty()`
6 |
7 = note: `-D clippy::len-zero` implied by `-D warnings`
8
9 error: length comparison to zero
10 --> $DIR/len_zero.rs:65:8
11 |
12 LL | if "".len() == 0 {}
13 | ^^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `"".is_empty()`
14
15 error: length comparison to zero
16 --> $DIR/len_zero.rs:80:8
17 |
18 LL | if has_is_empty.len() == 0 {
19 | ^^^^^^^^^^^^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `has_is_empty.is_empty()`
20
21 error: length comparison to zero
22 --> $DIR/len_zero.rs:83:8
23 |
24 LL | if has_is_empty.len() != 0 {
25 | ^^^^^^^^^^^^^^^^^^^^^^^ help: using `!is_empty` is clearer and more explicit: `!has_is_empty.is_empty()`
26
27 error: length comparison to zero
28 --> $DIR/len_zero.rs:86:8
29 |
30 LL | if has_is_empty.len() > 0 {
31 | ^^^^^^^^^^^^^^^^^^^^^^ help: using `!is_empty` is clearer and more explicit: `!has_is_empty.is_empty()`
32
33 error: length comparison to one
34 --> $DIR/len_zero.rs:89:8
35 |
36 LL | if has_is_empty.len() < 1 {
37 | ^^^^^^^^^^^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `has_is_empty.is_empty()`
38
39 error: length comparison to one
40 --> $DIR/len_zero.rs:92:8
41 |
42 LL | if has_is_empty.len() >= 1 {
43 | ^^^^^^^^^^^^^^^^^^^^^^^ help: using `!is_empty` is clearer and more explicit: `!has_is_empty.is_empty()`
44
45 error: length comparison to zero
46 --> $DIR/len_zero.rs:103:8
47 |
48 LL | if 0 == has_is_empty.len() {
49 | ^^^^^^^^^^^^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `has_is_empty.is_empty()`
50
51 error: length comparison to zero
52 --> $DIR/len_zero.rs:106:8
53 |
54 LL | if 0 != has_is_empty.len() {
55 | ^^^^^^^^^^^^^^^^^^^^^^^ help: using `!is_empty` is clearer and more explicit: `!has_is_empty.is_empty()`
56
57 error: length comparison to zero
58 --> $DIR/len_zero.rs:109:8
59 |
60 LL | if 0 < has_is_empty.len() {
61 | ^^^^^^^^^^^^^^^^^^^^^^ help: using `!is_empty` is clearer and more explicit: `!has_is_empty.is_empty()`
62
63 error: length comparison to one
64 --> $DIR/len_zero.rs:112:8
65 |
66 LL | if 1 <= has_is_empty.len() {
67 | ^^^^^^^^^^^^^^^^^^^^^^^ help: using `!is_empty` is clearer and more explicit: `!has_is_empty.is_empty()`
68
69 error: length comparison to one
70 --> $DIR/len_zero.rs:115:8
71 |
72 LL | if 1 > has_is_empty.len() {
73 | ^^^^^^^^^^^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `has_is_empty.is_empty()`
74
75 error: length comparison to zero
76 --> $DIR/len_zero.rs:129:8
77 |
78 LL | if with_is_empty.len() == 0 {
79 | ^^^^^^^^^^^^^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `with_is_empty.is_empty()`
80
81 error: length comparison to zero
82 --> $DIR/len_zero.rs:142:8
83 |
84 LL | if b.len() != 0 {}
85 | ^^^^^^^^^^^^ help: using `!is_empty` is clearer and more explicit: `!b.is_empty()`
86
87 error: aborting due to 14 previous errors
88