v8/test/mjsunit/regress/regress-crbug-779344.js
Yang Guo 1e77461d62 Perform stack check on Proxy call trap.
Proxy's call trap can be used to cause recursion.

R=bmeurer@chromium.org, tebbi@chromium.org

Bug: chromium:779344
Change-Id: I19c989f618f7230028ebe18c3415bc3f4bd72b93
Reviewed-on: https://chromium-review.googlesource.com/743782
Reviewed-by: Benedikt Meurer <bmeurer@chromium.org>
Commit-Queue: Yang Guo <yangguo@chromium.org>
Cr-Commit-Position: refs/heads/master@{#49069}
2017-11-02 07:29:34 +00:00

11 lines
294 B
JavaScript

// Copyright 2017 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 o = {};
var proxy = new Proxy(() => {}, o);
o.apply = proxy;
assertThrows(
() => Function.prototype.call.call(proxy)
);