Index: src/heap.cc |
diff --git a/src/heap.cc b/src/heap.cc |
index 8e724ebb6de99674ebd72883f1baa5ac30372899..a448292789ad72511cb6c6922dc903bc1f14eb8a 100644 |
--- a/src/heap.cc |
+++ b/src/heap.cc |
@@ -4180,10 +4180,10 @@ MaybeObject* Heap::AllocateGlobalObject(JSFunction* constructor) { |
InitializeJSObjectFromMap(global, dictionary, map); |
// Create a new map for the global object. |
- { MaybeObject* maybe_obj = map->CopyDropDescriptors(); |
- if (!maybe_obj->ToObject(&obj)) return maybe_obj; |
+ Map* new_map; |
+ { MaybeObject* maybe_map = map->CopyDropDescriptors(); |
+ if (!maybe_map->To(&new_map)) return maybe_map; |
} |
- Map* new_map = Map::cast(obj); |
// Set up the global object as a normalized object. |
global->set_map(new_map); |