@ibyar/expressions 0.5.1 → 0.5.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (187) hide show
  1. package/LICENSE +1 -1
  2. package/README.md +5 -4
  3. package/api/abstract.d.ts +5 -6
  4. package/api/abstract.js +3 -3
  5. package/api/abstract.js.map +1 -1
  6. package/api/class/class.d.ts +202 -0
  7. package/api/class/class.js +635 -0
  8. package/api/class/class.js.map +1 -0
  9. package/api/class/decorator.d.ts +20 -0
  10. package/api/class/decorator.js +48 -0
  11. package/api/class/decorator.js.map +1 -0
  12. package/api/computing/call.d.ts +3 -1
  13. package/api/computing/call.js +16 -4
  14. package/api/computing/call.js.map +1 -1
  15. package/api/computing/debugger.d.ts +15 -0
  16. package/api/computing/debugger.js +35 -0
  17. package/api/computing/debugger.js.map +1 -0
  18. package/api/computing/new.d.ts +2 -1
  19. package/api/computing/new.js +4 -0
  20. package/api/computing/new.js.map +1 -1
  21. package/api/computing/rest.d.ts +6 -6
  22. package/api/computing/rest.js +5 -2
  23. package/api/computing/rest.js.map +1 -1
  24. package/api/computing/return.d.ts +2 -1
  25. package/api/computing/return.js +3 -0
  26. package/api/computing/return.js.map +1 -1
  27. package/api/computing/spread.d.ts +2 -1
  28. package/api/computing/spread.js +5 -2
  29. package/api/computing/spread.js.map +1 -1
  30. package/api/computing/throw.d.ts +2 -1
  31. package/api/computing/throw.js +3 -0
  32. package/api/computing/throw.js.map +1 -1
  33. package/api/computing/yield.d.ts +2 -1
  34. package/api/computing/yield.js +3 -0
  35. package/api/computing/yield.js.map +1 -1
  36. package/api/definition/array.d.ts +12 -12
  37. package/api/definition/array.js +31 -25
  38. package/api/definition/array.js.map +1 -1
  39. package/api/definition/bind.d.ts +2 -2
  40. package/api/definition/bind.js +1 -1
  41. package/api/definition/bind.js.map +1 -1
  42. package/api/definition/function.d.ts +40 -51
  43. package/api/definition/function.js +291 -309
  44. package/api/definition/function.js.map +1 -1
  45. package/api/definition/member.d.ts +2 -2
  46. package/api/definition/member.js +1 -1
  47. package/api/definition/member.js.map +1 -1
  48. package/api/definition/object.d.ts +15 -12
  49. package/api/definition/object.js +43 -13
  50. package/api/definition/object.js.map +1 -1
  51. package/api/definition/statement.d.ts +2 -2
  52. package/api/definition/statement.js +7 -3
  53. package/api/definition/statement.js.map +1 -1
  54. package/api/definition/values.d.ts +35 -50
  55. package/api/definition/values.js +66 -149
  56. package/api/definition/values.js.map +1 -1
  57. package/api/deserialize/deserialize.d.ts +2 -1
  58. package/api/deserialize/deserialize.js +4 -1
  59. package/api/deserialize/deserialize.js.map +1 -1
  60. package/api/deserialize/type-store.d.ts +2 -2
  61. package/api/deserialize/type-store.js.map +1 -1
  62. package/api/expression.d.ts +13 -18
  63. package/api/expression.js.map +1 -1
  64. package/api/index.d.ts +2 -0
  65. package/api/index.js +2 -0
  66. package/api/index.js.map +1 -1
  67. package/api/module/common.d.ts +29 -0
  68. package/api/module/common.js +71 -0
  69. package/api/module/common.js.map +1 -0
  70. package/api/module/export.d.ts +66 -25
  71. package/api/module/export.js +270 -58
  72. package/api/module/export.js.map +1 -1
  73. package/api/module/import.d.ts +61 -25
  74. package/api/module/import.js +226 -68
  75. package/api/module/import.js.map +1 -1
  76. package/api/operators/assignment.d.ts +2 -2
  77. package/api/operators/assignment.js +1 -1
  78. package/api/operators/assignment.js.map +1 -1
  79. package/api/operators/await.d.ts +2 -2
  80. package/api/operators/await.js +1 -1
  81. package/api/operators/await.js.map +1 -1
  82. package/api/operators/binary.d.ts +2 -2
  83. package/api/operators/binary.js +1 -1
  84. package/api/operators/binary.js.map +1 -1
  85. package/api/operators/chaining.d.ts +2 -2
  86. package/api/operators/chaining.js +1 -1
  87. package/api/operators/chaining.js.map +1 -1
  88. package/api/operators/comma.d.ts +2 -2
  89. package/api/operators/comma.js +2 -2
  90. package/api/operators/comma.js.map +1 -1
  91. package/api/operators/grouping.d.ts +2 -2
  92. package/api/operators/grouping.js +1 -1
  93. package/api/operators/grouping.js.map +1 -1
  94. package/api/operators/logical.d.ts +2 -2
  95. package/api/operators/logical.js +1 -1
  96. package/api/operators/logical.js.map +1 -1
  97. package/api/operators/pipeline.d.ts +2 -2
  98. package/api/operators/pipeline.js +1 -1
  99. package/api/operators/pipeline.js.map +1 -1
  100. package/api/operators/ternary.d.ts +2 -2
  101. package/api/operators/ternary.js +1 -1
  102. package/api/operators/ternary.js.map +1 -1
  103. package/api/operators/unary.d.ts +3 -3
  104. package/api/operators/unary.js +4 -3
  105. package/api/operators/unary.js.map +1 -1
  106. package/api/operators/update.d.ts +2 -2
  107. package/api/operators/update.js +1 -1
  108. package/api/operators/update.js.map +1 -1
  109. package/api/{app/program.d.ts → program.d.ts} +8 -9
  110. package/api/program.js +45 -0
  111. package/api/program.js.map +1 -0
  112. package/api/statement/control/block.d.ts +4 -5
  113. package/api/statement/control/block.js +22 -23
  114. package/api/statement/control/block.js.map +1 -1
  115. package/api/statement/control/empty.d.ts +1 -1
  116. package/api/statement/control/empty.js.map +1 -1
  117. package/api/statement/control/if.d.ts +2 -2
  118. package/api/statement/control/if.js +1 -1
  119. package/api/statement/control/if.js.map +1 -1
  120. package/api/statement/control/switch.d.ts +4 -5
  121. package/api/statement/control/switch.js +13 -9
  122. package/api/statement/control/switch.js.map +1 -1
  123. package/api/statement/control/terminate.d.ts +38 -13
  124. package/api/statement/control/terminate.js +81 -20
  125. package/api/statement/control/terminate.js.map +1 -1
  126. package/api/statement/declarations/declares.d.ts +17 -16
  127. package/api/statement/declarations/declares.js +24 -19
  128. package/api/statement/declarations/declares.js.map +1 -1
  129. package/api/statement/iterations/for.d.ts +5 -5
  130. package/api/statement/iterations/for.js +29 -23
  131. package/api/statement/iterations/for.js.map +1 -1
  132. package/api/statement/iterations/while.d.ts +3 -3
  133. package/api/statement/iterations/while.js +17 -13
  134. package/api/statement/iterations/while.js.map +1 -1
  135. package/api/utils.d.ts +5 -0
  136. package/api/utils.js +4 -0
  137. package/api/utils.js.map +1 -0
  138. package/package.json +5 -5
  139. package/scope/event.d.ts +2 -2
  140. package/scope/event.js +8 -14
  141. package/scope/event.js.map +1 -1
  142. package/scope/finalizer.d.ts +4 -0
  143. package/scope/finalizer.js +11 -0
  144. package/scope/finalizer.js.map +1 -0
  145. package/scope/proxy.d.ts +2 -3
  146. package/scope/proxy.js +22 -26
  147. package/scope/proxy.js.map +1 -1
  148. package/scope/scope.d.ts +42 -53
  149. package/scope/scope.js +73 -143
  150. package/scope/scope.js.map +1 -1
  151. package/scope/stack.d.ts +43 -26
  152. package/scope/stack.js +148 -102
  153. package/scope/stack.js.map +1 -1
  154. package/v8/enums.d.ts +204 -0
  155. package/v8/enums.js +375 -0
  156. package/v8/enums.js.map +1 -0
  157. package/v8/index.d.ts +2 -1
  158. package/v8/index.js +2 -1
  159. package/v8/index.js.map +1 -1
  160. package/v8/inline.d.ts +177 -0
  161. package/v8/inline.js +1973 -0
  162. package/v8/inline.js.map +1 -0
  163. package/v8/nodes.d.ts +8 -7
  164. package/v8/nodes.js +37 -63
  165. package/v8/nodes.js.map +1 -1
  166. package/v8/parser.d.ts +41 -151
  167. package/v8/parser.js +507 -1578
  168. package/v8/parser.js.map +1 -1
  169. package/v8/stream.d.ts +35 -3
  170. package/v8/stream.js +616 -164
  171. package/v8/stream.js.map +1 -1
  172. package/v8/token.d.ts +15 -9
  173. package/v8/token.js +79 -46
  174. package/v8/token.js.map +1 -1
  175. package/visit/visitor.js +4 -7
  176. package/visit/visitor.js.map +1 -1
  177. package/api/app/class.d.ts +0 -117
  178. package/api/app/class.js +0 -292
  179. package/api/app/class.js.map +0 -1
  180. package/api/app/program.js +0 -39
  181. package/api/app/program.js.map +0 -1
  182. package/api/module/module.d.ts +0 -26
  183. package/api/module/module.js +0 -63
  184. package/api/module/module.js.map +0 -1
  185. package/v8/app.d.ts +0 -0
  186. package/v8/app.js +0 -2
  187. package/v8/app.js.map +0 -1
