Commit 7b5f018a authored by verwaest's avatar verwaest Committed by Commit bot

Simplify should-eager-compile handling

BUG=v8:5209

Review-Url: https://codereview.chromium.org/2428533002
Cr-Commit-Position: refs/heads/master@{#40366}
parent 04131452
......@@ -293,7 +293,6 @@ bool FunctionLiteral::ShouldEagerCompile() const {
}
void FunctionLiteral::SetShouldEagerCompile() {
if (body_ == nullptr) return;
scope()->set_should_eager_compile();
}
......
......@@ -310,12 +310,11 @@ bool Scope::HasSimpleParameters() {
}
bool DeclarationScope::ShouldEagerCompile() const {
if (!AllowsLazyCompilation()) return true;
return !is_lazily_parsed_ && should_eager_compile_;
return force_eager_compilation_ || should_eager_compile_;
}
void DeclarationScope::set_should_eager_compile() {
should_eager_compile_ = true;
should_eager_compile_ = !is_lazily_parsed_;
}
void DeclarationScope::set_asm_module() {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment