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

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

Issue 1957303002: [debugger] keep scope and context chain for hidden scopes in sync. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: fix test Created 4 years, 7 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 | « no previous file | src/debug/debug-scopes.cc » ('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 #ifndef V8_DEBUG_DEBUG_SCOPES_H_ 5 #ifndef V8_DEBUG_DEBUG_SCOPES_H_
6 #define V8_DEBUG_DEBUG_SCOPES_H_ 6 #define V8_DEBUG_DEBUG_SCOPES_H_
7 7
8 #include "src/debug/debug-frames.h" 8 #include "src/debug/debug-frames.h"
9 #include "src/frames.h" 9 #include "src/frames.h"
10 10
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after
78 78
79 #ifdef DEBUG 79 #ifdef DEBUG
80 // Debug print of the content of the current scope. 80 // Debug print of the content of the current scope.
81 void DebugPrint(); 81 void DebugPrint();
82 #endif 82 #endif
83 83
84 private: 84 private:
85 struct ExtendedScopeInfo { 85 struct ExtendedScopeInfo {
86 ExtendedScopeInfo(Handle<ScopeInfo> info, int start, int end) 86 ExtendedScopeInfo(Handle<ScopeInfo> info, int start, int end)
87 : scope_info(info), start_position(start), end_position(end) {} 87 : scope_info(info), start_position(start), end_position(end) {}
88 explicit ExtendedScopeInfo(Handle<ScopeInfo> info)
89 : scope_info(info), start_position(-1), end_position(-1) {}
88 Handle<ScopeInfo> scope_info; 90 Handle<ScopeInfo> scope_info;
89 int start_position; 91 int start_position;
90 int end_position; 92 int end_position;
93 bool is_hidden() { return start_position == -1 && end_position == -1; }
91 }; 94 };
92 95
93 Isolate* isolate_; 96 Isolate* isolate_;
94 FrameInspector* const frame_inspector_; 97 FrameInspector* const frame_inspector_;
95 Handle<Context> context_; 98 Handle<Context> context_;
96 List<ExtendedScopeInfo> nested_scope_chain_; 99 List<ExtendedScopeInfo> nested_scope_chain_;
97 Handle<StringSet> non_locals_; 100 Handle<StringSet> non_locals_;
98 bool seen_script_scope_; 101 bool seen_script_scope_;
99 bool failed_; 102 bool failed_;
100 103
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after
158 void GetNestedScopeChain(Isolate* isolate, Scope* scope, 161 void GetNestedScopeChain(Isolate* isolate, Scope* scope,
159 int statement_position); 162 int statement_position);
160 163
161 DISALLOW_IMPLICIT_CONSTRUCTORS(ScopeIterator); 164 DISALLOW_IMPLICIT_CONSTRUCTORS(ScopeIterator);
162 }; 165 };
163 166
164 } // namespace internal 167 } // namespace internal
165 } // namespace v8 168 } // namespace v8
166 169
167 #endif // V8_DEBUG_DEBUG_SCOPES_H_ 170 #endif // V8_DEBUG_DEBUG_SCOPES_H_
OLDNEW
« no previous file with comments | « no previous file | src/debug/debug-scopes.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698