package/api/app/class.js DELETED
@@ -1,292 +0,0 @@
1
- var MetaProperty_1, PrivateIdentifier_1, MethodDefinition_1, PropertyDefinition_1, ClassBody_1, ClassDeclaration_1, ClassExpression_1;
2
- import { __decorate, __metadata } from "tslib";
3
- import { AbstractExpressionNode } from '../abstract.js';
4
- import { Deserializer } from '../deserialize/deserialize.js';
5
- import { Identifier } from '../definition/values.js';
6
- import { MemberExpression } from '../definition/member.js';
7
- import { FunctionExpression } from '../definition/function.js';
8
- let MetaProperty = MetaProperty_1 = class MetaProperty extends MemberExpression {
9
- constructor(meta, property) {
10
- super(meta, property, false);
11
- this.meta = meta;
12
- }
13
- static getJsonName(identifier) {
14
- return Reflect.get(identifier, 'name');
15
- }
16
- static fromJSON(node, deserializer) {
17
- if (MetaProperty_1.getJsonName(node.meta) === 'new' && MetaProperty_1.getJsonName(node.property) === 'target') {
18
- return MetaProperty_1.NewTarget;
19
- }
20
- else if (MetaProperty_1.getJsonName(node.meta) === 'new' && MetaProperty_1.getJsonName(node.property) === 'meta') {
21
- return MetaProperty_1.ImportMeta;
22
- }
23
- return new MetaProperty_1(deserializer(node.meta), deserializer(node.property));
24
- }
25
- getMeta() {
26
- return this.meta;
27
- }
28
- shareVariables(scopeList) { }
29
- toString() {
30
- return `${this.meta.toString()}.${this.property.toString()}`;
31
- }
32
- toJson() {
33
- return {
34
- meta: this.meta.toJSON(),
35
- property: this.property.toJSON(),
36
- };
37
- }
38
- };
39
- MetaProperty.NewTarget = new MetaProperty_1(new Identifier('new'), new Identifier('target'));
40
- MetaProperty.ImportMeta = new MetaProperty_1(new Identifier('import'), new Identifier('meta'));
41
- MetaProperty = MetaProperty_1 = __decorate([
42
- Deserializer('MetaProperty'),
43
- __metadata("design:paramtypes", [Identifier, Identifier])
44
- ], MetaProperty);
45
- export { MetaProperty };
46
- let PrivateIdentifier = PrivateIdentifier_1 = class PrivateIdentifier extends Identifier {
47
- constructor(privateName) {
48
- super('ɵ_' + privateName);
49
- this.privateName = privateName;
50
- }
51
- static fromJSON(node) {
52
- return new PrivateIdentifier_1(node.name);
53
- }
54
- shareVariables(scopeList) { }
55
- toString() {
56
- return `#${this.privateName}`;
57
- }
58
- toJson() {
59
- return {
60
- name: this.privateName
61
- };
62
- }
63
- };
64
- PrivateIdentifier = PrivateIdentifier_1 = __decorate([
65
- Deserializer('PrivateIdentifier'),
66
- __metadata("design:paramtypes", [String])
67
- ], PrivateIdentifier);
68
- export { PrivateIdentifier };
69
- let MethodDefinition = MethodDefinition_1 = class MethodDefinition extends AbstractExpressionNode {
70
- constructor(kind, key, value, computed, isStatic) {
71
- super();
72
- this.kind = kind;
73
- this.key = key;
74
- this.value = value;
75
- this.computed = computed;
76
- this.static = isStatic;
77
- }
78
- static fromJSON(node, deserializer) {
79
- return new MethodDefinition_1(node.kind, deserializer(node.key), deserializer(node.value), node.computed, node.static);
80
- }
81
- getKind() {
82
- return this.kind;
83
- }
84
- getKey() {
85
- return this.key;
86
- }
87
- getValue() {
88
- return this.value;
89
- }
90
- isComputed() {
91
- return this.computed;
92
- }
93
- isStatic() {
94
- return this.static;
95
- }
96
- shareVariables(scopeList) { }
97
- set(stack, value) {
98
- throw new Error('Method not implemented.');
99
- }
100
- get(stack, thisContext) {
101
- throw new Error('Method not implemented.');
102
- }
103
- declareVariable(stack, scopeType, propertyValue) {
104
- throw new Error('Method not implemented.');
105
- }
106
- dependency(computed) {
107
- throw new Error('Method not implemented.');
108
- }
109
- dependencyPath(computed) {
110
- throw new Error('Method not implemented.');
111
- }
112
- toString() {
113
- throw new Error('Method not implemented.');
114
- }
115
- toJson() {
116
- return {
117
- kind: this.kind,
118
- key: this.key,
119
- value: this.value,
120
- computed: this.computed,
121
- static: this.static,
122
- };
123
- }
124
- };
125
- MethodDefinition = MethodDefinition_1 = __decorate([
126
- Deserializer('MethodDefinition'),
127
- __metadata("design:paramtypes", [String, Object, FunctionExpression, Boolean, Boolean])
128
- ], MethodDefinition);
129
- export { MethodDefinition };
130
- let PropertyDefinition = PropertyDefinition_1 = class PropertyDefinition extends AbstractExpressionNode {
131
- constructor(key, computed, isStatic, value) {
132
- super();
133
- this.key = key;
134
- this.computed = computed;
135
- this.value = value;
136
- this.static = isStatic;
137
- }
138
- static fromJSON(node, deserializer) {
139
- return new PropertyDefinition_1(deserializer(node.key), node.computed, node.static, node.value && deserializer(node.value));
140
- }
141
- getKey() {
142
- return this.key;
143
- }
144
- getValue() {
145
- return this.value;
146
- }
147
- isComputed() {
148
- return this.computed;
149
- }
150
- isStatic() {
151
- return this.static;
152
- }
153
- shareVariables(scopeList) { }
154
- set(stack, value) {
155
- throw new Error('Method not implemented.');
156
- }
157
- get(stack, thisContext) {
158
- throw new Error('Method not implemented.');
159
- }
160
- declareVariable(stack, scopeType, propertyValue) {
161
- throw new Error('Method not implemented.');
162
- }
163
- dependency(computed) {
164
- throw new Error('Method not implemented.');
165
- }
166
- dependencyPath(computed) {
167
- throw new Error('Method not implemented.');
168
- }
169
- toString() {
170
- throw new Error('Method not implemented.');
171
- }
172
- toJson() {
173
- return {
174
- key: this.key.toJSON(),
175
- computed: this.computed,
176
- static: this.static,
177
- value: this.value?.toJSON()
178
- };
179
- }
180
- };
181
- PropertyDefinition = PropertyDefinition_1 = __decorate([
182
- Deserializer('PropertyDefinition'),
183
- __metadata("design:paramtypes", [Object, Boolean, Boolean, Object])
184
- ], PropertyDefinition);
185
- export { PropertyDefinition };
186
- let ClassBody = ClassBody_1 = class ClassBody extends AbstractExpressionNode {
187
- constructor(body) {
188
- super();
189
- this.body = body;
190
- }
191
- static fromJSON(node, deserializer) {
192
- return new ClassBody_1(node.body.map(deserializer));
193
- }
194
- getBody() {
195
- return this.body;
196
- }
197
- shareVariables(scopeList) { }
198
- set(stack, value) {
199
- throw new Error('Method not implemented.');
200
- }
201
- get(stack, thisContext) {
202
- throw new Error('Method not implemented.');
203
- }
204
- dependency(computed) {
205
- throw new Error('Method not implemented.');
206
- }
207
- dependencyPath(computed) {
208
- throw new Error('Method not implemented.');
209
- }
210
- toString() {
211
- throw new Error('Method not implemented.');
212
- }
213
- toJson() {
214
- return {
215
- body: this.body.map(method => method.toJSON())
216
- };
217
- }
218
- };
219
- ClassBody = ClassBody_1 = __decorate([
220
- Deserializer('ClassBody'),
221
- __metadata("design:paramtypes", [Array])
222
- ], ClassBody);
223
- export { ClassBody };
224
- export class Class extends AbstractExpressionNode {
225
- constructor(body, id, superClass) {
226
- super();
227
- this.body = body;
228
- this.id = id;
229
- this.superClass = superClass;
230
- }
231
- getBody() {
232
- return this.body;
233
- }
234
- getId() {
235
- return this.id;
236
- }
237
- getSuperClass() {
238
- return this.superClass;
239
- }
240
- shareVariables(scopeList) { }
241
- set(stack) {
242
- throw new Error(`Class.#set() has no implementation.`);
243
- }
244
- get(stack) {
245
- throw new Error(`Class.#get() has no implementation.`);
246
- }
247
- dependency(computed) {
248
- throw new Error('Method not implemented.');
249
- }
250
- dependencyPath(computed) {
251
- throw new Error('Method not implemented.');
252
- }
253
- toString() {
254
- let classDeclaration = 'class ';
255
- if (this.id) {
256
- classDeclaration += this.id.toString();
257
- }
258
- if (this.superClass) {
259
- classDeclaration += ' extends ' + this.superClass.toString();
260
- }
261
- return `${classDeclaration} {${this.body.toString()}\n`;
262
- }
263
- toJson() {
264
- return {
265
- body: this.body.toJSON(),
266
- id: this.id?.toJSON(),
267
- superClass: this.superClass?.toJSON(),
268
- };
269
- }
270
- }
271
- let ClassDeclaration = ClassDeclaration_1 = class ClassDeclaration extends Class {
272
- static fromJSON(node, deserializer) {
273
- return new ClassDeclaration_1(deserializer(node.body), deserializer(node.id), node.superClass && deserializer(node.superClass));
274
- }
275
- declareVariable(stack, scopeType, propertyValue) {
276
- stack.declareVariable(scopeType, this.id.getName(), propertyValue);
277
- }
278
- };
279
- ClassDeclaration = ClassDeclaration_1 = __decorate([
280
- Deserializer('ClassDeclaration')
281
- ], ClassDeclaration);
282
- export { ClassDeclaration };
283
- let ClassExpression = ClassExpression_1 = class ClassExpression extends Class {
284
- static fromJSON(node, deserializer) {
285
- return new ClassExpression_1(deserializer(node.body), node.id && deserializer(node.id), node.superClass && deserializer(node.superClass));
286
- }
287
- };
288
- ClassExpression = ClassExpression_1 = __decorate([
289
- Deserializer('ClassExpression')
290
- ], ClassExpression);
291
- export { ClassExpression };
292
- //# sourceMappingURL=class.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"class.js","sourceRoot":"","sources":["../../../../src/expressions/api/app/class.ts"],"names":[],"mappings":";;AAMA,OAAO,EAAE,sBAAsB,EAAE,MAAM,gBAAgB,CAAC;AACxD,OAAO,EAAE,YAAY,EAAE,MAAM,+BAA+B,CAAC;AAC7D,OAAO,EAAE,UAAU,EAAE,MAAM,yBAAyB,CAAC;AACrD,OAAO,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAC3D,OAAO,EAAE,kBAAkB,EAAE,MAAM,2BAA2B,CAAC;AAW/D,IAAa,YAAY,oBAAzB,MAAa,YAAa,SAAQ,gBAAgB;IAsBjD,YAAoB,IAAgB,EAAE,QAAoB;QACzD,KAAK,CAAC,IAAI,EAAE,QAAQ,EAAE,KAAK,CAAC,CAAC;QADV,SAAI,GAAJ,IAAI,CAAY;IAEpC,CAAC;IAlBO,MAAM,CAAC,WAAW,CAAC,UAA0B;QACpD,OAAO,OAAO,CAAC,GAAG,CAAC,UAAU,EAAE,MAAM,CAAC,CAAC;IACxC,CAAC;IAED,MAAM,CAAC,QAAQ,CAAC,IAAkB,EAAE,YAAmC;QACtE,IAAI,cAAY,CAAC,WAAW,CAAC,IAAI,CAAC,IAAI,CAAC,KAAK,KAAK,IAAI,cAAY,CAAC,WAAW,CAAC,IAAI,CAAC,QAAQ,CAAC,KAAK,QAAQ,EAAE;YAC1G,OAAO,cAAY,CAAC,SAAS,CAAC;SAC9B;aACI,IAAI,cAAY,CAAC,WAAW,CAAC,IAAI,CAAC,IAAI,CAAC,KAAK,KAAK,IAAI,cAAY,CAAC,WAAW,CAAC,IAAI,CAAC,QAAQ,CAAC,KAAK,MAAM,EAAE;YAC7G,OAAO,cAAY,CAAC,UAAU,CAAC;SAC/B;QACD,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;SACrC,CAAC;IACH,CAAC;CACD;AAGD,IAAa,gBAAgB,wBAA7B,MAAa,gBAAiB,SAAQ,KAAK;IAC1C,MAAM,CAAC,QAAQ,CAAC,IAAsB,EAAE,YAAmC;QAC1E,OAAO,IAAI,kBAAgB,CAC1B,YAAY,CAAC,IAAI,CAAC,IAAI,CAAC,EACvB,YAAY,CAAC,IAAI,CAAC,EAAE,CAAC,EACrB,IAAI,CAAC,UAAU,IAAI,YAAY,CAAC,IAAI,CAAC,UAAU,CAAC,CAChD,CAAC;IACH,CAAC;IAED,eAAe,CAAC,KAAY,EAAE,SAAoB,EAAE,aAAmB;QACtE,KAAK,CAAC,eAAe,CAAC,SAAS,EAAE,IAAI,CAAC,EAAE,CAAC,OAAO,EAAE,EAAE,aAAa,CAAC,CAAC;IACpE,CAAC;CACD,CAAA;AAZY,gBAAgB;IAD5B,YAAY,CAAC,kBAAkB,CAAC;GACpB,gBAAgB,CAY5B;SAZY,gBAAgB;AAe7B,IAAa,eAAe,uBAA5B,MAAa,eAAgB,SAAQ,KAAK;IACzC,MAAM,CAAC,QAAQ,CAAC,IAAqB,EAAE,YAAmC;QACzE,OAAO,IAAI,iBAAe,CACzB,YAAY,CAAC,IAAI,CAAC,IAAI,CAAC,EACvB,IAAI,CAAC,EAAE,IAAI,YAAY,CAAC,IAAI,CAAC,EAAE,CAAC,EAChC,IAAI,CAAC,UAAU,IAAI,YAAY,CAAC,IAAI,CAAC,UAAU,CAAC,CAChD,CAAC;IACH,CAAC;CACD,CAAA;AARY,eAAe;IAD3B,YAAY,CAAC,iBAAiB,CAAC;GACnB,eAAe,CAQ3B;SARY,eAAe","sourcesContent":["import type {\n\tCanDeclareExpression, ExpressionEventPath,\n\tExpressionNode, NodeDeserializer\n} from '../expression.js';\nimport type { Stack } from '../../scope/stack.js';\nimport type { Scope, ScopeType } from '../../scope/scope.js';\nimport { AbstractExpressionNode } from '../abstract.js';\nimport { Deserializer } from '../deserialize/deserialize.js';\nimport { Identifier } from '../definition/values.js';\nimport { MemberExpression } from '../definition/member.js';\nimport { FunctionExpression } from '../definition/function.js';\n\n\n/**\n * MetaProperty node represents\n * - `new.target` meta property in ES2015.\n * - `import.meta` meta property in ES2030.\n * \n * In the future, it will represent other meta properties as well.\n */\n@Deserializer('MetaProperty')\nexport class MetaProperty extends MemberExpression {\n\n\tpublic static NewTarget = new MetaProperty(new Identifier('new'), new Identifier('target'));\n\n\tpublic static ImportMeta = new MetaProperty(new Identifier('import'), new Identifier('meta'));\n\n\tprivate static getJsonName(identifier: ExpressionNode): string {\n\t\treturn Reflect.get(identifier, 'name');\n\t}\n\n\tstatic fromJSON(node: MetaProperty, deserializer: NodeDeserializer<any>): MetaProperty {\n\t\tif (MetaProperty.getJsonName(node.meta) === 'new' && MetaProperty.getJsonName(node.property) === 'target') {\n\t\t\treturn MetaProperty.NewTarget;\n\t\t}\n\t\telse if (MetaProperty.getJsonName(node.meta) === 'new' && MetaProperty.getJsonName(node.property) === 'meta') {\n\t\t\treturn MetaProperty.ImportMeta;\n\t\t}\n\t\treturn new MetaProperty(\n\t\t\tdeserializer(node.meta),\n\t\t\tdeserializer(node.property)\n\t\t);\n\t}\n\tconstructor(private meta: Identifier, property: Identifier) {\n\t\tsuper(meta, property, false);\n\t}\n\tgetMeta() {\n\t\treturn this.meta;\n\t}\n\tshareVariables(scopeList: Scope<any>[]): void { }\n\ttoString(): string {\n\t\treturn `${this.meta.toString()}.${this.property.toString()}`;\n\t}\n\ttoJson(): { [key: string]: any; } {\n\t\treturn {\n\t\t\tmeta: this.meta.toJSON(),\n\t\t\tproperty: this.property.toJSON(),\n\t\t};\n\t}\n}\n\n/**\n * A private identifier refers to private class elements. For a private name #a, its name is a.\n */\n@Deserializer('PrivateIdentifier')\nexport class PrivateIdentifier extends Identifier {\n\tstatic fromJSON(node: PrivateIdentifier): PrivateIdentifier {\n\t\treturn new PrivateIdentifier(\n\t\t\tnode.name as string\n\t\t);\n\t}\n\tconstructor(private privateName: string) {\n\t\tsuper('ɵ_' + privateName);\n\t}\n\tshareVariables(scopeList: Scope<any>[]): void { }\n\ttoString(): string {\n\t\treturn `#${this.privateName}`;\n\t}\n\ttoJson(): { [key: string]: any; } {\n\t\treturn {\n\t\t\tname: this.privateName\n\t\t};\n\t}\n}\n\nexport type MethodDefinitionKind = 'constructor' | 'method' | 'set' | 'get';\n\n/**\n * - When key is a PrivateIdentifier, computed must be false and kind can not be \"constructor\".\n */\n@Deserializer('MethodDefinition')\nexport class MethodDefinition extends AbstractExpressionNode implements CanDeclareExpression {\n\tstatic fromJSON(node: MethodDefinition, deserializer: NodeDeserializer<any>): MethodDefinition {\n\t\treturn new MethodDefinition(\n\t\t\tnode.kind,\n\t\t\tdeserializer(node.key),\n\t\t\tdeserializer(node.value),\n\t\t\tnode.computed,\n\t\t\tnode.static\n\t\t);\n\t}\n\tprivate 'static': boolean;\n\tconstructor(\n\t\tprivate kind: MethodDefinitionKind,\n\t\tprivate key: ExpressionNode | PrivateIdentifier,\n\t\tprivate value: FunctionExpression,\n\n\t\tprivate computed: boolean,\n\t\tisStatic: boolean) {\n\t\tsuper();\n\t\tthis.static = isStatic;\n\t}\n\tgetKind() {\n\t\treturn this.kind;\n\t}\n\tgetKey() {\n\t\treturn this.key;\n\t}\n\tgetValue() {\n\t\treturn this.value;\n\t}\n\tisComputed() {\n\t\treturn this.computed;\n\t}\n\tisStatic() {\n\t\treturn this.static;\n\t}\n\tshareVariables(scopeList: Scope<any>[]): void { }\n\tset(stack: Stack, value: any) {\n\t\tthrow new Error('Method not implemented.');\n\t}\n\tget(stack: Stack, thisContext?: any) {\n\t\tthrow new Error('Method not implemented.');\n\t}\n\tdeclareVariable(stack: Stack, scopeType: ScopeType, propertyValue?: any) {\n\t\tthrow new Error('Method not implemented.');\n\t}\n\tdependency(computed?: true): ExpressionNode[] {\n\t\tthrow new Error('Method not implemented.');\n\t}\n\tdependencyPath(computed?: true): ExpressionEventPath[] {\n\t\tthrow new Error('Method not implemented.');\n\t}\n\ttoString(): string {\n\t\tthrow new Error('Method not implemented.');\n\t}\n\ttoJson(): { [key: string]: any; } {\n\t\treturn {\n\t\t\tkind: this.kind,\n\t\t\tkey: this.key,\n\t\t\tvalue: this.value,\n\t\t\tcomputed: this.computed,\n\t\t\tstatic: this.static,\n\t\t};\n\t}\n}\n\n\n\n/**\n * - When key is a PrivateIdentifier, computed must be false.\n */\n@Deserializer('PropertyDefinition')\nexport class PropertyDefinition extends AbstractExpressionNode implements CanDeclareExpression {\n\tstatic fromJSON(node: PropertyDefinition, deserializer: NodeDeserializer<any>): PropertyDefinition {\n\t\treturn new PropertyDefinition(\n\t\t\tdeserializer(node.key),\n\t\t\tnode.computed,\n\t\t\tnode.static,\n\t\t\tnode.value && deserializer(node.value)\n\t\t);\n\t}\n\tprivate 'static': boolean;\n\tconstructor(\n\t\tprivate key: ExpressionNode | PrivateIdentifier,\n\t\tprivate computed: boolean,\n\t\tisStatic: boolean,\n\t\tprivate value?: ExpressionNode) {\n\t\tsuper();\n\t\tthis.static = isStatic;\n\t}\n\tgetKey() {\n\t\treturn this.key;\n\t}\n\tgetValue() {\n\t\treturn this.value;\n\t}\n\tisComputed() {\n\t\treturn this.computed;\n\t}\n\tisStatic() {\n\t\treturn this.static;\n\t}\n\tshareVariables(scopeList: Scope<any>[]): void { }\n\tset(stack: Stack, value: any) {\n\t\tthrow new Error('Method not implemented.');\n\t}\n\tget(stack: Stack, thisContext?: any) {\n\t\tthrow new Error('Method not implemented.');\n\t}\n\tdeclareVariable(stack: Stack, scopeType: ScopeType, propertyValue?: any) {\n\t\tthrow new Error('Method not implemented.');\n\t}\n\tdependency(computed?: true): ExpressionNode[] {\n\t\tthrow new Error('Method not implemented.');\n\t}\n\tdependencyPath(computed?: true): ExpressionEventPath[] {\n\t\tthrow new Error('Method not implemented.');\n\t}\n\ttoString(): string {\n\t\tthrow new Error('Method not implemented.');\n\t}\n\ttoJson(): { [key: string]: any; } {\n\t\treturn {\n\t\t\tkey: this.key.toJSON(),\n\t\t\tcomputed: this.computed,\n\t\t\tstatic: this.static,\n\t\t\tvalue: this.value?.toJSON()\n\t\t};\n\t}\n}\n\n@Deserializer('ClassBody')\nexport class ClassBody extends AbstractExpressionNode {\n\tstatic fromJSON(node: ClassBody, deserializer: NodeDeserializer<any>): ClassBody {\n\t\treturn new ClassBody(\n\t\t\tnode.body.map(deserializer)\n\t\t);\n\t}\n\tconstructor(private body: (MethodDefinition | PropertyDefinition)[]) {\n\t\tsuper();\n\t}\n\tgetBody() {\n\t\treturn this.body;\n\t}\n\tshareVariables(scopeList: Scope<any>[]): void { }\n\tset(stack: Stack, value: any) {\n\t\tthrow new Error('Method not implemented.');\n\t}\n\tget(stack: Stack, thisContext?: any) {\n\t\tthrow new Error('Method not implemented.');\n\t}\n\tdependency(computed?: true): ExpressionNode[] {\n\t\tthrow new Error('Method not implemented.');\n\t}\n\tdependencyPath(computed?: true): ExpressionEventPath[] {\n\t\tthrow new Error('Method not implemented.');\n\t}\n\ttoString(): string {\n\t\tthrow new Error('Method not implemented.');\n\t}\n\ttoJson(): { [key: string]: any; } {\n\t\treturn {\n\t\t\tbody: this.body.map(method => method.toJSON())\n\t\t};\n\t}\n}\n\nexport class Class extends AbstractExpressionNode {\n\tconstructor(\n\t\tprotected body: ClassBody,\n\t\tprotected id?: Identifier,\n\t\tprotected superClass?: ExpressionNode) {\n\t\tsuper();\n\t}\n\tgetBody() {\n\t\treturn this.body;\n\t}\n\tgetId() {\n\t\treturn this.id;\n\t}\n\tgetSuperClass() {\n\t\treturn this.superClass;\n\t}\n\tshareVariables(scopeList: Scope<any>[]): void { }\n\tset(stack: Stack) {\n\t\tthrow new Error(`Class.#set() has no implementation.`);\n\t}\n\tget(stack: Stack) {\n\t\tthrow new Error(`Class.#get() has no implementation.`);\n\t}\n\tdependency(computed?: true): ExpressionNode[] {\n\t\tthrow new Error('Method not implemented.');\n\t}\n\tdependencyPath(computed?: true): ExpressionEventPath[] {\n\t\tthrow new Error('Method not implemented.');\n\t}\n\ttoString() {\n\t\tlet classDeclaration = 'class ';\n\t\tif (this.id) {\n\t\t\tclassDeclaration += this.id.toString();\n\t\t}\n\t\tif (this.superClass) {\n\t\t\tclassDeclaration += ' extends ' + this.superClass.toString();\n\t\t}\n\t\treturn `${classDeclaration} {${this.body.toString()}\\n`;\n\t}\n\ttoJson(): object {\n\t\treturn {\n\t\t\tbody: this.body.toJSON(),\n\t\t\tid: this.id?.toJSON(),\n\t\t\tsuperClass: this.superClass?.toJSON(),\n\t\t};\n\t}\n}\n\n@Deserializer('ClassDeclaration')\nexport class ClassDeclaration extends Class implements CanDeclareExpression {\n\tstatic fromJSON(node: ClassDeclaration, deserializer: NodeDeserializer<any>): ClassDeclaration {\n\t\treturn new ClassDeclaration(\n\t\t\tdeserializer(node.body),\n\t\t\tdeserializer(node.id),\n\t\t\tnode.superClass && deserializer(node.superClass)\n\t\t);\n\t}\n\tprotected id: Identifier;\n\tdeclareVariable(stack: Stack, scopeType: ScopeType, propertyValue?: any) {\n\t\tstack.declareVariable(scopeType, this.id.getName(), propertyValue);\n\t}\n}\n\n@Deserializer('ClassExpression')\nexport class ClassExpression extends Class {\n\tstatic fromJSON(node: ClassExpression, deserializer: NodeDeserializer<any>): ClassExpression {\n\t\treturn new ClassExpression(\n\t\t\tdeserializer(node.body),\n\t\t\tnode.id && deserializer(node.id),\n\t\t\tnode.superClass && deserializer(node.superClass)\n\t\t);\n\t}\n}\n"]}
@@ -1,39 +0,0 @@
1
- var Program_1;
2
- import { __decorate, __metadata } from "tslib";
3
- import { AbstractExpressionNode } from '../abstract.js';
4
- import { Deserializer } from '../deserialize/deserialize.js';
5
- let Program = Program_1 = class Program extends AbstractExpressionNode {
6
- constructor(sourceType, body) {
7
- super();
8
- this.sourceType = sourceType;
9
- this.body = body;
10
- }
11
- static fromJSON(node, deserializer) {
12
- return new Program_1(node.sourceType, node.body.map(deserializer));
13
- }
14
- shareVariables(scopeList) { }
15
- set(stack, value) {
16
- throw new Error(`${this.constructor.name}#set() has no implementation.`);
17
- }
18
- get(stack, thisContext) {
19
- throw new Error(`${this.constructor.name}#set() has no implementation.`);
20
- }
21
- dependency(computed) {
22
- throw new Error('Method not implemented.');
23
- }
24
- dependencyPath(computed) {
25
- throw new Error('Method not implemented.');
26
- }
27
- toString() {
28
- throw new Error(`${this.constructor.name}#set() has no implementation.`);
29
- }
30
- toJson() {
31
- throw new Error(`${this.constructor.name}#set() has no implementation.`);
32
- }
33
- };
34
- Program = Program_1 = __decorate([
35
- Deserializer('Program'),
36
- __metadata("design:paramtypes", [String, Array])
37
- ], Program);
38
- export { Program };
39
- //# sourceMappingURL=program.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"program.js","sourceRoot":"","sources":["../../../../src/expressions/api/app/program.ts"],"names":[],"mappings":";;AAGA,OAAO,EAAE,sBAAsB,EAAE,MAAM,gBAAgB,CAAC;AACxD,OAAO,EAAE,YAAY,EAAE,MAAM,+BAA+B,CAAC;AAK7D,IAAa,OAAO,eAApB,MAAa,OAAQ,SAAQ,sBAAsB;IAKlD,YAAoB,UAA6B,EAAU,IAAsB;QAChF,KAAK,EAAE,CAAC;QADW,eAAU,GAAV,UAAU,CAAmB;QAAU,SAAI,GAAJ,IAAI,CAAkB;IAEjF,CAAC;IALD,MAAM,CAAC,QAAQ,CAAC,IAAa,EAAE,YAA8B;QAC5D,OAAO,IAAI,SAAO,CAAC,IAAI,CAAC,UAAU,EAAE,IAAI,CAAC,IAAI,CAAC,GAAG,CAAC,YAAY,CAAC,CAAC,CAAC;IAClE,CAAC;IAID,cAAc,CAAC,SAAuB,IAAU,CAAC;IACjD,GAAG,CAAC,KAAY,EAAE,KAAU;QAC3B,MAAM,IAAI,KAAK,CAAC,GAAG,IAAI,CAAC,WAAW,CAAC,IAAI,+BAA+B,CAAC,CAAC;IAC1E,CAAC;IACD,GAAG,CAAC,KAAY,EAAE,WAAiB;QAClC,MAAM,IAAI,KAAK,CAAC,GAAG,IAAI,CAAC,WAAW,CAAC,IAAI,+BAA+B,CAAC,CAAC;IAC1E,CAAC;IAED,UAAU,CAAC,QAAe;QACzB,MAAM,IAAI,KAAK,CAAC,yBAAyB,CAAC,CAAC;IAC5C,CAAC;IACD,cAAc,CAAC,QAAe;QAC7B,MAAM,IAAI,KAAK,CAAC,yBAAyB,CAAC,CAAC;IAC5C,CAAC;IACD,QAAQ;QACP,MAAM,IAAI,KAAK,CAAC,GAAG,IAAI,CAAC,WAAW,CAAC,IAAI,+BAA+B,CAAC,CAAC;IAC1E,CAAC;IACD,MAAM;QACL,MAAM,IAAI,KAAK,CAAC,GAAG,IAAI,CAAC,WAAW,CAAC,IAAI,+BAA+B,CAAC,CAAC;IAC1E,CAAC;CAED,CAAA;AA7BY,OAAO;IADnB,YAAY,CAAC,SAAS,CAAC;;GACX,OAAO,CA6BnB;SA7BY,OAAO","sourcesContent":["import type { ExpressionEventPath, ExpressionNode, NodeDeserializer } from '../expression.js';\nimport type { Scope } from '../../scope/scope.js';\nimport type { Stack } from '../../scope/stack.js';\nimport { AbstractExpressionNode } from '../abstract.js';\nimport { Deserializer } from '../deserialize/deserialize.js';\n\nexport type ProgramSourceType = 'script' | 'module';\n\n@Deserializer('Program')\nexport class Program extends AbstractExpressionNode {\n\n\tstatic fromJSON(node: Program, deserializer: NodeDeserializer): Program {\n\t\treturn new Program(node.sourceType, node.body.map(deserializer));\n\t}\n\tconstructor(private sourceType: ProgramSourceType, private body: ExpressionNode[]) {\n\t\tsuper();\n\t}\n\tshareVariables(scopeList: Scope<any>[]): void { }\n\tset(stack: Stack, value: any): any {\n\t\tthrow new Error(`${this.constructor.name}#set() has no implementation.`);\n\t}\n\tget(stack: Stack, thisContext?: any): any {\n\t\tthrow new Error(`${this.constructor.name}#set() has no implementation.`);\n\t}\n\n\tdependency(computed?: true): ExpressionNode[] {\n\t\tthrow new Error('Method not implemented.');\n\t}\n\tdependencyPath(computed?: true): ExpressionEventPath[] {\n\t\tthrow new Error('Method not implemented.');\n\t}\n\ttoString(): string {\n\t\tthrow new Error(`${this.constructor.name}#set() has no implementation.`);\n\t}\n\ttoJson(): { [key: string]: any } {\n\t\tthrow new Error(`${this.constructor.name}#set() has no implementation.`);\n\t}\n\n}"]}
@@ -1,26 +0,0 @@
1
- import type { ExpressionEventPath, ExpressionNode, NodeDeserializer, VisitNodeListType, VisitNodeType } from '../expression.js';
2
- import type { Scope } from '../../scope/scope.js';
3
- import type { Stack } from '../../scope/stack.js';
4
- import { AbstractExpressionNode } from '../abstract.js';
5
- export declare class ModuleNode extends AbstractExpressionNode {
6
- private exportList;
7
- private importList;
8
- private body;
9
- private meta;
10
- static fromJSON(node: ModuleNode, deserializer: NodeDeserializer): ModuleNode;
11
- static visit(node: ModuleNode, visitNode: VisitNodeType, visitNodeList: VisitNodeListType): void;
12
- constructor(exportList: ExpressionNode[], importList: ExpressionNode[], body: ExpressionNode[], meta: {
13
- name: string;
14
- url: string;
15
- });
16
- getExportList(): ExpressionNode[];
17
- getImportList(): ExpressionNode[];
18
- getBody(): ExpressionNode[];
19
- shareVariables(scopeList: Scope<any>[]): void;
20
- set(stack: Stack): void;
21
- get(stack: Stack): void;
22
- dependency(computed?: true): ExpressionNode[];
23
- dependencyPath(computed?: true): ExpressionEventPath[];
24
- toString(): string;
25
- toJson(): object;
26
- }
@@ -1,63 +0,0 @@
1
- var ModuleNode_1;
2
- import { __decorate, __metadata } from "tslib";
3
- import { AbstractExpressionNode } from '../abstract.js';
4
- import { Deserializer } from '../deserialize/deserialize.js';
5
- let ModuleNode = ModuleNode_1 = class ModuleNode extends AbstractExpressionNode {
6
- constructor(exportList, importList, body, meta) {
7
- super();
8
- this.exportList = exportList;
9
- this.importList = importList;
10
- this.body = body;
11
- this.meta = meta;
12
- }
13
- static fromJSON(node, deserializer) {
14
- return new ModuleNode_1(node.exportList.map(deserializer), node.importList.map(deserializer), node.body.map(deserializer), node.meta);
15
- }
16
- static visit(node, visitNode, visitNodeList) {
17
- visitNodeList(node.exportList);
18
- visitNodeList(node.importList);
19
- visitNodeList(node.body);
20
- }
21
- getExportList() {
22
- return this.exportList;
23
- }
24
- getImportList() {
25
- return this.importList;
26
- }
27
- getBody() {
28
- return this.body;
29
- }
30
- shareVariables(scopeList) { }
31
- set(stack) {
32
- throw new Error(`ModuleNode.#set() has no implementation.`);
33
- }
34
- get(stack) {
35
- throw new Error(`ModuleNode.#get() has no implementation.`);
36
- }
37
- dependency(computed) {
38
- return this.body.flatMap(exp => exp.dependency(computed));
39
- }
40
- dependencyPath(computed) {
41
- return this.body.flatMap(exp => exp.dependencyPath(computed));
42
- }
43
- toString() {
44
- const importString = this.importList.map(imp => imp.toString()).join('\n');
45
- const exportString = this.exportList.map(expo => expo.toString()).join('\n');
46
- const bodyString = this.body.map(exp => exp.toString()).join('\n');
47
- return `${importString}\n${exportString}\n${bodyString}\n`;
48
- }
49
- toJson() {
50
- return {
51
- exportList: this.exportList.map(expression => expression.toJSON()),
52
- importList: this.importList.map(expression => expression.toJSON()),
53
- body: this.body.map(expression => expression.toJSON()),
54
- meta: JSON.parse(JSON.stringify(this.meta)),
55
- };
56
- }
57
- };
58
- ModuleNode = ModuleNode_1 = __decorate([
59
- Deserializer('module'),
60
- __metadata("design:paramtypes", [Array, Array, Array, Object])
61
- ], ModuleNode);
62
- export { ModuleNode };
63
- //# sourceMappingURL=module.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"module.js","sourceRoot":"","sources":["../../../../src/expressions/api/module/module.ts"],"names":[],"mappings":";;AAMA,OAAO,EAAE,sBAAsB,EAAE,MAAM,gBAAgB,CAAC;AACxD,OAAO,EAAE,YAAY,EAAE,MAAM,+BAA+B,CAAC;AAG7D,IAAa,UAAU,kBAAvB,MAAa,UAAW,SAAQ,sBAAsB;IAcrD,YACS,UAA4B,EAC5B,UAA4B,EAC5B,IAAsB,EACtB,IAAoC;QAC5C,KAAK,EAAE,CAAC;QAJA,eAAU,GAAV,UAAU,CAAkB;QAC5B,eAAU,GAAV,UAAU,CAAkB;QAC5B,SAAI,GAAJ,IAAI,CAAkB;Q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AAC,CAAC;IAC/D,CAAC;IACD,QAAQ;QACP,MAAM,YAAY,GAAG,IAAI,CAAC,UAAU,CAAC,GAAG,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,CAAC,QAAQ,EAAE,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;QAC3E,MAAM,YAAY,GAAG,IAAI,CAAC,UAAU,CAAC,GAAG,CAAC,IAAI,CAAC,EAAE,CAAC,IAAI,CAAC,QAAQ,EAAE,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;QAC7E,MAAM,UAAU,GAAG,IAAI,CAAC,IAAI,CAAC,GAAG,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,CAAC,QAAQ,EAAE,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;QACnE,OAAO,GAAG,YAAY,KAAK,YAAY,KAAK,UAAU,IAAI,CAAC;IAC5D,CAAC;IACD,MAAM;QACL,OAAO;YACN,UAAU,EAAE,IAAI,CAAC,UAAU,CAAC,GAAG,CAAC,UAAU,CAAC,EAAE,CAAC,UAAU,CAAC,MAAM,EAAE,CAAC;YAClE,UAAU,EAAE,IAAI,CAAC,UAAU,CAAC,GAAG,CAAC,UAAU,CAAC,EAAE,CAAC,UAAU,CAAC,MAAM,EAAE,CAAC;YAClE,IAAI,EAAE,IAAI,CAAC,IAAI,CAAC,GAAG,CAAC,UAAU,CAAC,EAAE,CAAC,UAAU,CAAC,MAAM,EAAE,CAAC;YACtD,IAAI,EAAE,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,SAAS,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;SAC3C,CAAC;IACH,CAAC;CACD,CAAA;AAzDY,UAAU;IADtB,YAAY,CAAC,QAAQ,CAAC;;GACV,UAAU,CAyDtB;SAzDY,UAAU","sourcesContent":["import type {\n\tExpressionEventPath, ExpressionNode, NodeDeserializer,\n\tVisitNodeListType, VisitNodeType\n} from '../expression.js';\nimport type { Scope } from '../../scope/scope.js';\nimport type { Stack } from '../../scope/stack.js';\nimport { AbstractExpressionNode } from '../abstract.js';\nimport { Deserializer } from '../deserialize/deserialize.js';\n\n@Deserializer('module')\nexport class ModuleNode extends AbstractExpressionNode {\n\tstatic fromJSON(node: ModuleNode, deserializer: NodeDeserializer): ModuleNode {\n\t\treturn new ModuleNode(\n\t\t\tnode.exportList.map(deserializer),\n\t\t\tnode.importList.map(deserializer),\n\t\t\tnode.body.map(deserializer),\n\t\t\tnode.meta\n\t\t);\n\t}\n\tstatic visit(node: ModuleNode, visitNode: VisitNodeType, visitNodeList: VisitNodeListType): void {\n\t\tvisitNodeList(node.exportList);\n\t\tvisitNodeList(node.importList);\n\t\tvisitNodeList(node.body);\n\t}\n\tconstructor(\n\t\tprivate exportList: ExpressionNode[],\n\t\tprivate importList: ExpressionNode[],\n\t\tprivate body: ExpressionNode[],\n\t\tprivate meta: { name: string, url: string, }) {\n\t\tsuper();\n\t}\n\tgetExportList() {\n\t\treturn this.exportList;\n\t}\n\tgetImportList() {\n\t\treturn this.importList;\n\t}\n\tgetBody() {\n\t\treturn this.body;\n\t}\n\tshareVariables(scopeList: Scope<any>[]): void { }\n\tset(stack: Stack) {\n\t\tthrow new Error(`ModuleNode.#set() has no implementation.`);\n\t}\n\tget(stack: Stack) {\n\t\tthrow new Error(`ModuleNode.#get() has no implementation.`);\n\t}\n\tdependency(computed?: true): ExpressionNode[] {\n\t\treturn this.body.flatMap(exp => exp.dependency(computed));\n\t}\n\tdependencyPath(computed?: true): ExpressionEventPath[] {\n\t\treturn this.body.flatMap(exp => exp.dependencyPath(computed));\n\t}\n\ttoString(): string {\n\t\tconst importString = this.importList.map(imp => imp.toString()).join('\\n');\n\t\tconst exportString = this.exportList.map(expo => expo.toString()).join('\\n');\n\t\tconst bodyString = this.body.map(exp => exp.toString()).join('\\n');\n\t\treturn `${importString}\\n${exportString}\\n${bodyString}\\n`;\n\t}\n\ttoJson(): object {\n\t\treturn {\n\t\t\texportList: this.exportList.map(expression => expression.toJSON()),\n\t\t\timportList: this.importList.map(expression => expression.toJSON()),\n\t\t\tbody: this.body.map(expression => expression.toJSON()),\n\t\t\tmeta: JSON.parse(JSON.stringify(this.meta)),\n\t\t};\n\t}\n}\n"]}
package/v8/app.d.ts DELETED
File without changes
package/v8/app.js DELETED
@@ -1,2 +0,0 @@
1
- "use strict";
2
- //# sourceMappingURL=app.js.map
package/v8/app.js.map DELETED
@@ -1 +0,0 @@
1
- {"version":3,"file":"app.js","sourceRoot":"","sources":["../../../src/expressions/v8/app.ts"],"names":[],"mappings":"","sourcesContent":["// import type { ExpressionNode } from '../api/expression.js';\n// import {\n// \tAssignmentNode, ConstNode, FunctionType,\n// \tLetNode, NullNode, StringNode, Variable\n// } from '../api/index.js';\n// import { JavaScriptParser, PropertyKind } from './parser.js';\n// import { Token } from './token.js';\n// import { MetaProperty } from '../api/app/class.js';\n\n\n// export type ClassInfo = {\n// \tisAnonymous: boolean;\n// \textends: ExpressionNode;\n// \thasSeenConstructor: boolean;\n// \thasStaticComputedNames: boolean;\n// \trequiresBrand: boolean;\n// \thasPrivateMethods: boolean,\n// \thasStaticPrivateMethods: boolean;\n// \tcomputedFieldCount: number;\n// \thasStaticElements: boolean;\n// };\n\n// export enum FunctionNameValidity {\n// \tFunctionNameIsStrictReserved = 'FunctionNameIsStrictReserved',\n// \tSkipFunctionNameCheck = 'SkipFunctionNameCheck',\n// \tFunctionNameValidityUnknown = 'FunctionNameValidityUnknown'\n// };\n\n// export enum AllowLabelledFunctionStatement {\n// \tAllowLabelledFunctionStatement = 'AllowLabelledFunctionStatement',\n// \tDisallowLabelledFunctionStatement = 'DisallowLabelledFunctionStatement',\n// };\n\n// export enum ParsingArrowHeadFlag {\n// \tCertainlyNotArrowHead = 'CertainlyNotArrowHead',\n// \tMaybeArrowHead = 'MaybeArrowHead'\n// };\n\n// export enum PropertyPosition {\n// \tObjectLiteral = 'ObjectLiteral',\n// \tClassLiteral = 'ClassLiteral'\n// }\n\n// const FUNCTIONS_TYPES: FunctionType[][][] = [\n// \t[\n// \t\t// SubFunctionKind::kNormalFunction\n// \t\t[// is_generator=false\n// \t\t\tFunctionType.NORMAL,\n// \t\t\tFunctionType.ASYNC\n// \t\t],\n// \t\t[// is_generator=true\n// \t\t\tFunctionType.GENERATOR,\n// \t\t\tFunctionType.ASYNC_GENERATOR\n// \t\t],\n// \t],\n// \t[\n// \t\t// SubFunctionKind::kNonStaticMethod\n// \t\t[// is_generator=false\n// \t\t\tFunctionType.CONCISE,\n// \t\t\tFunctionType.ASYNC_CONCISE\n// \t\t],\n// \t\t[// is_generator=true\n// \t\t\tFunctionType.CONCISE_GENERATOR,\n// \t\t\tFunctionType.ASYNC_CONCISE_GENERATOR\n// \t\t],\n// \t],\n// \t[\n// \t\t// SubFunctionKind::kStaticMethod\n// \t\t[// is_generator=false\n// \t\t\tFunctionType.STATIC_CONCISE,\n// \t\t\tFunctionType.STATIC_ASYNC_CONCISE\n// \t\t],\n// \t\t[// is_generator=true\n// \t\t\tFunctionType.STATIC_CONCISE_GENERATOR,\n// \t\t\tFunctionType.STATIC_ASYNC_CONCISE_GENERATOR\n// \t\t],\n// \t]\n// ];\n\n// export enum SubFunctionKind {\n// \tNormalFunction,\n// \tNonStaticMethod,\n// \tStaticMethod,\n// }\n\n// export function functionKindForImpl(subFunctionKind: SubFunctionKind, isGenerator: boolean, isAsync: boolean): FunctionType {\n// \treturn FUNCTIONS_TYPES[subFunctionKind as number][isGenerator ? 1 : 0][isAsync ? 1 : 0];\n// }\n\n// export class ParsePropertyInfo {\n// \tname: ExpressionNode;\n// \tposition = PropertyPosition.ClassLiteral;\n// \tfunctionFlags = FunctionType.NORMAL;\n// \tkind = PropertyKind.NotSet;\n// \tisComputedName = false;\n// \tisPrivate = false;\n// \tisStatic = false;\n// \tisRest = false;\n\n// \tPropertyKindFromToken(token: Token): boolean {\n// \t\t// This returns true, setting the property kind, iff the given token is\n// \t\t// one which must occur after a property name, indicating that the\n// \t\t// previous token was in fact a name and not a modifier (like the \"get\" in\n// \t\t// \"get x\").\n// \t\tswitch (token) {\n// \t\t\tcase Token.COLON:\n// \t\t\t\tthis.kind = PropertyKind.Value;\n// \t\t\t\treturn true;\n// \t\t\tcase Token.COMMA:\n// \t\t\t\tthis.kind = PropertyKind.Shorthand;\n// \t\t\t\treturn true;\n// \t\t\tcase Token.R_CURLY:\n// \t\t\t\tthis.kind = PropertyKind.ShorthandOrClassField;\n// \t\t\t\treturn true;\n// \t\t\tcase Token.ASSIGN:\n// \t\t\t\tthis.kind = PropertyKind.Assign;\n// \t\t\t\treturn true;\n// \t\t\tcase Token.L_PARENTHESES:\n// \t\t\t\tthis.kind = PropertyKind.Method;\n// \t\t\t\treturn true;\n// \t\t\tcase Token.MUL:\n// \t\t\tcase Token.SEMICOLON:\n// \t\t\t\tthis.kind = PropertyKind.ClassField;\n// \t\t\t\treturn true;\n// \t\t\tdefault:\n// \t\t\t\tbreak;\n// \t\t}\n// \t\treturn false;\n// \t}\n\n// }\n// enum ObjectLiteralPropertyKind {\n// \tCONSTANT = 'CONSTANT',\t// Property with constant value (compile time).\n// \tCOMPUTED = 'COMPUTED',\t// Property with computed value (execution time).\n// \tMATERIALIZED_LITERAL = 'MATERIALIZED_LITERAL', // Property value is a materialized literal.\n// \tGETTER = 'GETTER',\n// \tSETTER = 'SETTER',\t\t// Property is an accessor function.\n// \tPROTOTYPE = 'PROTOTYPE',\t// Property is __proto__.\n// \tSPREAD = 'SPREAD'\n// }\n// export class ObjectLiteralProperty {\n// \tstatic Kind = ObjectLiteralPropertyKind;\n// }\n\n// enum ClassLiteralPropertyKind {\n// \tMETHOD = 'METHOD',\n// \tGETTER = 'GETTER',\n// \tSETTER = 'SETTER',\n// \tFIELD = 'FIELD'\n// }\n\n// export class ClassLiteralProperty {\n// \tstatic Kind = ClassLiteralPropertyKind;\n// }\n\n// function assertUnreachable(x: never): never {\n// \tthrow new Error(`Didn't expect to get here`);\n// }\n// export function classPropertyKindFor(kind: PropertyKind): ClassLiteralPropertyKind {\n// \tswitch (kind) {\n// \t\tcase PropertyKind.AccessorGetter:\n// \t\t\treturn ClassLiteralPropertyKind.GETTER;\n// \t\tcase PropertyKind.AccessorSetter:\n// \t\t\treturn ClassLiteralPropertyKind.SETTER;\n// \t\tcase PropertyKind.Method:\n// \t\t\treturn ClassLiteralPropertyKind.METHOD;\n// \t\tcase PropertyKind.ClassField:\n// \t\t\treturn ClassLiteralPropertyKind.FIELD;\n// \t}\n// \tthrow new Error(`unexpected property kind: ${kind}`);\n// }\n\n// export enum VariableMode {\n// \tConst = 'Const',\n// \tPrivateMethod = 'PrivateMethod',\n// \tPrivateGetterOnly = 'PrivateGetterOnly',\n// \tPrivateSetterOnly = 'PrivateSetterOnly'\n// }\n\n// export function getVariableMode(kind: ClassLiteralPropertyKind): VariableMode {\n// \tswitch (kind) {\n// \t\tcase ClassLiteralPropertyKind.FIELD:\n// \t\t\treturn VariableMode.Const;\n// \t\tcase ClassLiteralPropertyKind.METHOD:\n// \t\t\treturn VariableMode.PrivateMethod;\n// \t\tcase ClassLiteralPropertyKind.GETTER:\n// \t\t\treturn VariableMode.PrivateGetterOnly;\n// \t\tcase ClassLiteralPropertyKind.SETTER:\n// \t\t\treturn VariableMode.PrivateSetterOnly;\n// \t}\n// }\n\n// export class JavaScriptAppParser extends JavaScriptParser {\n// \tprotected parseNewTargetExpression(): ExpressionNode {\n// \t\tthis.consume(Token.PERIOD);\n//\t\t const target: ExpressionNode = this.parsePropertyName();\n//\t\t if (target.toString() !== 'target') {\n//\t\t \tthrow new Error(this.errorMessage(`Expression (new.${target.toString()}) not supported.`));\n//\t\t }\n//\t\t return MetaProperty.NewTarget;\n// \t}\n// \tprotected parseClassDeclaration(names: ExpressionNode[] | undefined, defaultExport: boolean): ExpressionNode {\n// \t\t// ClassDeclaration ::\n// \t\t// 'class' Identifier ('extends' LeftHandExpression)? '{' ClassBody '}'\n// \t\t// 'class' ('extends' LeftHandExpression)? '{' ClassBody '}'\n// \t\t//\n// \t\t// The anonymous form is allowed iff [default_export] is true.\n// \t\t//\n// \t\t// 'class' is expected to be consumed by the caller.\n// \t\t//\n// \t\t// A ClassDeclaration\n// \t\t//\n// \t\t// class C { ... }\n// \t\t//\n// \t\t// has the same semantics as:\n// \t\t//\n// \t\t// let C = class C { ... };\n// \t\t//\n// \t\t// so rewrite it as such.\n\n// \t\tconst nextToken = this.peek().token;\n// \t\tconst isStrictReserved = Token.isStrictReservedWord(nextToken);\n// \t\tlet name: ExpressionNode | undefined;\n// \t\tlet variableName: ExpressionNode | undefined;\n// \t\tif (defaultExport && (nextToken == Token.EXTENDS || nextToken == Token.L_CURLY)) {\n// \t\t\tname = new StringNode('default');\n// \t\t\tvariableName = new StringNode('.default');\n// \t\t} else {\n// \t\t\tname = this.parseIdentifier();\n// \t\t\tvariableName = name;\n// \t\t}\n// \t\tconst value = this.parseClassLiteral(name, isStrictReserved);\n// \t\treturn this.declareClass(variableName, value, names);\n// \t}\n// \tprotected parseClassLiteral(name: ExpressionNode | undefined, nameIsStrictReserved: boolean): ExpressionNode {\n// \t\t// throw new Error(this.errorMessage(`Expression (class) not supported.`));\n// \t\tconst isAnonymous = !!!name;\n\n// \t\t// All parts of a ClassDeclaration and ClassExpression are strict code.\n// \t\tif (!isAnonymous) {\n// \t\t\tif (nameIsStrictReserved) {\n// \t\t\t\tthrow new Error(this.errorMessage(`Unexpected Strict Reserved class name`));\n// \t\t\t}\n// \t\t\tif (this.isEvalOrArguments(name!)) {\n// \t\t\t\tthrow new Error(this.errorMessage(`Strict Eval Arguments not allowed for class name`));\n// \t\t\t}\n// \t\t}\n\n// \t\t// ClassScope * class_scope = NewClassScope(scope(), is_anonymous);\n// \t\t// BlockState block_state(& scope_, class_scope);\n// \t\t// RaiseLanguageMode(LanguageMode.kStrict);\n\n// \t\t// BlockState object_literal_scope_state(& object_literal_scope_, nullptr);\n\n// \t\t// ClassInfo classInfo(this);\n// \t\t// classInfo.is_anonymous = is_anonymous;\n\n// \t\tconst classInfo = { isAnonymous, computedFieldCount: 0 } as ClassInfo;\n\n// \t\t// scope() -> set_start_position(class_token_pos);\n// \t\tif (this.check(Token.EXTENDS)) {\n// \t\t\t// ClassScope.HeritageParsingScope heritage(class_scope);\n// \t\t\t// FuncNameInferrerState fni_state(& fni_);\n// \t\t\t// ExpressionParsingScope scope(impl());\n// \t\t\tclassInfo.extends = this.parseLeftHandSideExpression();\n// \t\t\t// scope.ValidateExpression();\n// \t\t}\n\n// \t\tthis.expect(Token.L_CURLY);\n\n// \t\tconst hasExtends = !(classInfo.extends === undefined);\n\n// \t\tconst staticBlockList: ExpressionNode[] = [];\n// \t\tconst privateClassMemberList: ExpressionNode[] = [];\n// \t\tconst publicClassFieldList: ExpressionNode[] = [];\n// \t\tconst publicClassMethodList: ExpressionNode[] = [];\n\n// \t\twhile (this.peek().isNotType(Token.R_CURLY)) {\n// \t\t\tif (this.check(Token.SEMICOLON)) continue;\n\n// \t\t\t// Either we're parsing a `static { }` initialization block or a property.\n// \t\t\tif (this.peek().isType(Token.STATIC) && this.peekAhead().isType(Token.L_CURLY)) {\n// \t\t\t\tconst staticBlock = this.parseClassStaticBlock(classInfo);\n// \t\t\t\tstaticBlockList.push(staticBlock);\n// \t\t\t\tcontinue;\n// \t\t\t}\n\n// \t\t\t// FuncNameInferrerState fni_state(& fni_);\n// \t\t\t// If we haven't seen the constructor yet, it potentially is the next\n// \t\t\t// property.\n// \t\t\tlet isConstructor = !classInfo.hasSeenConstructor;\n// \t\t\tconst propInfo = new ParsePropertyInfo();\n// \t\t\tpropInfo.position = PropertyPosition.ClassLiteral;\n\n// \t\t\tconst property = this.parseClassPropertyDefinition(classInfo, propInfo, hasExtends);\n\n// \t\t\t// if (has_error()) return impl() -> FailureExpression();\n\n// \t\t\tconst propertyKind = classPropertyKindFor(propInfo.kind);\n// \t\t\tif (!classInfo.hasStaticComputedNames && propInfo.isStatic && propInfo.isComputedName) {\n// \t\t\t\tclassInfo.hasStaticComputedNames = true;\n// \t\t\t}\n// \t\t\tisConstructor &&= classInfo.hasSeenConstructor;\n\n// \t\t\tconst isField = propertyKind == ClassLiteralPropertyKind.FIELD;\n\n// \t\t\tif (propInfo.isPrivate) {\n// \t\t\t\tif (isConstructor) {\n// \t\t\t\t\tthrow new Error(this.errorMessage('private constructor is not allowed'));\n// \t\t\t\t}\n// \t\t\t\tclassInfo.requiresBrand ||= (!isField && !propInfo.isStatic);\n// \t\t\t\tconst isMethod = propertyKind == ClassLiteralPropertyKind.METHOD;\n// \t\t\t\tclassInfo.hasPrivateMethods ||= isMethod;\n// \t\t\t\tclassInfo.hasStaticPrivateMethods ||= isMethod && propInfo.isStatic;\n// \t\t\t\tconst privateClassMember = this.declarePrivateClassMember(propInfo.name, property, propertyKind, propInfo.isStatic, classInfo);\n// \t\t\t\tprivateClassMemberList.push(privateClassMember);\n// \t\t\t\tcontinue;\n// \t\t\t}\n\n// \t\t\tif (isField) {\n// \t\t\t\tif (propInfo.isComputedName) {\n// \t\t\t\t\tclassInfo.computedFieldCount++;\n// \t\t\t\t}\n// \t\t\t\tconst publicClassField = this.declarePublicClassField(property, propInfo.isStatic, propInfo.isComputedName, classInfo);\n// \t\t\t\tpublicClassFieldList.push(publicClassField);\n// \t\t\t\tcontinue;\n// \t\t\t}\n\n// \t\t\tconst publicClassMethod = this.declarePublicClassMethod(name, property, isConstructor, classInfo);\n// \t\t\tpublicClassMethodList.push(publicClassMethod);\n// \t\t}\n\n// \t\tthis.expect(Token.R_CURLY);\n// \t\t// int end_pos = end_position();\n// \t\t// class_scope -> set_end_position(end_pos);\n\n// \t\t// VariableProxy * unresolvable = class_scope -> ResolvePrivateNamesPartially();\n// \t\t// if (unresolvable != nullptr) {\n// \t\t// \timpl() -> ReportMessageAt(Scanner.Location(unresolvable -> position(),unresolvable -> position() + 1),\n// \t\t// \t\tMessageTemplate.kInvalidPrivateFieldResolution,\n// \t\t// \t\tunresolvable -> raw_name());\n// \t\t// \treturn impl() -> FailureExpression();\n// \t\t// }\n\n// \t\t// if (classInfo.requiresBrand) {\n// \t\t// \tclass_scope -> DeclareBrandVariable(ast_value_factory(), IsStaticFlag.kNotStatic, kNoSourcePosition);\n// \t\t// }\n\n// \t\t// if (class_scope -> needs_home_object()) {\n// \t\t// \tclassInfo.homeObjectVariable = class_scope -> DeclareHomeObjectVariable(ast_value_factory());\n// \t\t// \tclassInfo.staticHomeObjectVariable = class_scope -> DeclareStaticHomeObjectVariable(ast_value_factory());\n// \t\t// }\n\n// \t\t// bool should_save_class_variable_index = class_scope -> should_save_class_variable_index();\n// \t\t// if (!isAnonymous || should_save_class_variable_index) {\n// \t\t// \tthis.declareClassVariable(name, classInfo);\n// \t\t// \tif (should_save_class_variable_index) {\n// \t\t// \t\tclass_scope -> class_variable() -> set_is_used();\n// \t\t// \t\tclass_scope -> class_variable() -> ForceContextAllocation();\n// \t\t// \t}\n// \t\t// }\n// \t\treturn this.rewriteClassLiteral(name, classInfo);\n// \t}\n// \tprotected declarePublicClassMethod(name: ExpressionNode | undefined, property: ExpressionNode, isConstructor: boolean, classInfo: ClassInfo): ExpressionNode {\n// \t\tthrow new Error('Method not implemented.');\n// \t}\n// \tprotected declarePublicClassField(property: ExpressionNode, isStatic: boolean, isComputedName: boolean, classInfo: ClassInfo): ExpressionNode {\n// \t\tthrow new Error('Method not implemented.');\n// \t}\n// \tprotected inferFunctionName() {\n// \t\tthrow new Error('Method not implemented.');\n// \t}\n// \tprotected declarePrivateClassMember(name: ExpressionNode, property: ExpressionNode, propertyKind: ClassLiteralPropertyKind, isStatic: boolean, classInfo: ClassInfo): ExpressionNode {\n// \t\tthrow new Error('Method not implemented.');\n// \t}\n// \tprotected parseClassPropertyDefinition(classInfo: ClassInfo, propInfo: ParsePropertyInfo, hasExtends: boolean): ExpressionNode {\n// \t\tif (!classInfo) {\n// \t\t\tthrow new Error(this.errorMessage('class info is undefined'));\n// \t\t}\n// \t\tif (propInfo.position !== PropertyPosition.ClassLiteral) {\n// \t\t\tthrow new Error(this.errorMessage('expected property position ClassLiteral'));\n// \t\t}\n\n// \t\tconst nameToken = this.peek();\n// \t\tlet nameExpression: ExpressionNode;\n// \t\tif (nameToken.isType(Token.STATIC)) {\n// \t\t\tthis.consume(Token.STATIC);\n// \t\t\tif (this.peek().isType(Token.L_PARENTHESES)) {\n// \t\t\t\tpropInfo.kind = PropertyKind.Method;\n// \t\t\t\tpropInfo.name = this.parseIdentifier()!;\n// \t\t\t\tnameExpression = new StringNode(propInfo.name.toString());\n// \t\t\t} else if (this.peek().isType(Token.ASSIGN)\n// \t\t\t\t|| this.peek().isType(Token.SEMICOLON)\n// \t\t\t\t|| this.peek().isType(Token.R_BRACKETS)) {\n// \t\t\t\tpropInfo.name = this.parseIdentifier()!;\n// \t\t\t\tnameExpression = new StringNode(propInfo.name.toString());\n// \t\t\t} else {\n// \t\t\t\tpropInfo.isStatic = true;\n// \t\t\t\tnameExpression = this.parseProperty(propInfo);\n// \t\t\t}\n// \t\t} else {\n// \t\t\tnameExpression = this.parseProperty(propInfo);\n// \t\t}\n\n// \t\tswitch (propInfo.kind) {\n// \t\t\tcase PropertyKind.Assign:\n// \t\t\tcase PropertyKind.ClassField:\n// \t\t\tcase PropertyKind.ShorthandOrClassField:\n// \t\t\tcase PropertyKind.NotSet: {\n// \t\t\t\t// This case is a name followed by a\n// \t\t\t\t// name or other property. Here we have\n// \t\t\t\t// to assume that's an uninitialized\n// \t\t\t\t// field followed by a line break\n// \t\t\t\t// followed by a property, with ASI\n// \t\t\t\t// adding the semicolon. If not, there\n// \t\t\t\t// will be a syntax error after parsing\n// \t\t\t\t// the first name as an uninitialized\n// \t\t\t\t// field.\n// \t\t\t\tpropInfo.kind = PropertyKind.ClassField;\n\n// \t\t\t\t// if (!propInfo.isComputedName) {\n// \t\t\t\t// \tthis.checkClassFieldName(propInfo.name, propInfo.isStatic);\n// \t\t\t\t// }\n\n// \t\t\t\tconst initializer: ExpressionNode = this.parseMemberInitializer(classInfo, propInfo.isStatic);\n// \t\t\t\tthis.expectSemicolon();\n\n// \t\t\t\tconst result: ExpressionNode = this.newClassLiteralProperty(\n// \t\t\t\t\tnameExpression,\n// \t\t\t\t\tinitializer,\n// \t\t\t\t\tClassLiteralPropertyKind.FIELD,\n// \t\t\t\t\tpropInfo.isStatic,\n// \t\t\t\t\tpropInfo.isComputedName,\n// \t\t\t\t\tpropInfo.isPrivate\n// \t\t\t\t);\n// \t\t\t\tthis.setFunctionNameFromPropertyName(result, propInfo.name);\n// \t\t\t\treturn result;\n// \t\t\t}\n// \t\t\tcase PropertyKind.Method: {\n// \t\t\t\t// MethodDefinition\n// \t\t\t\t// PropertyName '(' StrictFormalParameters ')' '{' FunctionBody '}'\n// \t\t\t\t// '*' PropertyName '(' StrictFormalParameters ')' '{' FunctionBody '}'\n// \t\t\t\t// async PropertyName '(' StrictFormalParameters ')'\n// \t\t\t\t// '{' FunctionBody '}'\n// \t\t\t\t// async '*' PropertyName '(' StrictFormalParameters ')'\n// \t\t\t\t// '{' FunctionBody '}'\n\n// \t\t\t\t// if (!propInfo.isComputedName) {\n// \t\t\t\t// \tthis.checkClassMethodName(propInfo.name, PropertyKind.Method,propInfo.functionFlags, propInfo.isStatic,classInfo . hasSeenConstructor);\n// \t\t\t\t// }\n\n// \t\t\t\tlet kind: FunctionType = this.methodKindFor(propInfo.isStatic, propInfo.functionFlags);\n\n// \t\t\t\tif (!propInfo.isStatic && propInfo.name.toString() === 'constructor') {\n// \t\t\t\t\tclassInfo.hasSeenConstructor = true;\n// \t\t\t\t\tkind = hasExtends ? FunctionType.DERIVED_CONSTRUCTOR : FunctionType.BASE_CONSTRUCTOR;\n// \t\t\t\t}\n\n// \t\t\t\tconst value = this.parseFunctionLiteral(\n// \t\t\t\t\tkind,\n// \t\t\t\t\tpropInfo.name\n// \t\t\t\t\t// ,kSkipFunctionNameCheck, kind, FunctionSyntaxKind.kAccessorOrMethod\n// \t\t\t\t);\n\n// \t\t\t\tClassLiteralPropertyT result = factory() -> NewClassLiteralProperty(\n// \t\t\t\t\tname_expression, value, ClassLiteralProperty.METHOD,\n// \t\t\t\t\tpropInfo.is_static, propInfo.is_computed_name,\n// \t\t\t\t\tpropInfo.is_private);\n// \t\t\t\timpl() -> SetFunctionNameFromPropertyName(result, propInfo.name);\n// \t\t\t\treturn result;\n// \t\t\t}\n\n// \t\t\tcase PropertyKind.AccessorGetter:\n// \t\t\tcase PropertyKind.AccessorSetter: {\n// \t\t\t\tDCHECK_EQ(propInfo.function_flags, ParseFunctionFlag.kIsNormal);\n// \t\t\t\tbool is_get = propInfo.kind == PropertyKind.kAccessorGetter;\n\n// \t\t\t\tif (!propInfo.is_computed_name) {\n// \t\t\t\t\tCheckClassMethodName(propInfo.name, propInfo.kind,\n// \t\t\t\t\t\tParseFunctionFlag.kIsNormal, propInfo.is_static,\n// & class_info -> has_seen_constructor);\n// \t\t\t\t\t// Make sure the name expression is a string since we need a Name for\n// \t\t\t\t\t// Runtime_DefineAccessorPropertyUnchecked and since we can determine\n// \t\t\t\t\t// this statically we can skip the extra runtime check.\n// \t\t\t\t\tname_expression = factory() -> NewStringLiteral(\n// \t\t\t\t\t\tpropInfo.name, name_expression -> position());\n// \t\t\t\t}\n\n// \t\t\t\tFunctionKind kind;\n// \t\t\t\tif (propInfo.is_static) {\n// \t\t\t\t\tkind = is_get ? FunctionKind.kStaticGetterFunction\n// \t\t\t\t\t\t: FunctionKind.kStaticSetterFunction;\n// \t\t\t\t} else {\n// \t\t\t\t\tkind = is_get ? FunctionKind.kGetterFunction\n// \t\t\t\t\t\t: FunctionKind.kSetterFunction;\n// \t\t\t\t}\n\n// \t\t\t\tFunctionLiteralT value = impl() -> ParseFunctionLiteral(\n// \t\t\t\t\tpropInfo.name, scanner() -> location(), kSkipFunctionNameCheck, kind,\n// \t\t\t\t\tname_token_position, FunctionSyntaxKind.kAccessorOrMethod,\n// \t\t\t\t\tlanguage_mode(), nullptr);\n\n// \t\t\t\tClassLiteralPropertyKind property_kind =\n// \t\t\t\t\tis_get ? ClassLiteralProperty.GETTER : ClassLiteralProperty.SETTER;\n// \t\t\t\tClassLiteralPropertyT result = factory() -> NewClassLiteralProperty(\n// \t\t\t\t\tname_expression, value, property_kind, propInfo.is_static,\n// \t\t\t\t\tpropInfo.is_computed_name, propInfo.is_private);\n// \t\t\t\tconst AstRawString* prefix =\n// \t\t\t\tis_get ? ast_value_factory() -> get_space_string()\n// \t\t\t\t\t: ast_value_factory() -> set_space_string();\n// \t\t\t\timpl() -> SetFunctionNameFromPropertyName(result, propInfo.name, prefix);\n// \t\t\t\treturn result;\n// \t\t\t}\n// \t\t\tcase PropertyKind.Value:\n// \t\t\tcase PropertyKind.Shorthand:\n// \t\t\tcase PropertyKind.Spread:\n// \t\t\t\t// throw new Error(this.errorMessage('Report Unexpected Token'));\n// \t\t\t\treturn NullNode;\n// \t\t}\n// \t\tthrow new Error(this.errorMessage('UNREACHABLE'));\n// \t}\n// \tprotected methodKindFor(isStatic: boolean, functionFlags: FunctionType): FunctionType {\n// \t\tconst isGenerator = functionFlags.includes('GENERATOR');\n// \t\tconst isAsync = functionFlags.includes('ASYNC');\n// \t\treturn functionKindForImpl(\n// \t\t\tisStatic ? SubFunctionKind.StaticMethod : SubFunctionKind.NonStaticMethod,\n// \t\t\tisGenerator,\n// \t\t\tisAsync\n// \t\t);\n// \t}\n// \tnewClassLiteralProperty(nameExpression: ExpressionNode, initializer: ExpressionNode, FIELD: ClassLiteralPropertyKind, isStatic: boolean, isComputedName: boolean, isPrivate: boolean): ExpressionNode {\n// \t\tthrow new Error('Method not implemented.');\n// \t}\n// \tparseMemberInitializer(classInfo: ClassInfo, isStatic: boolean): ExpressionNode {\n// \t\tthrow new Error('Method not implemented.');\n// \t}\n// \tprotected parseClassStaticBlock(classInfo: ClassInfo): ExpressionNode {\n// \t\tthis.consume(Token.STATIC);\n// \t\t// Each static block has its own var and lexical scope, so make a new var\n// \t\t// block scope instead of using the synthetic members initializer function\n// \t\t// scope.\n// \t\tconst staticBlock = this.parseBlock();\n// \t\tclassInfo.hasStaticElements = true;\n// \t\treturn staticBlock;\n\n// \t}\n// \tprotected declareClass(variableName: ExpressionNode | undefined, value: ExpressionNode, names: ExpressionNode[] | undefined): ExpressionNode {\n// \t\tif (names && variableName) {\n// \t\t\tconst proxy = this.declareVariable(variableName, 'let');\n// \t\t\tnames.push(variableName);\n// \t\t\treturn new AssignmentNode('=', proxy, value);\n// \t\t}\n// \t\treturn value;\n// \t}\n// \tprotected parseSuperExpression(): ExpressionNode {\n// \t\tthrow new Error(this.errorMessage('Expression (supper) not supported.'));\n// \t}\n// \tprotected parseImportExpressions(): ExpressionNode {\n// \t\tthrow new Error(this.errorMessage('Expression (import) not supported.'));\n// \t}\n// \tprotected declareVariable(name: ExpressionNode | undefined, mode: 'let' | 'const' | 'var') {\n// \t\tif (!name) {\n// \t\t\tthrow new Error(this.errorMessage('Variable name is undefined'));\n// \t\t}\n// \t\tswitch (mode) {\n// \t\t\tcase 'const':\n// \t\t\t\treturn new ConstNode([new Variable(name)]);\n// \t\t\tdefault:\n// \t\t\tcase 'var':\n// \t\t\tcase 'let':\n// \t\t\t\treturn new LetNode([new Variable(name)]);\n// \t\t}\n// \t}\n// }\n"]}