@@ -77,49 +77,49 @@ LL | let _ = if let Some(_) = opt { true } else { false };
7777 | -------^^^^^^^------ help: try this: `if opt.is_some()`
7878
7979error: redundant pattern matching, consider using `is_some()`
80- --> $DIR/redundant_pattern_matching_option.rs:59 :20
80+ --> $DIR/redundant_pattern_matching_option.rs:60 :20
8181 |
8282LL | let _ = if let Some(_) = gen_opt() {
8383 | -------^^^^^^^------------ help: try this: `if gen_opt().is_some()`
8484
8585error: redundant pattern matching, consider using `is_none()`
86- --> $DIR/redundant_pattern_matching_option.rs:61 :19
86+ --> $DIR/redundant_pattern_matching_option.rs:62 :19
8787 |
8888LL | } else if let None = gen_opt() {
8989 | -------^^^^------------ help: try this: `if gen_opt().is_none()`
9090
9191error: redundant pattern matching, consider using `is_some()`
92- --> $DIR/redundant_pattern_matching_option.rs:67 :12
92+ --> $DIR/redundant_pattern_matching_option.rs:68 :12
9393 |
9494LL | if let Some(..) = gen_opt() {}
9595 | -------^^^^^^^^------------ help: try this: `if gen_opt().is_some()`
9696
9797error: redundant pattern matching, consider using `is_some()`
98- --> $DIR/redundant_pattern_matching_option.rs:82 :12
98+ --> $DIR/redundant_pattern_matching_option.rs:83 :12
9999 |
100100LL | if let Some(_) = Some(42) {}
101101 | -------^^^^^^^----------- help: try this: `if Some(42).is_some()`
102102
103103error: redundant pattern matching, consider using `is_none()`
104- --> $DIR/redundant_pattern_matching_option.rs:84 :12
104+ --> $DIR/redundant_pattern_matching_option.rs:85 :12
105105 |
106106LL | if let None = None::<()> {}
107107 | -------^^^^------------- help: try this: `if None::<()>.is_none()`
108108
109109error: redundant pattern matching, consider using `is_some()`
110- --> $DIR/redundant_pattern_matching_option.rs:86 :15
110+ --> $DIR/redundant_pattern_matching_option.rs:87 :15
111111 |
112112LL | while let Some(_) = Some(42) {}
113113 | ----------^^^^^^^----------- help: try this: `while Some(42).is_some()`
114114
115115error: redundant pattern matching, consider using `is_none()`
116- --> $DIR/redundant_pattern_matching_option.rs:88 :15
116+ --> $DIR/redundant_pattern_matching_option.rs:89 :15
117117 |
118118LL | while let None = None::<()> {}
119119 | ----------^^^^------------- help: try this: `while None::<()>.is_none()`
120120
121121error: redundant pattern matching, consider using `is_some()`
122- --> $DIR/redundant_pattern_matching_option.rs:90 :5
122+ --> $DIR/redundant_pattern_matching_option.rs:91 :5
123123 |
124124LL | / match Some(42) {
125125LL | | Some(_) => true,
@@ -128,7 +128,7 @@ LL | | };
128128 | |_____^ help: try this: `Some(42).is_some()`
129129
130130error: redundant pattern matching, consider using `is_none()`
131- --> $DIR/redundant_pattern_matching_option.rs:95 :5
131+ --> $DIR/redundant_pattern_matching_option.rs:96 :5
132132 |
133133LL | / match None::<()> {
134134LL | | Some(_) => false,
@@ -137,16 +137,88 @@ LL | | };
137137 | |_____^ help: try this: `None::<()>.is_none()`
138138
139139error: redundant pattern matching, consider using `is_none()`
140- --> $DIR/redundant_pattern_matching_option.rs:103 :12
140+ --> $DIR/redundant_pattern_matching_option.rs:104 :12
141141 |
142142LL | if let None = *(&None::<()>) {}
143143 | -------^^^^----------------- help: try this: `if (&None::<()>).is_none()`
144144
145145error: redundant pattern matching, consider using `is_none()`
146- --> $DIR/redundant_pattern_matching_option.rs:104 :12
146+ --> $DIR/redundant_pattern_matching_option.rs:105 :12
147147 |
148148LL | if let None = *&None::<()> {}
149149 | -------^^^^--------------- help: try this: `if (&None::<()>).is_none()`
150150
151- error: aborting due to 22 previous errors
151+ error: redundant pattern matching, consider using `is_some()`
152+ --> $DIR/redundant_pattern_matching_option.rs:109:5
153+ |
154+ LL | / match Some(42) {
155+ LL | | Some(_) => true,
156+ LL | | _ => false,
157+ LL | | };
158+ | |_____^ help: try this: `Some(42).is_some()`
159+
160+ error: redundant pattern matching, consider using `is_none()`
161+ --> $DIR/redundant_pattern_matching_option.rs:114:5
162+ |
163+ LL | / match Some(42) {
164+ LL | | Some(_) => false,
165+ LL | | _ => true,
166+ LL | | };
167+ | |_____^ help: try this: `Some(42).is_none()`
168+
169+ error: redundant pattern matching, consider using `is_none()`
170+ --> $DIR/redundant_pattern_matching_option.rs:119:5
171+ |
172+ LL | / match Some(42) {
173+ LL | | None => true,
174+ LL | | _ => false,
175+ LL | | };
176+ | |_____^ help: try this: `Some(42).is_none()`
177+
178+ error: redundant pattern matching, consider using `is_some()`
179+ --> $DIR/redundant_pattern_matching_option.rs:124:5
180+ |
181+ LL | / match Some(42) {
182+ LL | | None => false,
183+ LL | | _ => true,
184+ LL | | };
185+ | |_____^ help: try this: `Some(42).is_some()`
186+
187+ error: redundant pattern matching, consider using `is_none()`
188+ --> $DIR/redundant_pattern_matching_option.rs:129:5
189+ |
190+ LL | / match None::<()> {
191+ LL | | Some(_) => false,
192+ LL | | _ => true,
193+ LL | | };
194+ | |_____^ help: try this: `None::<()>.is_none()`
195+
196+ error: redundant pattern matching, consider using `is_none()`
197+ --> $DIR/redundant_pattern_matching_option.rs:134:5
198+ |
199+ LL | / match None::<()> {
200+ LL | | Some(_) => false,
201+ LL | | _ => true,
202+ LL | | };
203+ | |_____^ help: try this: `None::<()>.is_none()`
204+
205+ error: redundant pattern matching, consider using `is_none()`
206+ --> $DIR/redundant_pattern_matching_option.rs:139:5
207+ |
208+ LL | / match None::<()> {
209+ LL | | None => true,
210+ LL | | _ => false,
211+ LL | | };
212+ | |_____^ help: try this: `None::<()>.is_none()`
213+
214+ error: redundant pattern matching, consider using `is_some()`
215+ --> $DIR/redundant_pattern_matching_option.rs:144:5
216+ |
217+ LL | / match None::<()> {
218+ LL | | None => false,
219+ LL | | _ => true,
220+ LL | | };
221+ | |_____^ help: try this: `None::<()>.is_some()`
222+
223+ error: aborting due to 30 previous errors
152224
0 commit comments