summaryrefslogtreecommitdiffstats
path: root/src/tools/clippy/tests/ui/absurd-extreme-comparisons.stderr
blob: 6de554378aaa97f1d0537bb1b7703ae59b9f46fc (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
error: this comparison involving the minimum or maximum element for this type contains a case that is always true or always false
  --> $DIR/absurd-extreme-comparisons.rs:14:5
   |
LL |     u <= 0;
   |     ^^^^^^
   |
   = note: `-D clippy::absurd-extreme-comparisons` implied by `-D warnings`
   = help: because `0` is the minimum value for this type, the case where the two sides are not equal never occurs, consider using `u == 0` instead

error: this comparison involving the minimum or maximum element for this type contains a case that is always true or always false
  --> $DIR/absurd-extreme-comparisons.rs:15:5
   |
LL |     u <= Z;
   |     ^^^^^^
   |
   = help: because `Z` is the minimum value for this type, the case where the two sides are not equal never occurs, consider using `u == Z` instead

error: this comparison involving the minimum or maximum element for this type contains a case that is always true or always false
  --> $DIR/absurd-extreme-comparisons.rs:16:5
   |
LL |     u < Z;
   |     ^^^^^
   |
   = help: because `Z` is the minimum value for this type, this comparison is always false

error: this comparison involving the minimum or maximum element for this type contains a case that is always true or always false
  --> $DIR/absurd-extreme-comparisons.rs:17:5
   |
LL |     Z >= u;
   |     ^^^^^^
   |
   = help: because `Z` is the minimum value for this type, the case where the two sides are not equal never occurs, consider using `Z == u` instead

error: this comparison involving the minimum or maximum element for this type contains a case that is always true or always false
  --> $DIR/absurd-extreme-comparisons.rs:18:5
   |
LL |     Z > u;
   |     ^^^^^
   |
   = help: because `Z` is the minimum value for this type, this comparison is always false

error: this comparison involving the minimum or maximum element for this type contains a case that is always true or always false
  --> $DIR/absurd-extreme-comparisons.rs:19:5
   |
LL |     u > u32::MAX;
   |     ^^^^^^^^^^^^
   |
   = help: because `u32::MAX` is the maximum value for this type, this comparison is always false

error: this comparison involving the minimum or maximum element for this type contains a case that is always true or always false
  --> $DIR/absurd-extreme-comparisons.rs:20:5
   |
LL |     u >= u32::MAX;
   |     ^^^^^^^^^^^^^
   |
   = help: because `u32::MAX` is the maximum value for this type, the case where the two sides are not equal never occurs, consider using `u == u32::MAX` instead

error: this comparison involving the minimum or maximum element for this type contains a case that is always true or always false
  --> $DIR/absurd-extreme-comparisons.rs:21:5
   |
LL |     u32::MAX < u;
   |     ^^^^^^^^^^^^
   |
   = help: because `u32::MAX` is the maximum value for this type, this comparison is always false

error: this comparison involving the minimum or maximum element for this type contains a case that is always true or always false
  --> $DIR/absurd-extreme-comparisons.rs:22:5
   |
LL |     u32::MAX <= u;
   |     ^^^^^^^^^^^^^
   |
   = help: because `u32::MAX` is the maximum value for this type, the case where the two sides are not equal never occurs, consider using `u32::MAX == u` instead

error: this comparison involving the minimum or maximum element for this type contains a case that is always true or always false
  --> $DIR/absurd-extreme-comparisons.rs:23:5
   |
LL |     1-1 > u;
   |     ^^^^^^^
   |
   = help: because `1-1` is the minimum value for this type, this comparison is always false

error: this comparison involving the minimum or maximum element for this type contains a case that is always true or always false
  --> $DIR/absurd-extreme-comparisons.rs:24:5
   |
LL |     u >= !0;
   |     ^^^^^^^
   |
   = help: because `!0` is the maximum value for this type, the case where the two sides are not equal never occurs, consider using `u == !0` instead

error: this comparison involving the minimum or maximum element for this type contains a case that is always true or always false
  --> $DIR/absurd-extreme-comparisons.rs:25:5
   |
LL |     u <= 12 - 2*6;
   |     ^^^^^^^^^^^^^
   |
   = help: because `12 - 2*6` is the minimum value for this type, the case where the two sides are not equal never occurs, consider using `u == 12 - 2*6` instead

error: this comparison involving the minimum or maximum element for this type contains a case that is always true or always false
  --> $DIR/absurd-extreme-comparisons.rs:27:5
   |
LL |     i < -127 - 1;
   |     ^^^^^^^^^^^^
   |
   = help: because `-127 - 1` is the minimum value for this type, this comparison is always false

error: this comparison involving the minimum or maximum element for this type contains a case that is always true or always false
  --> $DIR/absurd-extreme-comparisons.rs:28:5
   |
LL |     i8::MAX >= i;
   |     ^^^^^^^^^^^^
   |
   = help: because `i8::MAX` is the maximum value for this type, this comparison is always true

error: this comparison involving the minimum or maximum element for this type contains a case that is always true or always false
  --> $DIR/absurd-extreme-comparisons.rs:29:5
   |
LL |     3-7 < i32::MIN;
   |     ^^^^^^^^^^^^^^
   |
   = help: because `i32::MIN` is the minimum value for this type, this comparison is always false

error: this comparison involving the minimum or maximum element for this type contains a case that is always true or always false
  --> $DIR/absurd-extreme-comparisons.rs:31:5
   |
LL |     b >= true;
   |     ^^^^^^^^^
   |
   = help: because `true` is the maximum value for this type, the case where the two sides are not equal never occurs, consider using `b == true` instead

error: this comparison involving the minimum or maximum element for this type contains a case that is always true or always false
  --> $DIR/absurd-extreme-comparisons.rs:32:5
   |
LL |     false > b;
   |     ^^^^^^^^^
   |
   = help: because `false` is the minimum value for this type, this comparison is always false

error: <-comparison of unit values detected. This will always be false
  --> $DIR/absurd-extreme-comparisons.rs:35:5
   |
LL |     () < {};
   |     ^^^^^^^
   |
   = note: `#[deny(clippy::unit_cmp)]` on by default

error: aborting due to 18 previous errors