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

Unified Diff: src/mirror-debugger.js

Issue 726643002: harmony-scoping: Implement debugger support for script scope. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Minor nits Created 6 years, 1 month 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 | « no previous file | src/runtime/runtime-debug.cc » ('j') | src/runtime/runtime-debug.cc » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/mirror-debugger.js
diff --git a/src/mirror-debugger.js b/src/mirror-debugger.js
index c8d2461d6bf46f30c608b836adba3a78f2ed191f..3c978be7fc3a5acf444d754bea622e84fa946fc3 100644
--- a/src/mirror-debugger.js
+++ b/src/mirror-debugger.js
@@ -195,11 +195,12 @@ PropertyAttribute.DontDelete = DONT_DELETE;
// A copy of the scope types from runtime.cc.
var ScopeType = { Global: 0,
- Local: 1,
- With: 2,
- Closure: 3,
- Catch: 4,
- Block: 5 };
+ Script: 1,
yurys 2014/11/14 12:25:32 This will break DevTools code as we rely on these
aandrey 2014/11/14 12:35:22 Can you add the new scope at the end. Our code dep
Dmitry Lomov (no reviews) 2014/11/14 13:56:51 Done.
+ Local: 2,
+ With: 3,
+ Closure: 4,
+ Catch: 5,
+ Block: 6 };
// Mirror hierarchy:
@@ -2293,11 +2294,12 @@ ScopeMirror.prototype.scopeType = function() {
ScopeMirror.prototype.scopeObject = function() {
- // For local and closure scopes create a transient mirror as these objects are
- // created on the fly materializing the local or closure scopes and
- // therefore will not preserve identity.
+ // For local, closure and script scopes create a transient mirror
+ // as these objects are created on the fly materializing the local
+ // or closure scopes and therefore will not preserve identity.
var transient = this.scopeType() == ScopeType.Local ||
- this.scopeType() == ScopeType.Closure;
+ this.scopeType() == ScopeType.Closure ||
+ this.scopeType() == ScopeType.Script;
return MakeMirror(this.details_.object(), transient);
};
« no previous file with comments | « no previous file | src/runtime/runtime-debug.cc » ('j') | src/runtime/runtime-debug.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698