We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent f0db822 commit 99cd110Copy full SHA for 99cd110
tasks/linter_codegen/src/main.rs
@@ -269,13 +269,12 @@ fn is_node_kind_call(expr: &Expr) -> bool {
269
fn extract_variants_from_pat(pat: &Pat, out: &mut BTreeSet<String>) -> CollectionResult {
270
match pat {
271
Pat::Or(orpat) => {
272
- let mut result = CollectionResult::Complete;
273
for p in &orpat.cases {
274
if extract_variants_from_pat(p, out) == CollectionResult::Incomplete {
275
- result = CollectionResult::Incomplete;
+ return CollectionResult::Incomplete;
276
}
277
278
- result
+ CollectionResult::Complete
279
280
Pat::TupleStruct(ts) => {
281
if let Some(variant) = astkind_variant_from_path(&ts.path) {
0 commit comments