Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1111)

Unified Diff: src/runtime/runtime-debug.cc

Issue 974213002: Extract ParseInfo from CompilationInfo. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/rewriter.cc ('k') | src/runtime/runtime-internal.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/runtime/runtime-debug.cc
diff --git a/src/runtime/runtime-debug.cc b/src/runtime/runtime-debug.cc
index 5c2a5a5750af59b1d44c1a8ad84917b7d70e1021..180f0137d1bf7d0a21e2296660719adb77eeb9e8 100644
--- a/src/runtime/runtime-debug.cc
+++ b/src/runtime/runtime-debug.cc
@@ -6,6 +6,7 @@
#include "src/accessors.h"
#include "src/arguments.h"
+#include "src/compiler.h"
#include "src/debug.h"
#include "src/deoptimizer.h"
#include "src/isolate-inl.h"
@@ -1198,16 +1199,18 @@ class ScopeIterator {
// Check whether we are in global, eval or function code.
Handle<ScopeInfo> scope_info(shared_info->scope_info());
+ Zone zone;
+ ParseInfo info(&zone);
if (scope_info->scope_type() != FUNCTION_SCOPE &&
scope_info->scope_type() != ARROW_SCOPE) {
// Global or eval code.
- CompilationInfoWithZone info(script);
+ info.InitializeFromScript(script);
if (scope_info->scope_type() == SCRIPT_SCOPE) {
- info.MarkAsGlobal();
+ info.set_global();
} else {
DCHECK(scope_info->scope_type() == EVAL_SCOPE);
- info.MarkAsEval();
- info.SetContext(Handle<Context>(function_->context()));
+ info.set_eval();
+ info.set_context(Handle<Context>(function_->context()));
}
if (Parser::ParseStatic(&info) && Scope::Analyze(&info)) {
scope = info.function()->scope();
@@ -1215,7 +1218,7 @@ class ScopeIterator {
RetrieveScopeChain(scope, shared_info);
} else {
// Function code
- CompilationInfoWithZone info(shared_info);
+ info.InitializeFromSharedFunctionInfo(shared_info);
if (Parser::ParseStatic(&info) && Scope::Analyze(&info)) {
scope = info.function()->scope();
}
« no previous file with comments | « src/rewriter.cc ('k') | src/runtime/runtime-internal.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698