mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-31 22:25:30 +00:00
Bug 453345 - Only look at pn_extra if we're actually a list. r=brendan
This commit is contained in:
parent
999e6c6956
commit
1e443bad7c
@ -1941,7 +1941,7 @@ CheckDestructuring(JSContext *cx, BindData *data,
|
||||
}
|
||||
|
||||
#if JS_HAS_DESTRUCTURING_SHORTHAND
|
||||
if (right && (right->pn_extra & PNX_SHORTHAND)) {
|
||||
if (right && right->pn_arity == PN_LIST && (right->pn_extra & PNX_SHORTHAND)) {
|
||||
js_ReportCompileErrorNumber(cx, TS(tc->parseContext), right,
|
||||
JSREPORT_ERROR, JSMSG_BAD_OBJECT_INIT);
|
||||
return JS_FALSE;
|
||||
|
Loading…
Reference in New Issue
Block a user