summaryrefslogtreecommitdiff
path: root/deps/v8/test/mjsunit/maglev/regress/regress-1392936.js
blob: 12a09d7184f64757004a57b7363739fb84803a50 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
// Copyright 2022 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.
//
// Flags: --maglev --allow-natives-syntax

var func = function(){}
function foo() {
    let call = func.call;
    call();
}
%PrepareFunctionForOptimization(foo);
try {foo();} catch {}
try {foo();} catch {}
%OptimizeMaglevOnNextCall(foo);
try {foo();} catch {}