| Index: src/runtime/runtime-object.cc
|
| diff --git a/src/runtime/runtime-object.cc b/src/runtime/runtime-object.cc
|
| index ad69a1004bf27bb847b8ce5c6fe46427390d690d..57191a8fc31d03cfdc88927d42521c06fe540182 100644
|
| --- a/src/runtime/runtime-object.cc
|
| +++ b/src/runtime/runtime-object.cc
|
| @@ -1538,18 +1538,20 @@
|
| NewTypeError(MessageTemplate::kInstanceofNonobjectProto, prototype));
|
| }
|
| // Return whether or not {prototype} is in the prototype chain of {object}.
|
| - return isolate->heap()->ToBoolean(
|
| - object->HasInPrototypeChain(isolate, *prototype));
|
| + Maybe<bool> result = Object::HasInPrototypeChain(isolate, object, prototype);
|
| + MAYBE_RETURN(result, isolate->heap()->exception());
|
| + return isolate->heap()->ToBoolean(result.FromJust());
|
| }
|
|
|
|
|
| RUNTIME_FUNCTION(Runtime_HasInPrototypeChain) {
|
| - SealHandleScope scope(isolate);
|
| + HandleScope scope(isolate);
|
| DCHECK_EQ(2, args.length());
|
| - CONVERT_ARG_CHECKED(Object, object, 0);
|
| - CONVERT_ARG_CHECKED(Object, prototype, 1);
|
| - return isolate->heap()->ToBoolean(
|
| - object->HasInPrototypeChain(isolate, prototype));
|
| + CONVERT_ARG_HANDLE_CHECKED(Object, object, 0);
|
| + CONVERT_ARG_HANDLE_CHECKED(Object, prototype, 1);
|
| + Maybe<bool> result = Object::HasInPrototypeChain(isolate, object, prototype);
|
| + MAYBE_RETURN(result, isolate->heap()->exception());
|
| + return isolate->heap()->ToBoolean(result.FromJust());
|
| }
|
|
|
|
|
|
|