| OLD | NEW |
| 1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 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 | 4 |
| 5 // This file relies on the fact that the following declarations have been made | 5 // This file relies on the fact that the following declarations have been made |
| 6 // in runtime.js: | 6 // in runtime.js: |
| 7 // var $Object = global.Object; | 7 // var $Object = global.Object; |
| 8 // var $Boolean = global.Boolean; | 8 // var $Boolean = global.Boolean; |
| 9 // var $Number = global.Number; | 9 // var $Number = global.Number; |
| 10 // var $Function = global.Function; | 10 // var $Function = global.Function; |
| (...skipping 1378 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1389 | 1389 |
| 1390 | 1390 |
| 1391 // ---------------------------------------------------------------------------- | 1391 // ---------------------------------------------------------------------------- |
| 1392 // Object | 1392 // Object |
| 1393 | 1393 |
| 1394 function SetUpObject() { | 1394 function SetUpObject() { |
| 1395 %CheckIsBootstrapping(); | 1395 %CheckIsBootstrapping(); |
| 1396 | 1396 |
| 1397 %SetNativeFlag($Object); | 1397 %SetNativeFlag($Object); |
| 1398 %SetCode($Object, ObjectConstructor); | 1398 %SetCode($Object, ObjectConstructor); |
| 1399 %SetExpectedNumberOfProperties($Object, 4); | |
| 1400 | 1399 |
| 1401 %SetProperty($Object.prototype, "constructor", $Object, DONT_ENUM); | 1400 %SetProperty($Object.prototype, "constructor", $Object, DONT_ENUM); |
| 1402 | 1401 |
| 1403 // Set up non-enumerable functions on the Object.prototype object. | 1402 // Set up non-enumerable functions on the Object.prototype object. |
| 1404 InstallFunctions($Object.prototype, DONT_ENUM, $Array( | 1403 InstallFunctions($Object.prototype, DONT_ENUM, $Array( |
| 1405 "toString", ObjectToString, | 1404 "toString", ObjectToString, |
| 1406 "toLocaleString", ObjectToLocaleString, | 1405 "toLocaleString", ObjectToLocaleString, |
| 1407 "valueOf", ObjectValueOf, | 1406 "valueOf", ObjectValueOf, |
| 1408 "hasOwnProperty", ObjectHasOwnProperty, | 1407 "hasOwnProperty", ObjectHasOwnProperty, |
| 1409 "isPrototypeOf", ObjectIsPrototypeOf, | 1408 "isPrototypeOf", ObjectIsPrototypeOf, |
| (...skipping 445 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1855 %SetCode($Function, FunctionConstructor); | 1854 %SetCode($Function, FunctionConstructor); |
| 1856 %SetProperty($Function.prototype, "constructor", $Function, DONT_ENUM); | 1855 %SetProperty($Function.prototype, "constructor", $Function, DONT_ENUM); |
| 1857 | 1856 |
| 1858 InstallFunctions($Function.prototype, DONT_ENUM, $Array( | 1857 InstallFunctions($Function.prototype, DONT_ENUM, $Array( |
| 1859 "bind", FunctionBind, | 1858 "bind", FunctionBind, |
| 1860 "toString", FunctionToString | 1859 "toString", FunctionToString |
| 1861 )); | 1860 )); |
| 1862 } | 1861 } |
| 1863 | 1862 |
| 1864 SetUpFunction(); | 1863 SetUpFunction(); |
| OLD | NEW |