[compiler] Remove redundant code
Just stumbled across this while doing https://codereview.chromium.org/2457433002/ R=mstarzinger@chromium.org Review-Url: https://codereview.chromium.org/2449103006 Cr-Commit-Position: refs/heads/master@{#40596}
This commit is contained in:
parent
7db6c79acd
commit
f6c3fd0a74
@ -1194,24 +1194,7 @@ bool Compiler::CompileOptimized(Handle<JSFunction> function,
|
||||
}
|
||||
|
||||
bool Compiler::CompileDebugCode(Handle<JSFunction> function) {
|
||||
Isolate* isolate = function->GetIsolate();
|
||||
DCHECK(AllowCompilation::IsAllowed(isolate));
|
||||
|
||||
// Start a compilation.
|
||||
Zone zone(isolate->allocator(), ZONE_NAME);
|
||||
ParseInfo parse_info(&zone, handle(function->shared()));
|
||||
CompilationInfo info(&parse_info, Handle<JSFunction>::null());
|
||||
info.MarkAsDebug();
|
||||
if (GetUnoptimizedCode(&info).is_null()) {
|
||||
isolate->clear_pending_exception();
|
||||
return false;
|
||||
}
|
||||
|
||||
// Check postconditions on success.
|
||||
DCHECK(!isolate->has_pending_exception());
|
||||
DCHECK(function->shared()->is_compiled());
|
||||
DCHECK(function->shared()->HasDebugCode());
|
||||
return true;
|
||||
return CompileDebugCode(handle(function->shared()));
|
||||
}
|
||||
|
||||
bool Compiler::CompileDebugCode(Handle<SharedFunctionInfo> shared) {
|
||||
|
Loading…
Reference in New Issue
Block a user