summaryrefslogtreecommitdiffstats
path: root/js/src/jit-test/tests/jaeger/tableSwitchDouble.js
blob: df9fe2a55f10a92ce52ed617baf6e42c7d850a74 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13

function f(a) {
    switch(a) {
        case 3: return 3;
        case 4: return 4;
        default: return -1;
    }
}

assertEq(f(-0.0), -1);
assertEq(f(3.14), -1);
assertEq(f(12.34), -1);