Debian Codegraph @

js/src/jit-test/tests/warp/scalar-replace-array-construct-array-04.js

raw
1 setJitCompilerOption("inlining.bytecode-max-length", 200);
2
3 var result;
4
5 function g(a, b) {
6 with ({}) {}
7 result = a + b;
8 }
9
10 function escape() { with({}) {} }
11
12 function f(...args) {
13 escape(args);
14 for (var i = 0; i < 50; ++i) {
15 new g(...args);
16 }
17 }
18
19 // |f| must be small enough to be inlinable.
20 assertEq(isSmallFunction(f), true);
21
22 f(1, 2);
23 assertEq(result, 3);
24
25 f("");
26 assertEq(result, "undefined");