OLD | NEW |
1 // Copyright 2014 the V8 project authors. All rights reserved. | 1 // Copyright 2014 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 #include "src/bootstrapper.h" | 5 #include "src/bootstrapper.h" |
6 | 6 |
7 #include "src/accessors.h" | 7 #include "src/accessors.h" |
8 #include "src/api-natives.h" | 8 #include "src/api-natives.h" |
9 #include "src/base/ieee754.h" | 9 #include "src/base/ieee754.h" |
10 #include "src/code-stubs.h" | 10 #include "src/code-stubs.h" |
(...skipping 3461 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3472 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_regexp_property) | 3472 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_regexp_property) |
3473 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_function_sent) | 3473 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_function_sent) |
3474 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_tailcalls) | 3474 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_tailcalls) |
3475 #ifdef V8_I18N_SUPPORT | 3475 #ifdef V8_I18N_SUPPORT |
3476 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(datetime_format_to_parts) | 3476 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(datetime_format_to_parts) |
3477 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(icu_case_mapping) | 3477 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(icu_case_mapping) |
3478 #endif | 3478 #endif |
3479 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_restrictive_generators) | 3479 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_restrictive_generators) |
3480 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_trailing_commas) | 3480 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_trailing_commas) |
3481 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_class_fields) | 3481 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_class_fields) |
3482 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_object_spread) | 3482 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_object_rest_spread) |
3483 | 3483 |
3484 void InstallPublicSymbol(Factory* factory, Handle<Context> native_context, | 3484 void InstallPublicSymbol(Factory* factory, Handle<Context> native_context, |
3485 const char* name, Handle<Symbol> value) { | 3485 const char* name, Handle<Symbol> value) { |
3486 Handle<JSGlobalObject> global( | 3486 Handle<JSGlobalObject> global( |
3487 JSGlobalObject::cast(native_context->global_object())); | 3487 JSGlobalObject::cast(native_context->global_object())); |
3488 Handle<String> symbol_string = factory->InternalizeUtf8String("Symbol"); | 3488 Handle<String> symbol_string = factory->InternalizeUtf8String("Symbol"); |
3489 Handle<JSObject> symbol = Handle<JSObject>::cast( | 3489 Handle<JSObject> symbol = Handle<JSObject>::cast( |
3490 JSObject::GetProperty(global, symbol_string).ToHandleChecked()); | 3490 JSObject::GetProperty(global, symbol_string).ToHandleChecked()); |
3491 Handle<String> name_string = factory->InternalizeUtf8String(name); | 3491 Handle<String> name_string = factory->InternalizeUtf8String(name); |
3492 PropertyAttributes attributes = | 3492 PropertyAttributes attributes = |
(...skipping 540 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4033 static const char* harmony_array_prototype_values_natives[] = {nullptr}; | 4033 static const char* harmony_array_prototype_values_natives[] = {nullptr}; |
4034 #ifdef V8_I18N_SUPPORT | 4034 #ifdef V8_I18N_SUPPORT |
4035 static const char* icu_case_mapping_natives[] = {"native icu-case-mapping.js", | 4035 static const char* icu_case_mapping_natives[] = {"native icu-case-mapping.js", |
4036 nullptr}; | 4036 nullptr}; |
4037 static const char* datetime_format_to_parts_natives[] = { | 4037 static const char* datetime_format_to_parts_natives[] = { |
4038 "native datetime-format-to-parts.js", nullptr}; | 4038 "native datetime-format-to-parts.js", nullptr}; |
4039 #endif | 4039 #endif |
4040 static const char* harmony_restrictive_generators_natives[] = {nullptr}; | 4040 static const char* harmony_restrictive_generators_natives[] = {nullptr}; |
4041 static const char* harmony_trailing_commas_natives[] = {nullptr}; | 4041 static const char* harmony_trailing_commas_natives[] = {nullptr}; |
4042 static const char* harmony_class_fields_natives[] = {nullptr}; | 4042 static const char* harmony_class_fields_natives[] = {nullptr}; |
4043 static const char* harmony_object_spread_natives[] = {nullptr}; | 4043 static const char* harmony_object_rest_spread_natives[] = {nullptr}; |
4044 | 4044 |
4045 for (int i = ExperimentalNatives::GetDebuggerCount(); | 4045 for (int i = ExperimentalNatives::GetDebuggerCount(); |
4046 i < ExperimentalNatives::GetBuiltinsCount(); i++) { | 4046 i < ExperimentalNatives::GetBuiltinsCount(); i++) { |
4047 #define INSTALL_EXPERIMENTAL_NATIVES(id, desc) \ | 4047 #define INSTALL_EXPERIMENTAL_NATIVES(id, desc) \ |
4048 if (FLAG_##id) { \ | 4048 if (FLAG_##id) { \ |
4049 for (size_t j = 0; id##_natives[j] != NULL; j++) { \ | 4049 for (size_t j = 0; id##_natives[j] != NULL; j++) { \ |
4050 Vector<const char> script_name = ExperimentalNatives::GetScriptName(i); \ | 4050 Vector<const char> script_name = ExperimentalNatives::GetScriptName(i); \ |
4051 if (strncmp(script_name.start(), id##_natives[j], \ | 4051 if (strncmp(script_name.start(), id##_natives[j], \ |
4052 script_name.length()) == 0) { \ | 4052 script_name.length()) == 0) { \ |
4053 if (!Bootstrapper::CompileExperimentalBuiltin(isolate(), i)) { \ | 4053 if (!Bootstrapper::CompileExperimentalBuiltin(isolate(), i)) { \ |
(...skipping 724 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4778 } | 4778 } |
4779 | 4779 |
4780 | 4780 |
4781 // Called when the top-level V8 mutex is destroyed. | 4781 // Called when the top-level V8 mutex is destroyed. |
4782 void Bootstrapper::FreeThreadResources() { | 4782 void Bootstrapper::FreeThreadResources() { |
4783 DCHECK(!IsActive()); | 4783 DCHECK(!IsActive()); |
4784 } | 4784 } |
4785 | 4785 |
4786 } // namespace internal | 4786 } // namespace internal |
4787 } // namespace v8 | 4787 } // namespace v8 |
OLD | NEW |