Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(5)

Side by Side Diff: src/bootstrapper.cc

Issue 792233008: ES6 computed property names (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 6 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « src/bailout-reason.h ('k') | src/builtins.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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/code-stubs.h" 8 #include "src/code-stubs.h"
9 #include "src/extensions/externalize-string-extension.h" 9 #include "src/extensions/externalize-string-extension.h"
10 #include "src/extensions/free-buffer-extension.h" 10 #include "src/extensions/free-buffer-extension.h"
(...skipping 1578 matching lines...) Expand 10 before | Expand all | Expand 10 after
1589 EMPTY_NATIVE_FUNCTIONS_FOR_FEATURE(harmony_array_includes) 1589 EMPTY_NATIVE_FUNCTIONS_FOR_FEATURE(harmony_array_includes)
1590 EMPTY_NATIVE_FUNCTIONS_FOR_FEATURE(harmony_classes) 1590 EMPTY_NATIVE_FUNCTIONS_FOR_FEATURE(harmony_classes)
1591 EMPTY_NATIVE_FUNCTIONS_FOR_FEATURE(harmony_object_literals) 1591 EMPTY_NATIVE_FUNCTIONS_FOR_FEATURE(harmony_object_literals)
1592 EMPTY_NATIVE_FUNCTIONS_FOR_FEATURE(harmony_regexps) 1592 EMPTY_NATIVE_FUNCTIONS_FOR_FEATURE(harmony_regexps)
1593 EMPTY_NATIVE_FUNCTIONS_FOR_FEATURE(harmony_arrow_functions) 1593 EMPTY_NATIVE_FUNCTIONS_FOR_FEATURE(harmony_arrow_functions)
1594 EMPTY_NATIVE_FUNCTIONS_FOR_FEATURE(harmony_numeric_literals) 1594 EMPTY_NATIVE_FUNCTIONS_FOR_FEATURE(harmony_numeric_literals)
1595 EMPTY_NATIVE_FUNCTIONS_FOR_FEATURE(harmony_tostring) 1595 EMPTY_NATIVE_FUNCTIONS_FOR_FEATURE(harmony_tostring)
1596 EMPTY_NATIVE_FUNCTIONS_FOR_FEATURE(harmony_templates) 1596 EMPTY_NATIVE_FUNCTIONS_FOR_FEATURE(harmony_templates)
1597 EMPTY_NATIVE_FUNCTIONS_FOR_FEATURE(harmony_sloppy) 1597 EMPTY_NATIVE_FUNCTIONS_FOR_FEATURE(harmony_sloppy)
1598 EMPTY_NATIVE_FUNCTIONS_FOR_FEATURE(harmony_unicode) 1598 EMPTY_NATIVE_FUNCTIONS_FOR_FEATURE(harmony_unicode)
1599 EMPTY_NATIVE_FUNCTIONS_FOR_FEATURE(harmony_computed_property_names)
1599 1600
1600 1601
1601 void Genesis::InstallNativeFunctions_harmony_proxies() { 1602 void Genesis::InstallNativeFunctions_harmony_proxies() {
1602 if (FLAG_harmony_proxies) { 1603 if (FLAG_harmony_proxies) {
1603 INSTALL_NATIVE(JSFunction, "DerivedHasTrap", derived_has_trap); 1604 INSTALL_NATIVE(JSFunction, "DerivedHasTrap", derived_has_trap);
1604 INSTALL_NATIVE(JSFunction, "DerivedGetTrap", derived_get_trap); 1605 INSTALL_NATIVE(JSFunction, "DerivedGetTrap", derived_get_trap);
1605 INSTALL_NATIVE(JSFunction, "DerivedSetTrap", derived_set_trap); 1606 INSTALL_NATIVE(JSFunction, "DerivedSetTrap", derived_set_trap);
1606 INSTALL_NATIVE(JSFunction, "ProxyEnumerate", proxy_enumerate); 1607 INSTALL_NATIVE(JSFunction, "ProxyEnumerate", proxy_enumerate);
1607 } 1608 }
1608 } 1609 }
(...skipping 10 matching lines...) Expand all
1619 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_array_includes) 1620 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_array_includes)
1620 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_classes) 1621 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_classes)
1621 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_object_literals) 1622 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_object_literals)
1622 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_arrow_functions) 1623 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_arrow_functions)
1623 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_numeric_literals) 1624 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_numeric_literals)
1624 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_tostring) 1625 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_tostring)
1625 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_proxies) 1626 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_proxies)
1626 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_templates) 1627 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_templates)
1627 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_sloppy) 1628 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_sloppy)
1628 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_unicode) 1629 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_unicode)
1630 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_computed_property_names)
1629 1631
1630 void Genesis::InitializeGlobal_harmony_regexps() { 1632 void Genesis::InitializeGlobal_harmony_regexps() {
1631 Handle<JSObject> builtins(native_context()->builtins()); 1633 Handle<JSObject> builtins(native_context()->builtins());
1632 1634
1633 Handle<HeapObject> flag(FLAG_harmony_regexps ? heap()->true_value() 1635 Handle<HeapObject> flag(FLAG_harmony_regexps ? heap()->true_value()
1634 : heap()->false_value()); 1636 : heap()->false_value());
1635 PropertyAttributes attributes = 1637 PropertyAttributes attributes =
1636 static_cast<PropertyAttributes>(DONT_DELETE | READ_ONLY); 1638 static_cast<PropertyAttributes>(DONT_DELETE | READ_ONLY);
1637 Runtime::DefineObjectProperty(builtins, factory()->harmony_regexps_string(), 1639 Runtime::DefineObjectProperty(builtins, factory()->harmony_regexps_string(),
1638 flag, attributes).Assert(); 1640 flag, attributes).Assert();
(...skipping 534 matching lines...) Expand 10 before | Expand all | Expand 10 after
2173 static const char* harmony_regexps_natives[] = { 2175 static const char* harmony_regexps_natives[] = {
2174 "native harmony-regexp.js", NULL}; 2176 "native harmony-regexp.js", NULL};
2175 static const char* harmony_arrow_functions_natives[] = {NULL}; 2177 static const char* harmony_arrow_functions_natives[] = {NULL};
2176 static const char* harmony_numeric_literals_natives[] = {NULL}; 2178 static const char* harmony_numeric_literals_natives[] = {NULL};
2177 static const char* harmony_tostring_natives[] = {"native harmony-tostring.js", 2179 static const char* harmony_tostring_natives[] = {"native harmony-tostring.js",
2178 NULL}; 2180 NULL};
2179 static const char* harmony_templates_natives[] = { 2181 static const char* harmony_templates_natives[] = {
2180 "native harmony-templates.js", NULL}; 2182 "native harmony-templates.js", NULL};
2181 static const char* harmony_sloppy_natives[] = {NULL}; 2183 static const char* harmony_sloppy_natives[] = {NULL};
2182 static const char* harmony_unicode_natives[] = {NULL}; 2184 static const char* harmony_unicode_natives[] = {NULL};
2185 static const char* harmony_computed_property_names_natives[] = {NULL};
2183 2186
2184 for (int i = ExperimentalNatives::GetDebuggerCount(); 2187 for (int i = ExperimentalNatives::GetDebuggerCount();
2185 i < ExperimentalNatives::GetBuiltinsCount(); i++) { 2188 i < ExperimentalNatives::GetBuiltinsCount(); i++) {
2186 #define INSTALL_EXPERIMENTAL_NATIVES(id, desc) \ 2189 #define INSTALL_EXPERIMENTAL_NATIVES(id, desc) \
2187 if (FLAG_##id) { \ 2190 if (FLAG_##id) { \
2188 for (size_t j = 0; id##_natives[j] != NULL; j++) { \ 2191 for (size_t j = 0; id##_natives[j] != NULL; j++) { \
2189 Vector<const char> script_name = ExperimentalNatives::GetScriptName(i); \ 2192 Vector<const char> script_name = ExperimentalNatives::GetScriptName(i); \
2190 if (strncmp(script_name.start(), id##_natives[j], \ 2193 if (strncmp(script_name.start(), id##_natives[j], \
2191 script_name.length()) == 0) { \ 2194 script_name.length()) == 0) { \
2192 if (!CompileExperimentalBuiltin(isolate(), i)) return false; \ 2195 if (!CompileExperimentalBuiltin(isolate(), i)) return false; \
(...skipping 637 matching lines...) Expand 10 before | Expand all | Expand 10 after
2830 return from + sizeof(NestingCounterType); 2833 return from + sizeof(NestingCounterType);
2831 } 2834 }
2832 2835
2833 2836
2834 // Called when the top-level V8 mutex is destroyed. 2837 // Called when the top-level V8 mutex is destroyed.
2835 void Bootstrapper::FreeThreadResources() { 2838 void Bootstrapper::FreeThreadResources() {
2836 DCHECK(!IsActive()); 2839 DCHECK(!IsActive());
2837 } 2840 }
2838 2841
2839 } } // namespace v8::internal 2842 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/bailout-reason.h ('k') | src/builtins.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698