Skip to content

Commit

Permalink
Fix anonymous function name in cover assignment (#3325)
Browse files Browse the repository at this point in the history
  • Loading branch information
raskad authored Sep 30, 2023
1 parent 332fd65 commit ebb40ae
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion boa_parser/src/parser/expression/assignment/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -241,7 +241,7 @@ where
cursor.set_goal(InputElement::RegExp);

if let Some(target) = AssignTarget::from_expression(&lhs, cursor.strict()) {
if let AssignTarget::Identifier(ident) = target {
if let Expression::Identifier(ident) = lhs {
self.name = Some(ident);
}
let expr = self.parse(cursor, interner)?;
Expand Down

0 comments on commit ebb40ae

Please sign in to comment.