js/src/tests/js1_8_5/regress/regress-810525.js

branch
TOR_BUG_3246
changeset 7
129ffea94266
equal deleted inserted replaced
-1:000000000000 0:4e21913a8cf3
1 /*
2 * Any copyright is dedicated to the Public Domain.
3 * http://creativecommons.org/licenses/publicdomain/
4 */
5 var expect = '';
6 var actual = '';
7
8 function test(s) {
9 var threw = false;
10 try {
11 eval(s);
12 } catch (e) {
13 assertEq(e.message.indexOf('(intermediate value)'), -1);
14 threw = true;
15 } finally {
16 assertEq(threw, true);
17 }
18 }
19
20 test("({p:1, q:2}).m()");
21 test("[].m()");
22 test("[1,2,3].m()");
23 test("/hi/.m()");
24
25 reportCompare(0, 0, "ok");

mercurial