summaryrefslogtreecommitdiffstats
path: root/js/src/jit-test/tests/jaeger/regalloc-double.js
blob: 8d49eb54f578c93f644ff8ef79f4bbd3351f2d0e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
// register allocation involving doubles.

function foo(a,b) {
  var c;
  if (a < b) {
    c = a + 1;
  } else {
    c = 0.5;
  }
  return c;
}
assertEq(foo(0, 1), 1);