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

Side by Side Diff: src/debug/debug-scopes.cc

Issue 2396963003: [parser] Deprecate ParseInfo constructor taking closure. (Closed)
Patch Set: Rebased. Created 4 years, 2 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 unified diff | Download patch
« no previous file with comments | « src/crankshaft/hydrogen.cc ('k') | src/parsing/parse-info.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2015 the V8 project authors. All rights reserved. 1 // Copyright 2015 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "src/debug/debug-scopes.h" 5 #include "src/debug/debug-scopes.h"
6 6
7 #include <memory> 7 #include <memory>
8 8
9 #include "src/ast/scopes.h" 9 #include "src/ast/scopes.h"
10 #include "src/debug/debug.h" 10 #include "src/debug/debug.h"
(...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after
99 info->set_outer_scope_info(handle(function->context()->scope_info())); 99 info->set_outer_scope_info(handle(function->context()->scope_info()));
100 } 100 }
101 // Language mode may be inherited from the eval caller. 101 // Language mode may be inherited from the eval caller.
102 // Retrieve it from shared function info. 102 // Retrieve it from shared function info.
103 info->set_language_mode(shared_info->language_mode()); 103 info->set_language_mode(shared_info->language_mode());
104 } else { 104 } else {
105 DCHECK(scope_info->scope_type() == SCRIPT_SCOPE); 105 DCHECK(scope_info->scope_type() == SCRIPT_SCOPE);
106 } 106 }
107 } else { 107 } else {
108 // Inner function. 108 // Inner function.
109 info.reset(new ParseInfo(&zone, function)); 109 info.reset(new ParseInfo(&zone, shared_info));
110 } 110 }
111 if (Parser::ParseStatic(info.get()) && Rewriter::Rewrite(info.get())) { 111 if (Parser::ParseStatic(info.get()) && Rewriter::Rewrite(info.get())) {
112 DeclarationScope* scope = info->literal()->scope(); 112 DeclarationScope* scope = info->literal()->scope();
113 if (!ignore_nested_scopes || collect_non_locals) { 113 if (!ignore_nested_scopes || collect_non_locals) {
114 CollectNonLocals(info.get(), scope); 114 CollectNonLocals(info.get(), scope);
115 } 115 }
116 if (!ignore_nested_scopes) { 116 if (!ignore_nested_scopes) {
117 DeclarationScope::Analyze(info.get(), AnalyzeMode::kDebugger); 117 DeclarationScope::Analyze(info.get(), AnalyzeMode::kDebugger);
118 RetrieveScopeChain(scope); 118 RetrieveScopeChain(scope);
119 } 119 }
(...skipping 711 matching lines...) Expand 10 before | Expand all | Expand 10 after
831 DCHECK((beg_pos >= 0 && end_pos >= 0) || inner_scope->is_hidden()); 831 DCHECK((beg_pos >= 0 && end_pos >= 0) || inner_scope->is_hidden());
832 if (beg_pos <= position && position < end_pos) { 832 if (beg_pos <= position && position < end_pos) {
833 GetNestedScopeChain(isolate, inner_scope, position); 833 GetNestedScopeChain(isolate, inner_scope, position);
834 return; 834 return;
835 } 835 }
836 } 836 }
837 } 837 }
838 838
839 } // namespace internal 839 } // namespace internal
840 } // namespace v8 840 } // namespace v8
OLDNEW
« no previous file with comments | « src/crankshaft/hydrogen.cc ('k') | src/parsing/parse-info.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698