diff --git a/common.gypi b/common.gypi index cc9107616a65a5..44e41a9753babf 100644 --- a/common.gypi +++ b/common.gypi @@ -39,7 +39,7 @@ # Reset this number to 0 on major V8 upgrades. # Increment by one for each non-official patch applied to deps/v8. - 'v8_embedder_string': '-node.15', + 'v8_embedder_string': '-node.16', ##### V8 defaults for Node.js ##### diff --git a/deps/v8/src/builtins/proxy-get-prototype-of.tq b/deps/v8/src/builtins/proxy-get-prototype-of.tq index 653d4503d16477..5b90a1bb02a064 100644 --- a/deps/v8/src/builtins/proxy-get-prototype-of.tq +++ b/deps/v8/src/builtins/proxy-get-prototype-of.tq @@ -33,7 +33,7 @@ namespace proxy { // 8. If Type(handlerProto) is neither Object nor Null, throw a TypeError // exception. - if (!Is(handlerProto)) { + if (!Is(handlerProto) && handlerProto != Null) { goto ThrowProxyGetPrototypeOfInvalid; } diff --git a/deps/v8/test/mjsunit/regress/regress-9781.js b/deps/v8/test/mjsunit/regress/regress-9781.js new file mode 100644 index 00000000000000..6d3e3162d39c27 --- /dev/null +++ b/deps/v8/test/mjsunit/regress/regress-9781.js @@ -0,0 +1,11 @@ +// Copyright 2019 the V8 project authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +var proto = Object.getPrototypeOf(new Proxy(Object.create(null), { + getPrototypeOf(target) { + return Reflect.getPrototypeOf(target); + } +} )); + +assertEquals(proto, null);