OLD | NEW |
---|---|
1 // Copyright 2006-2008 the V8 project authors. All rights reserved. | 1 // Copyright 2006-2008 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 1030 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
1041 // Reset the date cache: | 1041 // Reset the date cache: |
1042 cache = Date_cache; | 1042 cache = Date_cache; |
1043 cache.time = $NaN; | 1043 cache.time = $NaN; |
1044 cache.year = $NaN; | 1044 cache.year = $NaN; |
1045 cache.string = null; | 1045 cache.string = null; |
1046 } | 1046 } |
1047 | 1047 |
1048 | 1048 |
1049 // ------------------------------------------------------------------- | 1049 // ------------------------------------------------------------------- |
1050 | 1050 |
1051 function SetupDate() { | 1051 function SetupDate() { |
Erik Corry
2011/08/31 05:46:04
SetupDate -> SetUpDate
Lasse Reichstein
2011/09/01 13:30:42
I can do better - and make this a direct call of a
| |
1052 %AssertIsBootstrapping(); | |
1052 // Setup non-enumerable properties of the Date object itself. | 1053 // Setup non-enumerable properties of the Date object itself. |
1053 InstallFunctions($Date, DONT_ENUM, $Array( | 1054 InstallFunctions($Date, DONT_ENUM, $Array( |
1054 "UTC", DateUTC, | 1055 "UTC", DateUTC, |
1055 "parse", DateParse, | 1056 "parse", DateParse, |
1056 "now", DateNow | 1057 "now", DateNow |
1057 )); | 1058 )); |
1058 | 1059 |
1059 // Setup non-enumerable constructor property of the Date prototype object. | 1060 // Setup non-enumerable constructor property of the Date prototype object. |
1060 %SetProperty($Date.prototype, "constructor", $Date, DONT_ENUM); | 1061 %SetProperty($Date.prototype, "constructor", $Date, DONT_ENUM); |
1061 | 1062 |
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
1105 "toGMTString", DateToGMTString, | 1106 "toGMTString", DateToGMTString, |
1106 "toUTCString", DateToUTCString, | 1107 "toUTCString", DateToUTCString, |
1107 "getYear", DateGetYear, | 1108 "getYear", DateGetYear, |
1108 "setYear", DateSetYear, | 1109 "setYear", DateSetYear, |
1109 "toISOString", DateToISOString, | 1110 "toISOString", DateToISOString, |
1110 "toJSON", DateToJSON | 1111 "toJSON", DateToJSON |
1111 )); | 1112 )); |
1112 } | 1113 } |
1113 | 1114 |
1114 SetupDate(); | 1115 SetupDate(); |
OLD | NEW |