Don't do a second lookup as we have it already.
Review URL: http://codereview.chromium.org/149007 git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@2306 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
This commit is contained in:
parent
3d065ccebe
commit
9110beb772
13
src/ic.cc
13
src/ic.cc
@ -328,11 +328,11 @@ Object* CallIC::LoadFunction(State state,
|
||||
UpdateCaches(&lookup, state, object, name);
|
||||
}
|
||||
|
||||
// Get the property.
|
||||
PropertyAttributes attr;
|
||||
result = object->GetProperty(*object, &lookup, *name, &attr);
|
||||
if (result->IsFailure()) return result;
|
||||
if (lookup.type() == INTERCEPTOR) {
|
||||
// Get the property.
|
||||
PropertyAttributes attr;
|
||||
result = object->GetProperty(*name, &attr);
|
||||
if (result->IsFailure()) return result;
|
||||
// If the object does not have the requested property, check which
|
||||
// exception we need to throw.
|
||||
if (attr == ABSENT) {
|
||||
@ -341,11 +341,6 @@ Object* CallIC::LoadFunction(State state,
|
||||
}
|
||||
return TypeError("undefined_method", object, name);
|
||||
}
|
||||
} else {
|
||||
// Lookup is valid and no interceptors are involved. Get the
|
||||
// property.
|
||||
result = object->GetProperty(*name);
|
||||
if (result->IsFailure()) return result;
|
||||
}
|
||||
|
||||
ASSERT(result != Heap::the_hole_value());
|
||||
|
Loading…
Reference in New Issue
Block a user