| OLD | NEW |
| 1 # Copyright 2006-2009 the V8 project authors. All rights reserved. | 1 # Copyright 2006-2009 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 113 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 124 macro JSON_NUMBER_TO_STRING(arg) = ((%_IsSmi(%IS_VAR(arg)) || arg - arg == 0) ?
%_NumberToString(arg) : "null"); | 124 macro JSON_NUMBER_TO_STRING(arg) = ((%_IsSmi(%IS_VAR(arg)) || arg - arg == 0) ?
%_NumberToString(arg) : "null"); |
| 125 macro HAS_OWN_PROPERTY(obj, key) = (%_Call(ObjectHasOwnProperty, obj, key)); | 125 macro HAS_OWN_PROPERTY(obj, key) = (%_Call(ObjectHasOwnProperty, obj, key)); |
| 126 | 126 |
| 127 # Private names. | 127 # Private names. |
| 128 macro IS_PRIVATE(sym) = (%SymbolIsPrivate(sym)); | 128 macro IS_PRIVATE(sym) = (%SymbolIsPrivate(sym)); |
| 129 macro HAS_PRIVATE(obj, key) = HAS_OWN_PROPERTY(obj, key); | 129 macro HAS_PRIVATE(obj, key) = HAS_OWN_PROPERTY(obj, key); |
| 130 macro HAS_DEFINED_PRIVATE(obj, sym) = (!IS_UNDEFINED(obj[sym])); | 130 macro HAS_DEFINED_PRIVATE(obj, sym) = (!IS_UNDEFINED(obj[sym])); |
| 131 macro GET_PRIVATE(obj, sym) = (obj[sym]); | 131 macro GET_PRIVATE(obj, sym) = (obj[sym]); |
| 132 macro SET_PRIVATE(obj, sym, val) = (obj[sym] = val); | 132 macro SET_PRIVATE(obj, sym, val) = (obj[sym] = val); |
| 133 | 133 |
| 134 # To avoid ES2015 Function name inference. |
| 135 macro ANONYMOUS_FUNCTION(fn) = (0, (fn)); |
| 136 |
| 134 # Constants. The compiler constant folds them. | 137 # Constants. The compiler constant folds them. |
| 135 define INFINITY = (1/0); | 138 define INFINITY = (1/0); |
| 136 define UNDEFINED = (void 0); | 139 define UNDEFINED = (void 0); |
| 137 | 140 |
| 138 # Macros implemented in Python. | 141 # Macros implemented in Python. |
| 139 python macro CHAR_CODE(str) = ord(str[1]); | 142 python macro CHAR_CODE(str) = ord(str[1]); |
| 140 | 143 |
| 141 # Constants used on an array to implement the properties of the RegExp object. | 144 # Constants used on an array to implement the properties of the RegExp object. |
| 142 define REGEXP_NUMBER_OF_CAPTURES = 0; | 145 define REGEXP_NUMBER_OF_CAPTURES = 0; |
| 143 define REGEXP_FIRST_CAPTURE = 3; | 146 define REGEXP_FIRST_CAPTURE = 3; |
| (...skipping 112 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 256 define kSloppyModeBlockScopedFunctionRedefinition = 22; | 259 define kSloppyModeBlockScopedFunctionRedefinition = 22; |
| 257 define kForInInitializer = 23; | 260 define kForInInitializer = 23; |
| 258 define kArrayProtectorDirtied = 24; | 261 define kArrayProtectorDirtied = 24; |
| 259 define kArraySpeciesModified = 25; | 262 define kArraySpeciesModified = 25; |
| 260 define kArrayPrototypeConstructorModified = 26; | 263 define kArrayPrototypeConstructorModified = 26; |
| 261 define kArrayInstanceProtoModified = 27; | 264 define kArrayInstanceProtoModified = 27; |
| 262 define kArrayInstanceConstructorModified = 28; | 265 define kArrayInstanceConstructorModified = 28; |
| 263 define kLegacyFunctionDeclaration = 29; | 266 define kLegacyFunctionDeclaration = 29; |
| 264 define kRegExpPrototypeSourceGetter = 30; | 267 define kRegExpPrototypeSourceGetter = 30; |
| 265 define kRegExpPrototypeOldFlagGetter = 31; | 268 define kRegExpPrototypeOldFlagGetter = 31; |
| OLD | NEW |