Debian Codegraph @

js/src/jit-test/tests/fields/private-reflect-01.js

raw
1 function rp(x) {
2 return Reflect.parse(x);
3 };
4
5 rp(`(
6 class {
7 static #m = 'test262';
8 }
9 )`);
10
11 rp(`(
12 class {
13 static #m = 'test262';
14 constructor() {
15 #m in {};
16 }
17 }
18 )`);
19
20 rp(`(
21 class {
22 #m = 'test262';
23 }
24 )`);
25
26 rp(`(
27 class {
28 #m = 'test262';
29 gm() {
30 this.#m++;
31 this.#m--;
32 this.#m?.x;
33 o[this.#m];
34 return this.#m;
35 }
36 sm() {
37 this.#m = 12;
38 }
39 }
40 )`);
41
42 rp(`(
43 class {
44 static #m = 'test262';
45 static gm() {
46 this.#m++;
47 this.#m--;
48 this.#m?.x;
49 o[this.#m];
50 return this.#m;
51 }
52 static sm() {
53 this.#m = 12;
54 }
55 }
56 )`);