• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 // Copyright 2015 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4 
5 #ifndef V8_HEAP_SYMBOLS_H_
6 #define V8_HEAP_SYMBOLS_H_
7 
8 #define INTERNALIZED_STRING_LIST(V)                                \
9   V(anonymous_string, "anonymous")                                 \
10   V(apply_string, "apply")                                         \
11   V(arguments_string, "arguments")                                 \
12   V(Arguments_string, "Arguments")                                 \
13   V(arguments_to_string, "[object Arguments]")                     \
14   V(Array_string, "Array")                                         \
15   V(ArrayIterator_string, "Array Iterator")                        \
16   V(assign_string, "assign")                                       \
17   V(array_to_string, "[object Array]")                             \
18   V(boolean_to_string, "[object Boolean]")                         \
19   V(date_to_string, "[object Date]")                               \
20   V(error_to_string, "[object Error]")                             \
21   V(function_to_string, "[object Function]")                       \
22   V(number_to_string, "[object Number]")                           \
23   V(object_to_string, "[object Object]")                           \
24   V(regexp_to_string, "[object RegExp]")                           \
25   V(string_to_string, "[object String]")                           \
26   V(bind_string, "bind")                                           \
27   V(bool16x8_string, "bool16x8")                                   \
28   V(Bool16x8_string, "Bool16x8")                                   \
29   V(bool32x4_string, "bool32x4")                                   \
30   V(Bool32x4_string, "Bool32x4")                                   \
31   V(bool8x16_string, "bool8x16")                                   \
32   V(Bool8x16_string, "Bool8x16")                                   \
33   V(boolean_string, "boolean")                                     \
34   V(Boolean_string, "Boolean")                                     \
35   V(bound__string, "bound ")                                       \
36   V(buffer_string, "buffer")                                       \
37   V(byte_length_string, "byteLength")                              \
38   V(byte_offset_string, "byteOffset")                              \
39   V(call_string, "call")                                           \
40   V(callee_string, "callee")                                       \
41   V(caller_string, "caller")                                       \
42   V(cell_value_string, "%cell_value")                              \
43   V(char_at_string, "CharAt")                                      \
44   V(closure_string, "(closure)")                                   \
45   V(column_string, "column")                                       \
46   V(compare_ic_string, "==")                                       \
47   V(configurable_string, "configurable")                           \
48   V(constructor_string, "constructor")                             \
49   V(construct_string, "construct")                                 \
50   V(create_string, "create")                                       \
51   V(Date_string, "Date")                                           \
52   V(dayperiod_string, "dayperiod")                                 \
53   V(day_string, "day")                                             \
54   V(default_string, "default")                                     \
55   V(defineProperty_string, "defineProperty")                       \
56   V(deleteProperty_string, "deleteProperty")                       \
57   V(did_handle_string, "didHandle")                                \
58   V(display_name_string, "displayName")                            \
59   V(done_string, "done")                                           \
60   V(dot_result_string, ".result")                                  \
61   V(dot_string, ".")                                               \
62   V(exec_string, "exec")                                           \
63   V(entries_string, "entries")                                     \
64   V(enqueue_string, "enqueue")                                     \
65   V(enumerable_string, "enumerable")                               \
66   V(era_string, "era")                                             \
67   V(Error_string, "Error")                                         \
68   V(eval_string, "eval")                                           \
69   V(EvalError_string, "EvalError")                                 \
70   V(false_string, "false")                                         \
71   V(flags_string, "flags")                                         \
72   V(float32x4_string, "float32x4")                                 \
73   V(Float32x4_string, "Float32x4")                                 \
74   V(for_api_string, "for_api")                                     \
75   V(for_string, "for")                                             \
76   V(function_string, "function")                                   \
77   V(Function_string, "Function")                                   \
78   V(Generator_string, "Generator")                                 \
79   V(getOwnPropertyDescriptor_string, "getOwnPropertyDescriptor")   \
80   V(getOwnPropertyDescriptors_string, "getOwnPropertyDescriptors") \
81   V(getPrototypeOf_string, "getPrototypeOf")                       \
82   V(get_string, "get")                                             \
83   V(global_string, "global")                                       \
84   V(has_string, "has")                                             \
85   V(hour_string, "hour")                                           \
86   V(ignoreCase_string, "ignoreCase")                               \
87   V(illegal_access_string, "illegal access")                       \
88   V(illegal_argument_string, "illegal argument")                   \
89   V(index_string, "index")                                         \
90   V(infinity_string, "Infinity")                                   \
91   V(input_string, "input")                                         \
92   V(int16x8_string, "int16x8")                                     \
93   V(Int16x8_string, "Int16x8")                                     \
94   V(int32x4_string, "int32x4")                                     \
95   V(Int32x4_string, "Int32x4")                                     \
96   V(int8x16_string, "int8x16")                                     \
97   V(Int8x16_string, "Int8x16")                                     \
98   V(isExtensible_string, "isExtensible")                           \
99   V(isView_string, "isView")                                       \
100   V(KeyedLoadMonomorphic_string, "KeyedLoadMonomorphic")           \
101   V(KeyedStoreMonomorphic_string, "KeyedStoreMonomorphic")         \
102   V(keys_string, "keys")                                           \
103   V(lastIndex_string, "lastIndex")                                 \
104   V(length_string, "length")                                       \
105   V(line_string, "line")                                           \
106   V(literal_string, "literal")                                     \
107   V(Map_string, "Map")                                             \
108   V(message_string, "message")                                     \
109   V(minus_infinity_string, "-Infinity")                            \
110   V(minus_zero_string, "-0")                                       \
111   V(minute_string, "minute")                                       \
112   V(month_string, "month")                                         \
113   V(multiline_string, "multiline")                                 \
114   V(name_string, "name")                                           \
115   V(nan_string, "NaN")                                             \
116   V(next_string, "next")                                           \
117   V(not_equal, "not-equal")                                        \
118   V(null_string, "null")                                           \
119   V(null_to_string, "[object Null]")                               \
120   V(number_string, "number")                                       \
121   V(Number_string, "Number")                                       \
122   V(object_string, "object")                                       \
123   V(Object_string, "Object")                                       \
124   V(ok, "ok")                                                      \
125   V(ownKeys_string, "ownKeys")                                     \
126   V(position_string, "position")                                   \
127   V(preventExtensions_string, "preventExtensions")                 \
128   V(private_api_string, "private_api")                             \
129   V(Promise_string, "Promise")                                     \
130   V(PromiseResolveThenableJob_string, "PromiseResolveThenableJob") \
131   V(proto_string, "__proto__")                                     \
132   V(prototype_string, "prototype")                                 \
133   V(Proxy_string, "Proxy")                                         \
134   V(query_colon_string, "(?:)")                                    \
135   V(RangeError_string, "RangeError")                               \
136   V(ReferenceError_string, "ReferenceError")                       \
137   V(RegExp_string, "RegExp")                                       \
138   V(script_string, "script")                                       \
139   V(second_string, "second")                                       \
140   V(setPrototypeOf_string, "setPrototypeOf")                       \
141   V(set_string, "set")                                             \
142   V(Set_string, "Set")                                             \
143   V(source_mapping_url_string, "source_mapping_url")               \
144   V(source_string, "source")                                       \
145   V(sourceText_string, "sourceText")                               \
146   V(source_url_string, "source_url")                               \
147   V(stack_string, "stack")                                         \
148   V(stackTraceLimit_string, "stackTraceLimit")                     \
149   V(sticky_string, "sticky")                                       \
150   V(strict_compare_ic_string, "===")                               \
151   V(string_string, "string")                                       \
152   V(String_string, "String")                                       \
153   V(symbol_string, "symbol")                                       \
154   V(Symbol_string, "Symbol")                                       \
155   V(SyntaxError_string, "SyntaxError")                             \
156   V(this_string, "this")                                           \
157   V(throw_string, "throw")                                         \
158   V(timed_out, "timed-out")                                        \
159   V(timeZoneName_string, "timeZoneName")                           \
160   V(toJSON_string, "toJSON")                                       \
161   V(toString_string, "toString")                                   \
162   V(true_string, "true")                                           \
163   V(TypeError_string, "TypeError")                                 \
164   V(type_string, "type")                                           \
165   V(CompileError_string, "CompileError")                           \
166   V(RuntimeError_string, "RuntimeError")                           \
167   V(uint16x8_string, "uint16x8")                                   \
168   V(Uint16x8_string, "Uint16x8")                                   \
169   V(uint32x4_string, "uint32x4")                                   \
170   V(Uint32x4_string, "Uint32x4")                                   \
171   V(uint8x16_string, "uint8x16")                                   \
172   V(Uint8x16_string, "Uint8x16")                                   \
173   V(undefined_string, "undefined")                                 \
174   V(undefined_to_string, "[object Undefined]")                     \
175   V(unicode_string, "unicode")                                     \
176   V(URIError_string, "URIError")                                   \
177   V(valueOf_string, "valueOf")                                     \
178   V(values_string, "values")                                       \
179   V(value_string, "value")                                         \
180   V(WeakMap_string, "WeakMap")                                     \
181   V(WeakSet_string, "WeakSet")                                     \
182   V(weekday_string, "weekday")                                     \
183   V(will_handle_string, "willHandle")                              \
184   V(writable_string, "writable")                                   \
185   V(year_string, "year")
186 
187 #define PRIVATE_SYMBOL_LIST(V)         \
188   V(array_iteration_kind_symbol)       \
189   V(array_iterator_next_symbol)        \
190   V(array_iterator_object_symbol)      \
191   V(call_site_frame_array_symbol)      \
192   V(call_site_frame_index_symbol)      \
193   V(class_end_position_symbol)         \
194   V(class_start_position_symbol)       \
195   V(detailed_stack_trace_symbol)       \
196   V(elements_transition_symbol)        \
197   V(error_end_pos_symbol)              \
198   V(error_script_symbol)               \
199   V(error_start_pos_symbol)            \
200   V(frozen_symbol)                     \
201   V(hash_code_symbol)                  \
202   V(home_object_symbol)                \
203   V(intl_impl_object_symbol)           \
204   V(intl_initialized_marker_symbol)    \
205   V(intl_pattern_symbol)               \
206   V(intl_resolved_symbol)              \
207   V(megamorphic_symbol)                \
208   V(native_context_index_symbol)       \
209   V(nonexistent_symbol)                \
210   V(nonextensible_symbol)              \
211   V(normal_ic_symbol)                  \
212   V(not_mapped_symbol)                 \
213   V(premonomorphic_symbol)             \
214   V(promise_async_stack_id_symbol)     \
215   V(promise_debug_marker_symbol)       \
216   V(promise_deferred_reaction_symbol)  \
217   V(promise_forwarding_handler_symbol) \
218   V(promise_fulfill_reactions_symbol)  \
219   V(promise_handled_by_symbol)         \
220   V(promise_handled_hint_symbol)       \
221   V(promise_has_handler_symbol)        \
222   V(promise_raw_symbol)                \
223   V(promise_reject_reactions_symbol)   \
224   V(promise_result_symbol)             \
225   V(promise_state_symbol)              \
226   V(sealed_symbol)                     \
227   V(stack_trace_symbol)                \
228   V(strict_function_transition_symbol) \
229   V(uninitialized_symbol)
230 
231 #define PUBLIC_SYMBOL_LIST(V)                \
232   V(iterator_symbol, Symbol.iterator)        \
233   V(match_symbol, Symbol.match)              \
234   V(replace_symbol, Symbol.replace)          \
235   V(search_symbol, Symbol.search)            \
236   V(species_symbol, Symbol.species)          \
237   V(split_symbol, Symbol.split)              \
238   V(to_primitive_symbol, Symbol.toPrimitive) \
239   V(unscopables_symbol, Symbol.unscopables)
240 
241 // Well-Known Symbols are "Public" symbols, which have a bit set which causes
242 // them to produce an undefined value when a load results in a failed access
243 // check. Because this behaviour is not specified properly as of yet, it only
244 // applies to a subset of spec-defined Well-Known Symbols.
245 #define WELL_KNOWN_SYMBOL_LIST(V)                           \
246   V(has_instance_symbol, Symbol.hasInstance)                \
247   V(is_concat_spreadable_symbol, Symbol.isConcatSpreadable) \
248   V(to_string_tag_symbol, Symbol.toStringTag)
249 
250 #endif  // V8_HEAP_SYMBOLS_H_
251