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

Unified Diff: src/bootstrapper.cc

Issue 1029783003: Populate PrototypeInfo with prototype_object value (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 9 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/factory.h » ('j') | no next file with comments »
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 097437e7c1e8723e1189feb46eb9a2289a0f67b8..b121d3e1d6aebd74b6bdf9bb8ab1972f15b11cda 100644
--- a/src/bootstrapper.cc
+++ b/src/bootstrapper.cc
@@ -487,6 +487,7 @@ Handle<JSFunction> Genesis::CreateEmptyFunction(Isolate* isolate) {
"EmptyObjectPrototype");
map->set_is_prototype_map(true);
object_function_prototype->set_map(*map);
+ Map::SetPrototypeObject(map, object_function_prototype, isolate);
native_context()->set_initial_object_prototype(*object_function_prototype);
// For bootstrapping set the array prototype to be the same as the object
@@ -512,6 +513,7 @@ Handle<JSFunction> Genesis::CreateEmptyFunction(Isolate* isolate) {
Map::SetPrototype(empty_function_map, object_function_prototype);
empty_function_map->set_is_prototype_map(true);
empty_function->set_map(*empty_function_map);
+ Map::SetPrototypeObject(empty_function_map, empty_function, isolate);
// --- E m p t y ---
Handle<String> source = factory->NewStringFromStaticChars("() {}");
@@ -1127,6 +1129,7 @@ void Genesis::InitializeGlobal(Handle<GlobalObject> global_object,
Smi::FromInt(0),
SKIP_WRITE_BARRIER); // It's a Smi.
proto_map->set_is_prototype_map(true);
+ Map::SetPrototypeObject(proto_map, proto, isolate);
Map::SetPrototype(initial_map, proto);
factory->SetRegExpIrregexpData(Handle<JSRegExp>::cast(proto),
JSRegExp::IRREGEXP, factory->empty_string(),
« no previous file with comments | « no previous file | src/factory.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698