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

Unified Diff: src/bootstrapper.cc

Issue 1658773003: [esnext] implement Object.getOwnPropertyDescriptors() proposal (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: fix rebase + re-enable test Created 4 years, 10 months 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | src/builtins.h » ('j') | src/builtins.cc » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/bootstrapper.cc
diff --git a/src/bootstrapper.cc b/src/bootstrapper.cc
index 835ac7a88f36ae2fd4adaa8a7b39ad9d31b38603..0d6a4710857f9d4bac29bda7ba57b97f84bcdeea 100644
--- a/src/bootstrapper.cc
+++ b/src/bootstrapper.cc
@@ -2459,6 +2459,19 @@ void Genesis::InitializeGlobal_harmony_object_values_entries() {
Builtins::kObjectValues, 1, false);
}
+void Genesis::InitializeGlobal_harmony_object_own_property_descriptors() {
+ if (!FLAG_harmony_object_own_property_descriptors) return;
+
+ Handle<JSGlobalObject> global(
+ JSGlobalObject::cast(native_context()->global_object()));
+ Isolate* isolate = global->GetIsolate();
+ Factory* factory = isolate->factory();
+
+ Handle<JSFunction> object_function = isolate->object_function();
+ SimpleInstallFunction(object_function,
+ factory->getOwnPropertyDescriptors_string(),
+ Builtins::kObjectGetOwnPropertyDescriptors, 1, false);
+}
void Genesis::InstallJSProxyMaps() {
// Allocate the different maps for all Proxy types.
@@ -2948,6 +2961,8 @@ bool Genesis::InstallExperimentalNatives() {
static const char* promise_extra_natives[] = {"native promise-extra.js",
nullptr};
static const char* harmony_object_values_entries_natives[] = {nullptr};
+ static const char* harmony_object_own_property_descriptors_natives[] = {
+ nullptr};
for (int i = ExperimentalNatives::GetDebuggerCount();
i < ExperimentalNatives::GetBuiltinsCount(); i++) {
« no previous file with comments | « no previous file | src/builtins.h » ('j') | src/builtins.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698