Index: src/ic.cc |
diff --git a/src/ic.cc b/src/ic.cc |
index 517ed188d89b671d13324ba3f1337f3101eb016c..0ca70d3711a47971f5c3a0d240bd47dae2c16eae 100644 |
--- a/src/ic.cc |
+++ b/src/ic.cc |
@@ -1134,8 +1134,7 @@ static bool LookupForWrite(Handle<JSObject> receiver, |
// receiver when trying to fetch extra information from the transition. |
receiver->map()->LookupTransition(*holder, *name, lookup); |
if (!lookup->IsTransition()) return false; |
- PropertyDetails target_details = |
- lookup->GetTransitionDetails(receiver->map()); |
+ PropertyDetails target_details = lookup->GetTransitionDetails(); |
if (target_details.IsReadOnly()) return false; |
// If the value that's being stored does not fit in the field that the |
@@ -1146,7 +1145,7 @@ static bool LookupForWrite(Handle<JSObject> receiver, |
// transition target. |
ASSERT(!receiver->map()->is_deprecated()); |
if (!value->FitsRepresentation(target_details.representation())) { |
- Handle<Map> target(lookup->GetTransitionMapFromMap(receiver->map())); |
+ Handle<Map> target(lookup->GetTransitionTarget()); |
Map::GeneralizeRepresentation( |
target, target->LastAdded(), |
value->OptimalRepresentation(), FORCE_FIELD); |
@@ -1319,12 +1318,8 @@ Handle<Code> StoreIC::CompileHandler(LookupResult* lookup, |
case TRANSITION: { |
// Explicitly pass in the receiver map since LookupForWrite may have |
// stored something else than the receiver in the holder. |
- Handle<Map> transition( |
- lookup->GetTransitionTarget(receiver->map()), isolate()); |
- int descriptor = transition->LastAdded(); |
- |
- DescriptorArray* target_descriptors = transition->instance_descriptors(); |
- PropertyDetails details = target_descriptors->GetDetails(descriptor); |
+ Handle<Map> transition(lookup->GetTransitionTarget()); |
+ PropertyDetails details = transition->GetLastDescriptorDetails(); |
if (details.type() == CALLBACKS || details.attributes() != NONE) break; |