summaryrefslogtreecommitdiffstats
path: root/js/src/jit-test/tests/basic/testBug772328.js
blob: 4b465b0a22ddfac9b6194c440459e6afef3ab8b0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
function f(x) {
    function x() {}
    arguments[0] = 42;
    return x;
}
assertEq(f(0), 42);

function g(x) {
    function x() {}
    assertEq(arguments[0], x);
}
g(0);

var caught = false;
try {
    (function h(x) { function x() {} }).blah.baz;
} catch (e) {
    caught = true;
}
assertEq(caught, true);