Backed out 2 changesets (bug 1569315) on request from mgaudet on a CLOSED TREE

Backed out changeset eb0b2f561461 (bug 1569315)
Backed out changeset 5d553fb84ecb (bug 1569315)
This commit is contained in:
Andreea Pavel
2019-08-02 02:02:52 +03:00
parent 866a98e215
commit 8d1e7c4fe1
5 changed files with 30 additions and 99 deletions

View File

@@ -261,15 +261,10 @@ JS::Result<FunctionBox*> BinASTParserPerTokenizer<Tok>::buildFunctionBox(
// Allocate the function before walking down the tree.
RootedFunction fun(cx_);
if (pc_) {
Rooted<FunctionCreationData> fcd(
cx_, GenerateFunctionCreationData(atom, syntax, generatorKind,
functionAsyncKind));
BINJS_TRY_VAR(fun, AllocNewFunction(cx_, fcd));
MOZ_ASSERT(fun->explicitName() == atom);
} else {
BINJS_TRY_VAR(fun, lazyScript_->functionNonDelazifying());
}
BINJS_TRY_VAR(fun, !pc_ ? lazyScript_->functionNonDelazifying()
: AllocNewFunction(cx_, atom, syntax, generatorKind,
functionAsyncKind));
MOZ_ASSERT_IF(pc_, fun->explicitName() == atom);
mozilla::Maybe<Directives> directives;
if (pc_) {