Index: src/objects.cc |
diff --git a/src/objects.cc b/src/objects.cc |
index d69134c470faac46f7ed6e9d6b5e8e7942ded462..ee0ac2d0ca496d0801e817ced13c740ac1f4cc3c 100644 |
--- a/src/objects.cc |
+++ b/src/objects.cc |
@@ -5825,10 +5825,11 @@ Object* JSObject::GetPropertyPostInterceptor(JSObject* receiver, |
} |
-Object* JSObject::GetPropertyWithInterceptorProper( |
+bool JSObject::GetPropertyWithInterceptorProper( |
JSObject* receiver, |
String* name, |
- PropertyAttributes* attributes) { |
+ PropertyAttributes* attributes, |
+ Object** result_object) { |
HandleScope scope; |
Handle<InterceptorInfo> interceptor(GetNamedInterceptor()); |
Handle<JSObject> receiver_handle(receiver); |
@@ -5849,14 +5850,17 @@ Object* JSObject::GetPropertyWithInterceptorProper( |
VMState state(EXTERNAL); |
result = getter(v8::Utils::ToLocal(name_handle), info); |
} |
- if (!Top::has_scheduled_exception() && !result.IsEmpty()) { |
+ if (Top::has_scheduled_exception()) { |
+ return false; |
+ } |
+ if (!result.IsEmpty()) { |
*attributes = NONE; |
- return *v8::Utils::OpenHandle(*result); |
+ *result_object = *v8::Utils::OpenHandle(*result); |
+ return true; |
} |
} |
- *attributes = ABSENT; |
- return Heap::undefined_value(); |
+ return false; |
} |
@@ -5870,13 +5874,12 @@ Object* JSObject::GetInterceptorPropertyWithLookupHint( |
Handle<JSObject> holder_handle(this); |
Handle<String> name_handle(name); |
- Object* result = GetPropertyWithInterceptorProper(receiver, |
- name, |
- attributes); |
- if (*attributes != ABSENT) { |
+ Object* result = NULL; |
+ if (GetPropertyWithInterceptorProper(receiver, name, attributes, &result)) { |
return result; |
+ } else { |
+ RETURN_IF_SCHEDULED_EXCEPTION(); |
} |
- RETURN_IF_SCHEDULED_EXCEPTION(); |
int property_index = lookup_hint->value(); |
if (property_index >= 0) { |
@@ -5921,11 +5924,12 @@ Object* JSObject::GetPropertyWithInterceptor( |
Handle<JSObject> holder_handle(this); |
Handle<String> name_handle(name); |
- Object* result = GetPropertyWithInterceptorProper(receiver, name, attributes); |
- if (*attributes != ABSENT) { |
+ Object* result = NULL; |
+ if (GetPropertyWithInterceptorProper(receiver, name, attributes, &result)) { |
return result; |
+ } else { |
+ RETURN_IF_SCHEDULED_EXCEPTION(); |
} |
- RETURN_IF_SCHEDULED_EXCEPTION(); |
result = holder_handle->GetPropertyPostInterceptor( |
*receiver_handle, |