mirror of
https://repo.dactyloidae.xyz/Dactyloidae/UXP.git
synced 2026-09-05 23:38:38 +09:00
1320403 - Move JSFunction::EXPR_BODY to JSScript, LazyScript, and FunctionBox.
This commit is contained in:
parent
7f7b0a029c
commit
d451930d58
9 changed files with 55 additions and 26 deletions
|
|
@ -3250,10 +3250,9 @@ CheckModuleLevelName(ModuleValidator& m, ParseNode* usepn, PropertyName* name)
|
|||
static bool
|
||||
CheckFunctionHead(ModuleValidator& m, ParseNode* fn)
|
||||
{
|
||||
JSFunction* fun = FunctionObject(fn);
|
||||
if (fn->pn_funbox->hasRest())
|
||||
return m.fail(fn, "rest args not allowed");
|
||||
if (fun->isExprBody())
|
||||
if (fn->pn_funbox->isExprBody())
|
||||
return m.fail(fn, "expression closures not allowed");
|
||||
if (fn->pn_funbox->hasDestructuringArgs)
|
||||
return m.fail(fn, "destructuring args not allowed");
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue