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 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
4 // met: | 4 // met: |
5 // | 5 // |
6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
(...skipping 520 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
531 * @constructor | 531 * @constructor |
532 * @extends ValueMirror | 532 * @extends ValueMirror |
533 */ | 533 */ |
534 function NumberMirror(value) { | 534 function NumberMirror(value) { |
535 %_CallFunction(this, NUMBER_TYPE, value, ValueMirror); | 535 %_CallFunction(this, NUMBER_TYPE, value, ValueMirror); |
536 } | 536 } |
537 inherits(NumberMirror, ValueMirror); | 537 inherits(NumberMirror, ValueMirror); |
538 | 538 |
539 | 539 |
540 NumberMirror.prototype.toText = function() { | 540 NumberMirror.prototype.toText = function() { |
541 return %NumberToString(this.value_); | 541 return %_NumberToString(this.value_); |
542 }; | 542 }; |
543 | 543 |
544 | 544 |
545 /** | 545 /** |
546 * Mirror object for string values. | 546 * Mirror object for string values. |
547 * @param {string} value The string value reflected by this mirror | 547 * @param {string} value The string value reflected by this mirror |
548 * @constructor | 548 * @constructor |
549 * @extends ValueMirror | 549 * @extends ValueMirror |
550 */ | 550 */ |
551 function StringMirror(value) { | 551 function StringMirror(value) { |
(...skipping 2132 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2684 } | 2684 } |
2685 if (!NUMBER_IS_FINITE(value)) { | 2685 if (!NUMBER_IS_FINITE(value)) { |
2686 if (value > 0) { | 2686 if (value > 0) { |
2687 return 'Infinity'; | 2687 return 'Infinity'; |
2688 } else { | 2688 } else { |
2689 return '-Infinity'; | 2689 return '-Infinity'; |
2690 } | 2690 } |
2691 } | 2691 } |
2692 return value; | 2692 return value; |
2693 } | 2693 } |
OLD | NEW |