Index: src/api.cc |
diff --git a/src/api.cc b/src/api.cc |
index 7c484de53ee1e537a8abeefdce1e0cab69e4952e..e5ed581aaeece9936220d7b740d969cfa89e68f7 100644 |
--- a/src/api.cc |
+++ b/src/api.cc |
@@ -3205,6 +3205,26 @@ PropertyAttribute v8::Object::GetPropertyAttributes(v8::Handle<Value> key) { |
} |
+Local<Value> v8::Object::GetOwnPropertyDescriptor(Local<String> key) { |
+ i::Isolate* isolate = Utils::OpenHandle(this)->GetIsolate(); |
+ ON_BAILOUT(isolate, "v8::Object::GetOwnPropertyDescriptor()", |
+ return Local<Value>()); |
+ ENTER_V8(isolate); |
+ i::Handle<i::JSObject> obj = Utils::OpenHandle(this); |
+ i::Handle<i::Name> key_name = Utils::OpenHandle(*key); |
+ i::Handle<i::Object> args[] = { obj, key_name }; |
+ EXCEPTION_PREAMBLE(isolate); |
+ i::Handle<i::Object> result; |
+ has_pending_exception = !CallV8HeapFunction( |
+ "ObjectGetOwnPropertyDescriptor", |
+ isolate->factory()->undefined_value(), |
+ ARRAY_SIZE(args), |
+ args).ToHandle(&result); |
+ EXCEPTION_BAILOUT_CHECK(isolate, Local<Value>()); |
+ return Utils::ToLocal(result); |
+} |
+ |
+ |
Local<Value> v8::Object::GetPrototype() { |
i::Isolate* isolate = Utils::OpenHandle(this)->GetIsolate(); |
ON_BAILOUT(isolate, "v8::Object::GetPrototype()", return Local<v8::Value>()); |