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

Unified Diff: src/mirror-debugger.js

Issue 443843004: Mirror object properties are always names (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 4 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 | « no previous file | test/mjsunit/mirror-object.js » ('j') | no next file with comments »
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 932294157b0258f297614ddd9abd50a23fbec98a..a90f6035195afec0d660649bd8656732e0123c3b 100644
--- a/src/mirror-debugger.js
+++ b/src/mirror-debugger.js
@@ -759,7 +759,7 @@ ObjectMirror.prototype.propertyNames = function(kind, limit) {
// Copy names for indexed properties.
if (kind & PropertyKind.Indexed) {
for (var i = 0; index < limit && i < elementNames.length; i++) {
- names[index++] = elementNames[i];
+ names[index++] = %ToString(elementNames[i]);
rossberg 2014/08/06 14:21:30 Hm, I don't understand why this change is necessar
}
}
@@ -797,7 +797,8 @@ ObjectMirror.prototype.internalProperties = function() {
ObjectMirror.prototype.property = function(name) {
- var details = %DebugGetPropertyDetails(this.value_, %ToString(name));
+ name = IS_SYMBOL(name) ? name : %ToString(name);
rossberg 2014/08/06 14:21:29 You can use %ToName for this.
+ var details = %DebugGetPropertyDetails(this.value_, name);
if (details) {
return new PropertyMirror(this, name, details);
}
@@ -1357,7 +1358,7 @@ SetMirror.prototype.values = function() {
/**
* Base mirror object for properties.
* @param {ObjectMirror} mirror The mirror object having this property
- * @param {string} name The name of the property
+ * @param {Name} name The name of the property (a string or a symbol)
* @param {Array} details Details about the property
* @constructor
* @extends Mirror
« no previous file with comments | « no previous file | test/mjsunit/mirror-object.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698