From b1eff9d603f0f4c928d65075ec5b9e01974119ce Mon Sep 17 00:00:00 2001 From: raskad <32105367+raskad@users.noreply.github.com> Date: Sat, 30 Sep 2023 01:34:03 +0200 Subject: [PATCH] Fix anonymous function name in cover assignment --- boa_parser/src/parser/expression/assignment/mod.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/boa_parser/src/parser/expression/assignment/mod.rs b/boa_parser/src/parser/expression/assignment/mod.rs index ed66cff608f..d84160c7b41 100644 --- a/boa_parser/src/parser/expression/assignment/mod.rs +++ b/boa_parser/src/parser/expression/assignment/mod.rs @@ -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)?;