File: destructuringLvalue.jstest

package info (click to toggle)
htmlunit-core-js 2.8-1
  • links: PTS, VCS
  • area: main
  • in suites: jessie, jessie-kfreebsd, stretch, wheezy
  • size: 5,804 kB
  • ctags: 10,088
  • sloc: java: 75,059; xml: 889; sh: 14; makefile: 11
file content (13 lines) | stat: -rw-r--r-- 468 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
/* TODO(stevey): fix this test
var obj = { p:3 };
var arr = [ 3 ];
[obj.p] = [9];
if (obj.p != 9) throw "obj.p not set by array destructuring assignment";
[arr[0]] = [9];
if (arr[0] != 9) throw "arr[0] not set by array destructuring assignment";
({prop:obj.p} = {prop:12});
if (obj.p != 12) throw "obj.p not set by object destructuring assignment";
({prop:arr[0]} = {prop:12});
if (arr[0] != 12) throw "arr[0] not set by object destructuring assignment";
*/
"success"