PageRenderTime 23ms CodeModel.GetById 15ms app.highlight 4ms RepoModel.GetById 1ms app.codeStats 0ms

/js/src/jit-test/tests/basic/testApplyInterpretLowered.js

http://github.com/zpao/v8monkey
JavaScript | 15 lines | 11 code | 3 blank | 1 comment | 3 complexity | 7b8b10a8364c31b6e82a44a6697bf783 MD5 | raw file
 1
 2/* Read correct return value when the interpreter pops a lowered call/apply. */
 3
 4function recompile() {}
 5
 6function foo() {
 7  if (arguments[0] == 9)
 8    recompile();
 9  return arguments[0];
10}
11function bar() {
12  for (var i = 0; i < 10; i++)
13    assertEq(foo.apply(null, [i]), i);
14}
15bar();