chore: 清理 oxide_emit clippy 告警

This commit is contained in:
2026-08-14 05:26:25 +08:00
parent 12ebdb8c0e
commit 6522a39dd7
4 changed files with 15 additions and 25 deletions
+2 -4
View File
@@ -537,10 +537,8 @@ impl Emitter {
);
}
BindingPattern::ArrayPattern(ap) => {
for elem in &ap.elements {
if let Some(e) = elem {
self.predeclare_lexical_pattern(e, is_const, ctx);
}
for e in ap.elements.iter().flatten() {
self.predeclare_lexical_pattern(e, is_const, ctx);
}
if let Some(rest) = &ap.rest {
self.predeclare_lexical_pattern(&rest.argument, is_const, ctx);