summaryrefslogtreecommitdiffstats
path: root/js/src/jit-test/tests/parser/bug-844805-2.js
blob: 5a278ef9b1aaef2f5b3bcb458ea0cf9a9b1c09a1 (plain)
1
2
3
4
5
6
7
8
9
10
// Constant folding does not affect strict delete.

function f(x) {
    "use strict";

    // This senseless delete-expression is legal even in strict mode. Per ES5.1
    // 11.4.1 step 2, it does nothing and returns true.
    return delete (1 ? x : x);
}
assertEq(f(), true);