Commit 8c9fe2d8 authored by Yang Guo's avatar Yang Guo Committed by Commit Bot

Use null prototype for extras binding and utils objects

R=bmeurer@chromium.org

Bug: chromium:934201
Change-Id: I73048fef3afea5d06be88a2768d77f7e349daef5
Reviewed-on: https://chromium-review.googlesource.com/c/1488760Reviewed-by: 's avatarBenedikt Meurer <bmeurer@chromium.org>
Commit-Queue: Yang Guo <yangguo@chromium.org>
Cr-Commit-Position: refs/heads/master@{#59861}
parent c47a8f63
...@@ -4703,8 +4703,7 @@ bool Genesis::InstallNatives() { ...@@ -4703,8 +4703,7 @@ bool Genesis::InstallNatives() {
// Set up the extras utils object as a shared container between native // Set up the extras utils object as a shared container between native
// scripts and extras. (Extras consume things added there by native scripts.) // scripts and extras. (Extras consume things added there by native scripts.)
Handle<JSObject> extras_utils = Handle<JSObject> extras_utils = factory()->NewJSObjectWithNullProto();
factory()->NewJSObject(isolate()->object_function());
native_context()->set_extras_utils_object(*extras_utils); native_context()->set_extras_utils_object(*extras_utils);
InstallInternalPackedArray(extras_utils, "InternalPackedArray"); InstallInternalPackedArray(extras_utils, "InternalPackedArray");
...@@ -5082,8 +5081,7 @@ bool Genesis::InstallNatives() { ...@@ -5082,8 +5081,7 @@ bool Genesis::InstallNatives() {
bool Genesis::InstallExtraNatives() { bool Genesis::InstallExtraNatives() {
HandleScope scope(isolate()); HandleScope scope(isolate());
Handle<JSObject> extras_binding = Handle<JSObject> extras_binding = factory()->NewJSObjectWithNullProto();
factory()->NewJSObject(isolate()->object_function());
// binding.isTraceCategoryEnabled(category) // binding.isTraceCategoryEnabled(category)
SimpleInstallFunction(isolate(), extras_binding, "isTraceCategoryEnabled", SimpleInstallFunction(isolate(), extras_binding, "isTraceCategoryEnabled",
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment