| OLD | NEW |
| 1 // Copyright 2006-2012 the V8 project authors. All rights reserved. | 1 // Copyright 2006-2012 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 "use strict"; | 4 "use strict"; |
| 5 | 5 |
| 6 // Handle id counters. | 6 // Handle id counters. |
| 7 var next_handle_ = 0; | 7 var next_handle_ = 0; |
| 8 var next_transient_handle_ = -1; | 8 var next_transient_handle_ = -1; |
| 9 | 9 |
| 10 // Mirror cache. | 10 // Mirror cache. |
| (...skipping 805 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 816 * Return the internal properties for this object as an array of | 816 * Return the internal properties for this object as an array of |
| 817 * InternalPropertyMirror objects. | 817 * InternalPropertyMirror objects. |
| 818 * @return {Array} Property mirrors for this object | 818 * @return {Array} Property mirrors for this object |
| 819 */ | 819 */ |
| 820 ObjectMirror.prototype.internalProperties = function() { | 820 ObjectMirror.prototype.internalProperties = function() { |
| 821 return ObjectMirror.GetInternalProperties(this.value_); | 821 return ObjectMirror.GetInternalProperties(this.value_); |
| 822 } | 822 } |
| 823 | 823 |
| 824 | 824 |
| 825 ObjectMirror.prototype.property = function(name) { | 825 ObjectMirror.prototype.property = function(name) { |
| 826 var details = %DebugGetPropertyDetails(this.value_, builtins.$toName(name)); | 826 var details = %DebugGetPropertyDetails(this.value_, %ToName(name)); |
| 827 if (details) { | 827 if (details) { |
| 828 return new PropertyMirror(this, name, details); | 828 return new PropertyMirror(this, name, details); |
| 829 } | 829 } |
| 830 | 830 |
| 831 // Nothing found. | 831 // Nothing found. |
| 832 return GetUndefinedMirror(); | 832 return GetUndefinedMirror(); |
| 833 }; | 833 }; |
| 834 | 834 |
| 835 | 835 |
| 836 | 836 |
| (...skipping 342 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1179 }; | 1179 }; |
| 1180 | 1180 |
| 1181 | 1181 |
| 1182 ArrayMirror.prototype.indexedPropertiesFromRange = function(opt_from_index, | 1182 ArrayMirror.prototype.indexedPropertiesFromRange = function(opt_from_index, |
| 1183 opt_to_index) { | 1183 opt_to_index) { |
| 1184 var from_index = opt_from_index || 0; | 1184 var from_index = opt_from_index || 0; |
| 1185 var to_index = opt_to_index || this.length() - 1; | 1185 var to_index = opt_to_index || this.length() - 1; |
| 1186 if (from_index > to_index) return new Array(); | 1186 if (from_index > to_index) return new Array(); |
| 1187 var values = new Array(to_index - from_index + 1); | 1187 var values = new Array(to_index - from_index + 1); |
| 1188 for (var i = from_index; i <= to_index; i++) { | 1188 for (var i = from_index; i <= to_index; i++) { |
| 1189 var details = %DebugGetPropertyDetails(this.value_, builtins.$toString(i)); | 1189 var details = %DebugGetPropertyDetails(this.value_, %ToString(i)); |
| 1190 var value; | 1190 var value; |
| 1191 if (details) { | 1191 if (details) { |
| 1192 value = new PropertyMirror(this, i, details); | 1192 value = new PropertyMirror(this, i, details); |
| 1193 } else { | 1193 } else { |
| 1194 value = GetUndefinedMirror(); | 1194 value = GetUndefinedMirror(); |
| 1195 } | 1195 } |
| 1196 values[i - from_index] = value; | 1196 values[i - from_index] = value; |
| 1197 } | 1197 } |
| 1198 return values; | 1198 return values; |
| 1199 }; | 1199 }; |
| (...skipping 1862 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3062 } | 3062 } |
| 3063 if (!NUMBER_IS_FINITE(value)) { | 3063 if (!NUMBER_IS_FINITE(value)) { |
| 3064 if (value > 0) { | 3064 if (value > 0) { |
| 3065 return 'Infinity'; | 3065 return 'Infinity'; |
| 3066 } else { | 3066 } else { |
| 3067 return '-Infinity'; | 3067 return '-Infinity'; |
| 3068 } | 3068 } |
| 3069 } | 3069 } |
| 3070 return value; | 3070 return value; |
| 3071 } | 3071 } |
| OLD | NEW |