/js/src/jit-test/tests/jaeger/recompile/callic.js
http://github.com/zpao/v8monkey · JavaScript · 27 lines · 20 code · 5 blank · 2 comment · 1 complexity · 77b9c2e7d7164a9faa1c43fe67ff8dfd MD5 · raw file
- /* Recompilation while being processed by a call IC. */
- var g;
- function foo() {
- for (g = 0; g < 5; g++) {
- bar();
- }
- function bar() {
- with ({}) {
- eval("g = undefined;");
- }
- }
- }
- foo();
- assertEq(g, NaN);
- /* Recompilation while being processed by a native call IC. */
- function native() {
- var x;
- x = x;
- x = Math.ceil(NaN);
- assertEq(x, NaN);
- }
- native();