| 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/code-stubs.h" | 9 #include "src/code-stubs.h" |
| 10 #include "src/extensions/externalize-string-extension.h" | 10 #include "src/extensions/externalize-string-extension.h" |
| (...skipping 2331 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2342 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_unicode_regexps) | 2342 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_unicode_regexps) |
| 2343 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_do_expressions) | 2343 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_do_expressions) |
| 2344 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_iterator_close) | 2344 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_iterator_close) |
| 2345 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_regexp_lookbehind) | 2345 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_regexp_lookbehind) |
| 2346 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_regexp_property) | 2346 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_regexp_property) |
| 2347 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_function_name) | 2347 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_function_name) |
| 2348 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_function_sent) | 2348 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_function_sent) |
| 2349 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(promise_extra) | 2349 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(promise_extra) |
| 2350 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_tailcalls) | 2350 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_tailcalls) |
| 2351 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_instanceof) | 2351 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_instanceof) |
| 2352 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_exponentiation_operator) |
| 2352 | 2353 |
| 2353 void InstallPublicSymbol(Factory* factory, Handle<Context> native_context, | 2354 void InstallPublicSymbol(Factory* factory, Handle<Context> native_context, |
| 2354 const char* name, Handle<Symbol> value) { | 2355 const char* name, Handle<Symbol> value) { |
| 2355 Handle<JSGlobalObject> global( | 2356 Handle<JSGlobalObject> global( |
| 2356 JSGlobalObject::cast(native_context->global_object())); | 2357 JSGlobalObject::cast(native_context->global_object())); |
| 2357 Handle<String> symbol_string = factory->InternalizeUtf8String("Symbol"); | 2358 Handle<String> symbol_string = factory->InternalizeUtf8String("Symbol"); |
| 2358 Handle<JSObject> symbol = Handle<JSObject>::cast( | 2359 Handle<JSObject> symbol = Handle<JSObject>::cast( |
| 2359 JSObject::GetProperty(global, symbol_string).ToHandleChecked()); | 2360 JSObject::GetProperty(global, symbol_string).ToHandleChecked()); |
| 2360 Handle<String> name_string = factory->InternalizeUtf8String(name); | 2361 Handle<String> name_string = factory->InternalizeUtf8String(name); |
| 2361 PropertyAttributes attributes = | 2362 PropertyAttributes attributes = |
| (...skipping 642 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3004 static const char* harmony_regexp_lookbehind_natives[] = {nullptr}; | 3005 static const char* harmony_regexp_lookbehind_natives[] = {nullptr}; |
| 3005 static const char* harmony_instanceof_natives[] = {nullptr}; | 3006 static const char* harmony_instanceof_natives[] = {nullptr}; |
| 3006 static const char* harmony_regexp_property_natives[] = {nullptr}; | 3007 static const char* harmony_regexp_property_natives[] = {nullptr}; |
| 3007 static const char* harmony_function_name_natives[] = {nullptr}; | 3008 static const char* harmony_function_name_natives[] = {nullptr}; |
| 3008 static const char* harmony_function_sent_natives[] = {nullptr}; | 3009 static const char* harmony_function_sent_natives[] = {nullptr}; |
| 3009 static const char* promise_extra_natives[] = {"native promise-extra.js", | 3010 static const char* promise_extra_natives[] = {"native promise-extra.js", |
| 3010 nullptr}; | 3011 nullptr}; |
| 3011 static const char* harmony_object_values_entries_natives[] = {nullptr}; | 3012 static const char* harmony_object_values_entries_natives[] = {nullptr}; |
| 3012 static const char* harmony_object_own_property_descriptors_natives[] = { | 3013 static const char* harmony_object_own_property_descriptors_natives[] = { |
| 3013 nullptr}; | 3014 nullptr}; |
| 3015 static const char* harmony_exponentiation_operator_natives[] = {nullptr}; |
| 3014 | 3016 |
| 3015 for (int i = ExperimentalNatives::GetDebuggerCount(); | 3017 for (int i = ExperimentalNatives::GetDebuggerCount(); |
| 3016 i < ExperimentalNatives::GetBuiltinsCount(); i++) { | 3018 i < ExperimentalNatives::GetBuiltinsCount(); i++) { |
| 3017 #define INSTALL_EXPERIMENTAL_NATIVES(id, desc) \ | 3019 #define INSTALL_EXPERIMENTAL_NATIVES(id, desc) \ |
| 3018 if (FLAG_##id) { \ | 3020 if (FLAG_##id) { \ |
| 3019 for (size_t j = 0; id##_natives[j] != NULL; j++) { \ | 3021 for (size_t j = 0; id##_natives[j] != NULL; j++) { \ |
| 3020 Vector<const char> script_name = ExperimentalNatives::GetScriptName(i); \ | 3022 Vector<const char> script_name = ExperimentalNatives::GetScriptName(i); \ |
| 3021 if (strncmp(script_name.start(), id##_natives[j], \ | 3023 if (strncmp(script_name.start(), id##_natives[j], \ |
| 3022 script_name.length()) == 0) { \ | 3024 script_name.length()) == 0) { \ |
| 3023 if (!Bootstrapper::CompileExperimentalBuiltin(isolate(), i)) { \ | 3025 if (!Bootstrapper::CompileExperimentalBuiltin(isolate(), i)) { \ |
| (...skipping 654 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3678 } | 3680 } |
| 3679 | 3681 |
| 3680 | 3682 |
| 3681 // Called when the top-level V8 mutex is destroyed. | 3683 // Called when the top-level V8 mutex is destroyed. |
| 3682 void Bootstrapper::FreeThreadResources() { | 3684 void Bootstrapper::FreeThreadResources() { |
| 3683 DCHECK(!IsActive()); | 3685 DCHECK(!IsActive()); |
| 3684 } | 3686 } |
| 3685 | 3687 |
| 3686 } // namespace internal | 3688 } // namespace internal |
| 3687 } // namespace v8 | 3689 } // namespace v8 |
| OLD | NEW |