Index: src/objects.cc |
diff --git a/src/objects.cc b/src/objects.cc |
index 935e875f5105bf28dd371baa224c89823db689b4..cd748b019599337e78878d14e8f83281e5530f72 100644 |
--- a/src/objects.cc |
+++ b/src/objects.cc |
@@ -119,6 +119,17 @@ bool Object::BooleanValue() { |
} |
+bool Object::IsCallable() { |
+ Object* fun = this; |
+ while (fun->IsJSFunctionProxy()) { |
+ fun = JSFunctionProxy::cast(fun)->call_trap(); |
+ } |
+ return fun->IsJSFunction() || |
+ (fun->IsHeapObject() && |
+ HeapObject::cast(fun)->map()->has_instance_call_handler()); |
+} |
+ |
+ |
void Object::Lookup(Name* name, LookupResult* result) { |
Object* holder = NULL; |
if (IsJSReceiver()) { |
@@ -2187,21 +2198,6 @@ void JSObject::EnqueueChangeRecord(Handle<JSObject> object, |
} |
-void JSObject::DeliverChangeRecords(Isolate* isolate) { |
- ASSERT(isolate->observer_delivery_pending()); |
- bool threw = false; |
- Execution::Call( |
- isolate, |
- isolate->observers_deliver_changes(), |
- isolate->factory()->undefined_value(), |
- 0, |
- NULL, |
- &threw); |
- ASSERT(!threw); |
- isolate->set_observer_delivery_pending(false); |
-} |
- |
- |
Handle<Object> JSObject::SetPropertyPostInterceptor( |
Handle<JSObject> object, |
Handle<Name> name, |