Bug 1061853 - Remove a stale bit of code dealing with the parsing of shorthands in destructuring assignment object patterns as not being done by identifierName() (they are now). r=shu

--HG--
extra : rebase_source : b8de5cacd646f0f4ca70179c9fa673291157807d
This commit is contained in:
Jeff Walden 2014-09-03 17:28:10 -07:00
parent 12717b8699
commit fa909fc010

View File

@ -3062,17 +3062,6 @@ Parser<FullParseHandler>::checkDestructuringObject(BindData<FullParseHandler> *d
}
ok = bindDestructuringVar(data, expr);
} else {
/*
* If this is a destructuring shorthand ({x} = ...), then
* identifierName wasn't used to parse |x|. As a result, |x|
* hasn't been officially linked to its def or registered in
* lexdeps. Do that now.
*/
if (!member->isKind(PNK_MUTATEPROTO) && member->pn_right == member->pn_left) {
RootedPropertyName name(context, expr->pn_atom->asPropertyName());
if (!noteNameUse(name, expr))
return false;
}
ok = checkAndMarkAsAssignmentLhs(expr, KeyedDestructuringAssignment);
}
if (!ok)