oxc-parser 0.69.0 → 0.71.0
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.
- package/README.md +13 -5
- package/bindings.js +2 -1
- package/generated/deserialize/js.js +221 -210
- package/generated/deserialize/ts.js +262 -252
- package/index.d.ts +2 -1
- package/package.json +21 -18
|
@@ -35,8 +35,8 @@ function deserialize(buffer, sourceTextInput, sourceLenInput) {
|
|
|
35
35
|
}
|
|
36
36
|
|
|
37
37
|
function deserializeProgram(pos) {
|
|
38
|
-
const body = deserializeVecDirective(pos +
|
|
39
|
-
body.push(...deserializeVecStatement(pos +
|
|
38
|
+
const body = deserializeVecDirective(pos + 72);
|
|
39
|
+
body.push(...deserializeVecStatement(pos + 96));
|
|
40
40
|
|
|
41
41
|
const end = deserializeU32(pos + 4);
|
|
42
42
|
|
|
@@ -62,8 +62,8 @@ function deserializeProgram(pos) {
|
|
|
62
62
|
start,
|
|
63
63
|
end,
|
|
64
64
|
body,
|
|
65
|
-
sourceType: deserializeModuleKind(pos +
|
|
66
|
-
hashbang: deserializeOptionHashbang(pos +
|
|
65
|
+
sourceType: deserializeModuleKind(pos + 125),
|
|
66
|
+
hashbang: deserializeOptionHashbang(pos + 48),
|
|
67
67
|
};
|
|
68
68
|
return program;
|
|
69
69
|
}
|
|
@@ -151,12 +151,12 @@ function deserializeObjectProperty(pos) {
|
|
|
151
151
|
type: 'Property',
|
|
152
152
|
start: deserializeU32(pos),
|
|
153
153
|
end: deserializeU32(pos + 4),
|
|
154
|
-
method: deserializeBool(pos +
|
|
155
|
-
shorthand: deserializeBool(pos +
|
|
156
|
-
computed: deserializeBool(pos +
|
|
157
|
-
key: deserializePropertyKey(pos +
|
|
158
|
-
value: deserializeExpression(pos +
|
|
159
|
-
kind: deserializePropertyKind(pos +
|
|
154
|
+
method: deserializeBool(pos + 41),
|
|
155
|
+
shorthand: deserializeBool(pos + 42),
|
|
156
|
+
computed: deserializeBool(pos + 43),
|
|
157
|
+
key: deserializePropertyKey(pos + 8),
|
|
158
|
+
value: deserializeExpression(pos + 24),
|
|
159
|
+
kind: deserializePropertyKind(pos + 40),
|
|
160
160
|
optional: false,
|
|
161
161
|
};
|
|
162
162
|
}
|
|
@@ -166,7 +166,7 @@ function deserializeTemplateLiteral(pos) {
|
|
|
166
166
|
type: 'TemplateLiteral',
|
|
167
167
|
start: deserializeU32(pos),
|
|
168
168
|
end: deserializeU32(pos + 4),
|
|
169
|
-
expressions: deserializeVecExpression(pos +
|
|
169
|
+
expressions: deserializeVecExpression(pos + 32),
|
|
170
170
|
quasis: deserializeVecTemplateElement(pos + 8),
|
|
171
171
|
};
|
|
172
172
|
}
|
|
@@ -244,7 +244,7 @@ function deserializeCallExpression(pos) {
|
|
|
244
244
|
end: deserializeU32(pos + 4),
|
|
245
245
|
callee: deserializeExpression(pos + 8),
|
|
246
246
|
arguments: deserializeVecArgument(pos + 32),
|
|
247
|
-
optional: deserializeBool(pos +
|
|
247
|
+
optional: deserializeBool(pos + 56),
|
|
248
248
|
typeArguments: deserializeOptionBoxTSTypeParameterInstantiation(pos + 24),
|
|
249
249
|
};
|
|
250
250
|
}
|
|
@@ -284,9 +284,9 @@ function deserializeUpdateExpression(pos) {
|
|
|
284
284
|
type: 'UpdateExpression',
|
|
285
285
|
start: deserializeU32(pos),
|
|
286
286
|
end: deserializeU32(pos + 4),
|
|
287
|
-
operator: deserializeUpdateOperator(pos +
|
|
288
|
-
prefix: deserializeBool(pos +
|
|
289
|
-
argument: deserializeSimpleAssignmentTarget(pos +
|
|
287
|
+
operator: deserializeUpdateOperator(pos + 24),
|
|
288
|
+
prefix: deserializeBool(pos + 25),
|
|
289
|
+
argument: deserializeSimpleAssignmentTarget(pos + 8),
|
|
290
290
|
};
|
|
291
291
|
}
|
|
292
292
|
|
|
@@ -295,9 +295,9 @@ function deserializeUnaryExpression(pos) {
|
|
|
295
295
|
type: 'UnaryExpression',
|
|
296
296
|
start: deserializeU32(pos),
|
|
297
297
|
end: deserializeU32(pos + 4),
|
|
298
|
-
operator: deserializeUnaryOperator(pos +
|
|
298
|
+
operator: deserializeUnaryOperator(pos + 24),
|
|
299
299
|
prefix: true,
|
|
300
|
-
argument: deserializeExpression(pos +
|
|
300
|
+
argument: deserializeExpression(pos + 8),
|
|
301
301
|
};
|
|
302
302
|
}
|
|
303
303
|
|
|
@@ -307,8 +307,8 @@ function deserializeBinaryExpression(pos) {
|
|
|
307
307
|
start: deserializeU32(pos),
|
|
308
308
|
end: deserializeU32(pos + 4),
|
|
309
309
|
left: deserializeExpression(pos + 8),
|
|
310
|
-
operator: deserializeBinaryOperator(pos +
|
|
311
|
-
right: deserializeExpression(pos +
|
|
310
|
+
operator: deserializeBinaryOperator(pos + 40),
|
|
311
|
+
right: deserializeExpression(pos + 24),
|
|
312
312
|
};
|
|
313
313
|
}
|
|
314
314
|
|
|
@@ -329,8 +329,8 @@ function deserializeLogicalExpression(pos) {
|
|
|
329
329
|
start: deserializeU32(pos),
|
|
330
330
|
end: deserializeU32(pos + 4),
|
|
331
331
|
left: deserializeExpression(pos + 8),
|
|
332
|
-
operator: deserializeLogicalOperator(pos +
|
|
333
|
-
right: deserializeExpression(pos +
|
|
332
|
+
operator: deserializeLogicalOperator(pos + 40),
|
|
333
|
+
right: deserializeExpression(pos + 24),
|
|
334
334
|
};
|
|
335
335
|
}
|
|
336
336
|
|
|
@@ -350,15 +350,15 @@ function deserializeAssignmentExpression(pos) {
|
|
|
350
350
|
type: 'AssignmentExpression',
|
|
351
351
|
start: deserializeU32(pos),
|
|
352
352
|
end: deserializeU32(pos + 4),
|
|
353
|
-
operator: deserializeAssignmentOperator(pos +
|
|
354
|
-
left: deserializeAssignmentTarget(pos +
|
|
355
|
-
right: deserializeExpression(pos +
|
|
353
|
+
operator: deserializeAssignmentOperator(pos + 40),
|
|
354
|
+
left: deserializeAssignmentTarget(pos + 8),
|
|
355
|
+
right: deserializeExpression(pos + 24),
|
|
356
356
|
};
|
|
357
357
|
}
|
|
358
358
|
|
|
359
359
|
function deserializeArrayAssignmentTarget(pos) {
|
|
360
360
|
const elements = deserializeVecOptionAssignmentTargetMaybeDefault(pos + 8);
|
|
361
|
-
const rest = deserializeOptionAssignmentTargetRest(pos +
|
|
361
|
+
const rest = deserializeOptionAssignmentTargetRest(pos + 32);
|
|
362
362
|
if (rest !== null) elements.push(rest);
|
|
363
363
|
return {
|
|
364
364
|
type: 'ArrayPattern',
|
|
@@ -373,7 +373,7 @@ function deserializeArrayAssignmentTarget(pos) {
|
|
|
373
373
|
|
|
374
374
|
function deserializeObjectAssignmentTarget(pos) {
|
|
375
375
|
const properties = deserializeVecAssignmentTargetProperty(pos + 8);
|
|
376
|
-
const rest = deserializeOptionAssignmentTargetRest(pos +
|
|
376
|
+
const rest = deserializeOptionAssignmentTargetRest(pos + 32);
|
|
377
377
|
if (rest !== null) properties.push(rest);
|
|
378
378
|
return {
|
|
379
379
|
type: 'ObjectPattern',
|
|
@@ -426,9 +426,9 @@ function deserializeAssignmentTargetPropertyIdentifier(pos) {
|
|
|
426
426
|
end: end,
|
|
427
427
|
left: keyCopy,
|
|
428
428
|
right: init,
|
|
429
|
-
typeAnnotation: null,
|
|
430
|
-
optional: false,
|
|
431
429
|
decorators: [],
|
|
430
|
+
optional: false,
|
|
431
|
+
typeAnnotation: null,
|
|
432
432
|
};
|
|
433
433
|
return {
|
|
434
434
|
type: 'Property',
|
|
@@ -536,9 +536,9 @@ function deserializeVariableDeclaration(pos) {
|
|
|
536
536
|
type: 'VariableDeclaration',
|
|
537
537
|
start: deserializeU32(pos),
|
|
538
538
|
end: deserializeU32(pos + 4),
|
|
539
|
-
declarations: deserializeVecVariableDeclarator(pos +
|
|
540
|
-
kind: deserializeVariableDeclarationKind(pos +
|
|
541
|
-
declare: deserializeBool(pos +
|
|
539
|
+
declarations: deserializeVecVariableDeclarator(pos + 8),
|
|
540
|
+
kind: deserializeVariableDeclarationKind(pos + 32),
|
|
541
|
+
declare: deserializeBool(pos + 33),
|
|
542
542
|
};
|
|
543
543
|
}
|
|
544
544
|
|
|
@@ -547,9 +547,9 @@ function deserializeVariableDeclarator(pos) {
|
|
|
547
547
|
type: 'VariableDeclarator',
|
|
548
548
|
start: deserializeU32(pos),
|
|
549
549
|
end: deserializeU32(pos + 4),
|
|
550
|
-
id: deserializeBindingPattern(pos +
|
|
551
|
-
init: deserializeOptionExpression(pos +
|
|
552
|
-
definite: deserializeBool(pos +
|
|
550
|
+
id: deserializeBindingPattern(pos + 8),
|
|
551
|
+
init: deserializeOptionExpression(pos + 40),
|
|
552
|
+
definite: deserializeBool(pos + 57),
|
|
553
553
|
};
|
|
554
554
|
}
|
|
555
555
|
|
|
@@ -630,10 +630,10 @@ function deserializeForOfStatement(pos) {
|
|
|
630
630
|
type: 'ForOfStatement',
|
|
631
631
|
start: deserializeU32(pos),
|
|
632
632
|
end: deserializeU32(pos + 4),
|
|
633
|
-
await: deserializeBool(pos +
|
|
634
|
-
left: deserializeForStatementLeft(pos +
|
|
635
|
-
right: deserializeExpression(pos +
|
|
636
|
-
body: deserializeStatement(pos +
|
|
633
|
+
await: deserializeBool(pos + 60),
|
|
634
|
+
left: deserializeForStatementLeft(pos + 8),
|
|
635
|
+
right: deserializeExpression(pos + 24),
|
|
636
|
+
body: deserializeStatement(pos + 40),
|
|
637
637
|
};
|
|
638
638
|
}
|
|
639
639
|
|
|
@@ -773,7 +773,7 @@ function deserializeAssignmentPattern(pos) {
|
|
|
773
773
|
|
|
774
774
|
function deserializeObjectPattern(pos) {
|
|
775
775
|
const properties = deserializeVecBindingProperty(pos + 8);
|
|
776
|
-
const rest = deserializeOptionBoxBindingRestElement(pos +
|
|
776
|
+
const rest = deserializeOptionBoxBindingRestElement(pos + 32);
|
|
777
777
|
if (rest !== null) properties.push(rest);
|
|
778
778
|
return {
|
|
779
779
|
type: 'ObjectPattern',
|
|
@@ -803,7 +803,7 @@ function deserializeBindingProperty(pos) {
|
|
|
803
803
|
|
|
804
804
|
function deserializeArrayPattern(pos) {
|
|
805
805
|
const elements = deserializeVecOptionBindingPattern(pos + 8);
|
|
806
|
-
const rest = deserializeOptionBoxBindingRestElement(pos +
|
|
806
|
+
const rest = deserializeOptionBoxBindingRestElement(pos + 32);
|
|
807
807
|
if (rest !== null) elements.push(rest);
|
|
808
808
|
return {
|
|
809
809
|
type: 'ArrayPattern',
|
|
@@ -830,39 +830,39 @@ function deserializeBindingRestElement(pos) {
|
|
|
830
830
|
}
|
|
831
831
|
|
|
832
832
|
function deserializeFunction(pos) {
|
|
833
|
-
const params = deserializeBoxFormalParameters(pos +
|
|
834
|
-
const thisParam = deserializeOptionBoxTSThisParameter(pos +
|
|
833
|
+
const params = deserializeBoxFormalParameters(pos + 56);
|
|
834
|
+
const thisParam = deserializeOptionBoxTSThisParameter(pos + 48);
|
|
835
835
|
if (thisParam !== null) params.unshift(thisParam);
|
|
836
836
|
return {
|
|
837
|
-
type: deserializeFunctionType(pos +
|
|
837
|
+
type: deserializeFunctionType(pos + 84),
|
|
838
838
|
start: deserializeU32(pos),
|
|
839
839
|
end: deserializeU32(pos + 4),
|
|
840
|
-
id: deserializeOptionBindingIdentifier(pos +
|
|
840
|
+
id: deserializeOptionBindingIdentifier(pos + 8),
|
|
841
841
|
expression: false,
|
|
842
|
-
generator: deserializeBool(pos +
|
|
843
|
-
async: deserializeBool(pos +
|
|
842
|
+
generator: deserializeBool(pos + 85),
|
|
843
|
+
async: deserializeBool(pos + 86),
|
|
844
844
|
params,
|
|
845
|
-
body: deserializeOptionBoxFunctionBody(pos +
|
|
846
|
-
declare: deserializeBool(pos +
|
|
847
|
-
typeParameters: deserializeOptionBoxTSTypeParameterDeclaration(pos +
|
|
848
|
-
returnType: deserializeOptionBoxTSTypeAnnotation(pos +
|
|
845
|
+
body: deserializeOptionBoxFunctionBody(pos + 72),
|
|
846
|
+
declare: deserializeBool(pos + 87),
|
|
847
|
+
typeParameters: deserializeOptionBoxTSTypeParameterDeclaration(pos + 40),
|
|
848
|
+
returnType: deserializeOptionBoxTSTypeAnnotation(pos + 64),
|
|
849
849
|
};
|
|
850
850
|
}
|
|
851
851
|
|
|
852
852
|
function deserializeFormalParameters(pos) {
|
|
853
|
-
const params = deserializeVecFormalParameter(pos +
|
|
854
|
-
if (uint32[(pos +
|
|
855
|
-
pos = uint32[(pos +
|
|
853
|
+
const params = deserializeVecFormalParameter(pos + 8);
|
|
854
|
+
if (uint32[(pos + 32) >> 2] !== 0 && uint32[(pos + 36) >> 2] !== 0) {
|
|
855
|
+
pos = uint32[(pos + 32) >> 2];
|
|
856
856
|
params.push({
|
|
857
857
|
type: 'RestElement',
|
|
858
858
|
start: deserializeU32(pos),
|
|
859
859
|
end: deserializeU32(pos + 4),
|
|
860
860
|
argument: deserializeBindingPatternKind(pos + 8),
|
|
861
|
+
decorators: [],
|
|
862
|
+
optional: deserializeBool(pos + 32),
|
|
861
863
|
typeAnnotation: deserializeOptionBoxTSTypeAnnotation(
|
|
862
864
|
pos + 24,
|
|
863
865
|
),
|
|
864
|
-
optional: deserializeBool(pos + 32),
|
|
865
|
-
decorators: [],
|
|
866
866
|
value: null,
|
|
867
867
|
});
|
|
868
868
|
}
|
|
@@ -870,16 +870,16 @@ function deserializeFormalParameters(pos) {
|
|
|
870
870
|
}
|
|
871
871
|
|
|
872
872
|
function deserializeFormalParameter(pos) {
|
|
873
|
-
const accessibility = deserializeOptionTSAccessibility(pos +
|
|
874
|
-
readonly = deserializeBool(pos +
|
|
875
|
-
override = deserializeBool(pos +
|
|
873
|
+
const accessibility = deserializeOptionTSAccessibility(pos + 64),
|
|
874
|
+
readonly = deserializeBool(pos + 65),
|
|
875
|
+
override = deserializeBool(pos + 66);
|
|
876
876
|
let param;
|
|
877
877
|
if (accessibility === null && !readonly && !override) {
|
|
878
878
|
param = {
|
|
879
|
-
...deserializeBindingPatternKind(pos +
|
|
880
|
-
typeAnnotation: deserializeOptionBoxTSTypeAnnotation(pos + 56),
|
|
881
|
-
optional: deserializeBool(pos + 64),
|
|
879
|
+
...deserializeBindingPatternKind(pos + 32),
|
|
882
880
|
decorators: deserializeVecDecorator(pos + 8),
|
|
881
|
+
optional: deserializeBool(pos + 56),
|
|
882
|
+
typeAnnotation: deserializeOptionBoxTSTypeAnnotation(pos + 48),
|
|
883
883
|
};
|
|
884
884
|
} else {
|
|
885
885
|
param = {
|
|
@@ -889,7 +889,7 @@ function deserializeFormalParameter(pos) {
|
|
|
889
889
|
accessibility,
|
|
890
890
|
decorators: deserializeVecDecorator(pos + 8),
|
|
891
891
|
override,
|
|
892
|
-
parameter: deserializeBindingPattern(pos +
|
|
892
|
+
parameter: deserializeBindingPattern(pos + 32),
|
|
893
893
|
readonly,
|
|
894
894
|
static: false,
|
|
895
895
|
};
|
|
@@ -899,7 +899,7 @@ function deserializeFormalParameter(pos) {
|
|
|
899
899
|
|
|
900
900
|
function deserializeFunctionBody(pos) {
|
|
901
901
|
const body = deserializeVecDirective(pos + 8);
|
|
902
|
-
body.push(...deserializeVecStatement(pos +
|
|
902
|
+
body.push(...deserializeVecStatement(pos + 32));
|
|
903
903
|
return {
|
|
904
904
|
type: 'BlockStatement',
|
|
905
905
|
start: deserializeU32(pos),
|
|
@@ -909,8 +909,8 @@ function deserializeFunctionBody(pos) {
|
|
|
909
909
|
}
|
|
910
910
|
|
|
911
911
|
function deserializeArrowFunctionExpression(pos) {
|
|
912
|
-
const expression = deserializeBool(pos +
|
|
913
|
-
let body = deserializeBoxFunctionBody(pos +
|
|
912
|
+
const expression = deserializeBool(pos + 44);
|
|
913
|
+
let body = deserializeBoxFunctionBody(pos + 32);
|
|
914
914
|
return {
|
|
915
915
|
type: 'ArrowFunctionExpression',
|
|
916
916
|
start: deserializeU32(pos),
|
|
@@ -918,11 +918,11 @@ function deserializeArrowFunctionExpression(pos) {
|
|
|
918
918
|
id: null,
|
|
919
919
|
expression,
|
|
920
920
|
generator: false,
|
|
921
|
-
async: deserializeBool(pos +
|
|
922
|
-
params: deserializeBoxFormalParameters(pos +
|
|
921
|
+
async: deserializeBool(pos + 45),
|
|
922
|
+
params: deserializeBoxFormalParameters(pos + 16),
|
|
923
923
|
body: expression ? body.body[0].expression : body,
|
|
924
|
-
typeParameters: deserializeOptionBoxTSTypeParameterDeclaration(pos +
|
|
925
|
-
returnType: deserializeOptionBoxTSTypeAnnotation(pos +
|
|
924
|
+
typeParameters: deserializeOptionBoxTSTypeParameterDeclaration(pos + 8),
|
|
925
|
+
returnType: deserializeOptionBoxTSTypeAnnotation(pos + 24),
|
|
926
926
|
};
|
|
927
927
|
}
|
|
928
928
|
|
|
@@ -931,25 +931,25 @@ function deserializeYieldExpression(pos) {
|
|
|
931
931
|
type: 'YieldExpression',
|
|
932
932
|
start: deserializeU32(pos),
|
|
933
933
|
end: deserializeU32(pos + 4),
|
|
934
|
-
delegate: deserializeBool(pos +
|
|
935
|
-
argument: deserializeOptionExpression(pos +
|
|
934
|
+
delegate: deserializeBool(pos + 24),
|
|
935
|
+
argument: deserializeOptionExpression(pos + 8),
|
|
936
936
|
};
|
|
937
937
|
}
|
|
938
938
|
|
|
939
939
|
function deserializeClass(pos) {
|
|
940
940
|
return {
|
|
941
|
-
type: deserializeClassType(pos +
|
|
941
|
+
type: deserializeClassType(pos + 132),
|
|
942
942
|
start: deserializeU32(pos),
|
|
943
943
|
end: deserializeU32(pos + 4),
|
|
944
|
-
id: deserializeOptionBindingIdentifier(pos +
|
|
945
|
-
superClass: deserializeOptionExpression(pos +
|
|
946
|
-
body: deserializeBoxClassBody(pos +
|
|
947
|
-
decorators: deserializeVecDecorator(pos +
|
|
948
|
-
typeParameters: deserializeOptionBoxTSTypeParameterDeclaration(pos +
|
|
949
|
-
superTypeArguments: deserializeOptionBoxTSTypeParameterInstantiation(pos +
|
|
950
|
-
implements: deserializeVecTSClassImplements(pos +
|
|
951
|
-
abstract: deserializeBool(pos +
|
|
952
|
-
declare: deserializeBool(pos +
|
|
944
|
+
id: deserializeOptionBindingIdentifier(pos + 32),
|
|
945
|
+
superClass: deserializeOptionExpression(pos + 72),
|
|
946
|
+
body: deserializeBoxClassBody(pos + 120),
|
|
947
|
+
decorators: deserializeVecDecorator(pos + 8),
|
|
948
|
+
typeParameters: deserializeOptionBoxTSTypeParameterDeclaration(pos + 64),
|
|
949
|
+
superTypeArguments: deserializeOptionBoxTSTypeParameterInstantiation(pos + 88),
|
|
950
|
+
implements: deserializeVecTSClassImplements(pos + 96),
|
|
951
|
+
abstract: deserializeBool(pos + 133),
|
|
952
|
+
declare: deserializeBool(pos + 134),
|
|
953
953
|
};
|
|
954
954
|
}
|
|
955
955
|
|
|
@@ -963,8 +963,8 @@ function deserializeClassBody(pos) {
|
|
|
963
963
|
}
|
|
964
964
|
|
|
965
965
|
function deserializeMethodDefinition(pos) {
|
|
966
|
-
const kind = deserializeMethodDefinitionKind(pos +
|
|
967
|
-
let key = deserializePropertyKey(pos +
|
|
966
|
+
const kind = deserializeMethodDefinitionKind(pos + 57);
|
|
967
|
+
let key = deserializePropertyKey(pos + 32);
|
|
968
968
|
if (kind === 'constructor') {
|
|
969
969
|
key = {
|
|
970
970
|
type: 'Identifier',
|
|
@@ -977,38 +977,38 @@ function deserializeMethodDefinition(pos) {
|
|
|
977
977
|
};
|
|
978
978
|
}
|
|
979
979
|
return {
|
|
980
|
-
type: deserializeMethodDefinitionType(pos +
|
|
980
|
+
type: deserializeMethodDefinitionType(pos + 56),
|
|
981
981
|
start: deserializeU32(pos),
|
|
982
982
|
end: deserializeU32(pos + 4),
|
|
983
|
-
static: deserializeBool(pos +
|
|
984
|
-
computed: deserializeBool(pos +
|
|
983
|
+
static: deserializeBool(pos + 59),
|
|
984
|
+
computed: deserializeBool(pos + 58),
|
|
985
985
|
key,
|
|
986
986
|
kind,
|
|
987
|
-
value: deserializeBoxFunction(pos +
|
|
988
|
-
decorators: deserializeVecDecorator(pos +
|
|
989
|
-
override: deserializeBool(pos +
|
|
990
|
-
optional: deserializeBool(pos +
|
|
991
|
-
accessibility: deserializeOptionTSAccessibility(pos +
|
|
987
|
+
value: deserializeBoxFunction(pos + 48),
|
|
988
|
+
decorators: deserializeVecDecorator(pos + 8),
|
|
989
|
+
override: deserializeBool(pos + 60),
|
|
990
|
+
optional: deserializeBool(pos + 61),
|
|
991
|
+
accessibility: deserializeOptionTSAccessibility(pos + 62),
|
|
992
992
|
};
|
|
993
993
|
}
|
|
994
994
|
|
|
995
995
|
function deserializePropertyDefinition(pos) {
|
|
996
996
|
return {
|
|
997
|
-
type: deserializePropertyDefinitionType(pos +
|
|
997
|
+
type: deserializePropertyDefinitionType(pos + 72),
|
|
998
998
|
start: deserializeU32(pos),
|
|
999
999
|
end: deserializeU32(pos + 4),
|
|
1000
|
-
static: deserializeBool(pos +
|
|
1001
|
-
computed: deserializeBool(pos +
|
|
1002
|
-
key: deserializePropertyKey(pos +
|
|
1003
|
-
value: deserializeOptionExpression(pos +
|
|
1004
|
-
decorators: deserializeVecDecorator(pos +
|
|
1005
|
-
declare: deserializeBool(pos +
|
|
1006
|
-
override: deserializeBool(pos +
|
|
1007
|
-
optional: deserializeBool(pos +
|
|
1008
|
-
definite: deserializeBool(pos +
|
|
1009
|
-
readonly: deserializeBool(pos +
|
|
1010
|
-
typeAnnotation: deserializeOptionBoxTSTypeAnnotation(pos +
|
|
1011
|
-
accessibility: deserializeOptionTSAccessibility(pos +
|
|
1000
|
+
static: deserializeBool(pos + 74),
|
|
1001
|
+
computed: deserializeBool(pos + 73),
|
|
1002
|
+
key: deserializePropertyKey(pos + 32),
|
|
1003
|
+
value: deserializeOptionExpression(pos + 56),
|
|
1004
|
+
decorators: deserializeVecDecorator(pos + 8),
|
|
1005
|
+
declare: deserializeBool(pos + 75),
|
|
1006
|
+
override: deserializeBool(pos + 76),
|
|
1007
|
+
optional: deserializeBool(pos + 77),
|
|
1008
|
+
definite: deserializeBool(pos + 78),
|
|
1009
|
+
readonly: deserializeBool(pos + 79),
|
|
1010
|
+
typeAnnotation: deserializeOptionBoxTSTypeAnnotation(pos + 48),
|
|
1011
|
+
accessibility: deserializeOptionTSAccessibility(pos + 80),
|
|
1012
1012
|
};
|
|
1013
1013
|
}
|
|
1014
1014
|
|
|
@@ -1032,19 +1032,19 @@ function deserializeStaticBlock(pos) {
|
|
|
1032
1032
|
|
|
1033
1033
|
function deserializeAccessorProperty(pos) {
|
|
1034
1034
|
return {
|
|
1035
|
-
type: deserializeAccessorPropertyType(pos +
|
|
1035
|
+
type: deserializeAccessorPropertyType(pos + 72),
|
|
1036
1036
|
start: deserializeU32(pos),
|
|
1037
1037
|
end: deserializeU32(pos + 4),
|
|
1038
|
-
key: deserializePropertyKey(pos +
|
|
1039
|
-
typeAnnotation: deserializeOptionBoxTSTypeAnnotation(pos +
|
|
1040
|
-
value: deserializeOptionExpression(pos +
|
|
1041
|
-
computed: deserializeBool(pos +
|
|
1042
|
-
static: deserializeBool(pos +
|
|
1043
|
-
decorators: deserializeVecDecorator(pos +
|
|
1044
|
-
definite: deserializeBool(pos +
|
|
1045
|
-
accessibility: deserializeOptionTSAccessibility(pos +
|
|
1038
|
+
key: deserializePropertyKey(pos + 32),
|
|
1039
|
+
typeAnnotation: deserializeOptionBoxTSTypeAnnotation(pos + 48),
|
|
1040
|
+
value: deserializeOptionExpression(pos + 56),
|
|
1041
|
+
computed: deserializeBool(pos + 73),
|
|
1042
|
+
static: deserializeBool(pos + 74),
|
|
1043
|
+
decorators: deserializeVecDecorator(pos + 8),
|
|
1044
|
+
definite: deserializeBool(pos + 76),
|
|
1045
|
+
accessibility: deserializeOptionTSAccessibility(pos + 77),
|
|
1046
1046
|
optional: false,
|
|
1047
|
-
override: deserializeBool(pos +
|
|
1047
|
+
override: deserializeBool(pos + 75),
|
|
1048
1048
|
readonly: false,
|
|
1049
1049
|
declare: false,
|
|
1050
1050
|
};
|
|
@@ -1063,15 +1063,16 @@ function deserializeImportExpression(pos) {
|
|
|
1063
1063
|
function deserializeImportDeclaration(pos) {
|
|
1064
1064
|
let specifiers = deserializeOptionVecImportDeclarationSpecifier(pos + 8);
|
|
1065
1065
|
if (specifiers === null) specifiers = [];
|
|
1066
|
-
const withClause = deserializeOptionBoxWithClause(pos +
|
|
1066
|
+
const withClause = deserializeOptionBoxWithClause(pos + 80);
|
|
1067
1067
|
return {
|
|
1068
1068
|
type: 'ImportDeclaration',
|
|
1069
1069
|
start: deserializeU32(pos),
|
|
1070
1070
|
end: deserializeU32(pos + 4),
|
|
1071
1071
|
specifiers,
|
|
1072
|
-
source: deserializeStringLiteral(pos +
|
|
1073
|
-
attributes: withClause === null ? [] : withClause.
|
|
1074
|
-
|
|
1072
|
+
source: deserializeStringLiteral(pos + 32),
|
|
1073
|
+
attributes: withClause === null ? [] : withClause.attributes,
|
|
1074
|
+
phase: deserializeOptionImportPhase(pos + 88),
|
|
1075
|
+
importKind: deserializeImportOrExportKind(pos + 89),
|
|
1075
1076
|
};
|
|
1076
1077
|
}
|
|
1077
1078
|
|
|
@@ -1106,11 +1107,7 @@ function deserializeImportNamespaceSpecifier(pos) {
|
|
|
1106
1107
|
|
|
1107
1108
|
function deserializeWithClause(pos) {
|
|
1108
1109
|
return {
|
|
1109
|
-
|
|
1110
|
-
start: deserializeU32(pos),
|
|
1111
|
-
end: deserializeU32(pos + 4),
|
|
1112
|
-
attributesKeyword: deserializeIdentifierName(pos + 8),
|
|
1113
|
-
withEntries: deserializeVecImportAttribute(pos + 32),
|
|
1110
|
+
attributes: deserializeVecImportAttribute(pos + 32),
|
|
1114
1111
|
};
|
|
1115
1112
|
}
|
|
1116
1113
|
|
|
@@ -1125,15 +1122,15 @@ function deserializeImportAttribute(pos) {
|
|
|
1125
1122
|
}
|
|
1126
1123
|
|
|
1127
1124
|
function deserializeExportNamedDeclaration(pos) {
|
|
1128
|
-
const withClause = deserializeOptionBoxWithClause(pos +
|
|
1125
|
+
const withClause = deserializeOptionBoxWithClause(pos + 96);
|
|
1129
1126
|
return {
|
|
1130
1127
|
type: 'ExportNamedDeclaration',
|
|
1131
1128
|
start: deserializeU32(pos),
|
|
1132
1129
|
end: deserializeU32(pos + 4),
|
|
1133
1130
|
declaration: deserializeOptionDeclaration(pos + 8),
|
|
1134
1131
|
specifiers: deserializeVecExportSpecifier(pos + 24),
|
|
1135
|
-
source: deserializeOptionStringLiteral(pos +
|
|
1136
|
-
attributes: withClause === null ? [] : withClause.
|
|
1132
|
+
source: deserializeOptionStringLiteral(pos + 48),
|
|
1133
|
+
attributes: withClause === null ? [] : withClause.attributes,
|
|
1137
1134
|
exportKind: deserializeImportOrExportKind(pos + 104),
|
|
1138
1135
|
};
|
|
1139
1136
|
}
|
|
@@ -1156,7 +1153,7 @@ function deserializeExportAllDeclaration(pos) {
|
|
|
1156
1153
|
end: deserializeU32(pos + 4),
|
|
1157
1154
|
exported: deserializeOptionModuleExportName(pos + 8),
|
|
1158
1155
|
source: deserializeStringLiteral(pos + 64),
|
|
1159
|
-
attributes: withClause === null ? [] : withClause.
|
|
1156
|
+
attributes: withClause === null ? [] : withClause.attributes,
|
|
1160
1157
|
exportKind: deserializeImportOrExportKind(pos + 120),
|
|
1161
1158
|
};
|
|
1162
1159
|
}
|
|
@@ -1289,7 +1286,7 @@ function deserializeRegExpFlags(pos) {
|
|
|
1289
1286
|
}
|
|
1290
1287
|
|
|
1291
1288
|
function deserializeJSXElement(pos) {
|
|
1292
|
-
const closingElement = deserializeOptionBoxJSXClosingElement(pos +
|
|
1289
|
+
const closingElement = deserializeOptionBoxJSXClosingElement(pos + 40);
|
|
1293
1290
|
const openingElement = deserializeBoxJSXOpeningElement(pos + 8);
|
|
1294
1291
|
if (closingElement === null) openingElement.selfClosing = true;
|
|
1295
1292
|
return {
|
|
@@ -1329,18 +1326,17 @@ function deserializeJSXFragment(pos) {
|
|
|
1329
1326
|
start: deserializeU32(pos),
|
|
1330
1327
|
end: deserializeU32(pos + 4),
|
|
1331
1328
|
openingFragment: deserializeJSXOpeningFragment(pos + 8),
|
|
1332
|
-
closingFragment: deserializeJSXClosingFragment(pos +
|
|
1329
|
+
closingFragment: deserializeJSXClosingFragment(pos + 40),
|
|
1333
1330
|
children: deserializeVecJSXChild(pos + 16),
|
|
1334
1331
|
};
|
|
1335
1332
|
}
|
|
1336
1333
|
|
|
1337
1334
|
function deserializeJSXOpeningFragment(pos) {
|
|
1338
|
-
|
|
1335
|
+
return {
|
|
1339
1336
|
type: 'JSXOpeningFragment',
|
|
1340
1337
|
start: deserializeU32(pos),
|
|
1341
1338
|
end: deserializeU32(pos + 4),
|
|
1342
1339
|
};
|
|
1343
|
-
return node;
|
|
1344
1340
|
}
|
|
1345
1341
|
|
|
1346
1342
|
function deserializeJSXClosingFragment(pos) {
|
|
@@ -1454,8 +1450,8 @@ function deserializeTSEnumDeclaration(pos) {
|
|
|
1454
1450
|
end: deserializeU32(pos + 4),
|
|
1455
1451
|
id: deserializeBindingIdentifier(pos + 8),
|
|
1456
1452
|
body: deserializeTSEnumBody(pos + 40),
|
|
1457
|
-
const: deserializeBool(pos +
|
|
1458
|
-
declare: deserializeBool(pos +
|
|
1453
|
+
const: deserializeBool(pos + 76),
|
|
1454
|
+
declare: deserializeBool(pos + 77),
|
|
1459
1455
|
};
|
|
1460
1456
|
}
|
|
1461
1457
|
|
|
@@ -1541,8 +1537,8 @@ function deserializeTSTypeOperator(pos) {
|
|
|
1541
1537
|
type: 'TSTypeOperator',
|
|
1542
1538
|
start: deserializeU32(pos),
|
|
1543
1539
|
end: deserializeU32(pos + 4),
|
|
1544
|
-
operator: deserializeTSTypeOperatorOperator(pos +
|
|
1545
|
-
typeAnnotation: deserializeTSType(pos +
|
|
1540
|
+
operator: deserializeTSTypeOperatorOperator(pos + 24),
|
|
1541
|
+
typeAnnotation: deserializeTSType(pos + 8),
|
|
1546
1542
|
};
|
|
1547
1543
|
}
|
|
1548
1544
|
|
|
@@ -1775,7 +1771,7 @@ function deserializeTSTypeAliasDeclaration(pos) {
|
|
|
1775
1771
|
id: deserializeBindingIdentifier(pos + 8),
|
|
1776
1772
|
typeParameters: deserializeOptionBoxTSTypeParameterDeclaration(pos + 40),
|
|
1777
1773
|
typeAnnotation: deserializeTSType(pos + 48),
|
|
1778
|
-
declare: deserializeBool(pos +
|
|
1774
|
+
declare: deserializeBool(pos + 68),
|
|
1779
1775
|
};
|
|
1780
1776
|
}
|
|
1781
1777
|
|
|
@@ -1822,8 +1818,8 @@ function deserializeTSInterfaceDeclaration(pos) {
|
|
|
1822
1818
|
id: deserializeBindingIdentifier(pos + 8),
|
|
1823
1819
|
typeParameters: deserializeOptionBoxTSTypeParameterDeclaration(pos + 40),
|
|
1824
1820
|
extends: deserializeVecTSInterfaceHeritage(pos + 48),
|
|
1825
|
-
body: deserializeBoxTSInterfaceBody(pos +
|
|
1826
|
-
declare: deserializeBool(pos +
|
|
1821
|
+
body: deserializeBoxTSInterfaceBody(pos + 72),
|
|
1822
|
+
declare: deserializeBool(pos + 84),
|
|
1827
1823
|
};
|
|
1828
1824
|
}
|
|
1829
1825
|
|
|
@@ -1841,11 +1837,11 @@ function deserializeTSPropertySignature(pos) {
|
|
|
1841
1837
|
type: 'TSPropertySignature',
|
|
1842
1838
|
start: deserializeU32(pos),
|
|
1843
1839
|
end: deserializeU32(pos + 4),
|
|
1844
|
-
computed: deserializeBool(pos +
|
|
1845
|
-
optional: deserializeBool(pos +
|
|
1846
|
-
readonly: deserializeBool(pos +
|
|
1847
|
-
key: deserializePropertyKey(pos +
|
|
1848
|
-
typeAnnotation: deserializeOptionBoxTSTypeAnnotation(pos +
|
|
1840
|
+
computed: deserializeBool(pos + 32),
|
|
1841
|
+
optional: deserializeBool(pos + 33),
|
|
1842
|
+
readonly: deserializeBool(pos + 34),
|
|
1843
|
+
key: deserializePropertyKey(pos + 8),
|
|
1844
|
+
typeAnnotation: deserializeOptionBoxTSTypeAnnotation(pos + 24),
|
|
1849
1845
|
accessibility: null,
|
|
1850
1846
|
static: false,
|
|
1851
1847
|
};
|
|
@@ -1857,9 +1853,9 @@ function deserializeTSIndexSignature(pos) {
|
|
|
1857
1853
|
start: deserializeU32(pos),
|
|
1858
1854
|
end: deserializeU32(pos + 4),
|
|
1859
1855
|
parameters: deserializeVecTSIndexSignatureName(pos + 8),
|
|
1860
|
-
typeAnnotation: deserializeBoxTSTypeAnnotation(pos +
|
|
1861
|
-
readonly: deserializeBool(pos +
|
|
1862
|
-
static: deserializeBool(pos +
|
|
1856
|
+
typeAnnotation: deserializeBoxTSTypeAnnotation(pos + 32),
|
|
1857
|
+
readonly: deserializeBool(pos + 40),
|
|
1858
|
+
static: deserializeBool(pos + 41),
|
|
1863
1859
|
accessibility: null,
|
|
1864
1860
|
};
|
|
1865
1861
|
}
|
|
@@ -1879,20 +1875,20 @@ function deserializeTSCallSignatureDeclaration(pos) {
|
|
|
1879
1875
|
}
|
|
1880
1876
|
|
|
1881
1877
|
function deserializeTSMethodSignature(pos) {
|
|
1882
|
-
const params = deserializeBoxFormalParameters(pos +
|
|
1883
|
-
const thisParam = deserializeOptionBoxTSThisParameter(pos +
|
|
1878
|
+
const params = deserializeBoxFormalParameters(pos + 40);
|
|
1879
|
+
const thisParam = deserializeOptionBoxTSThisParameter(pos + 32);
|
|
1884
1880
|
if (thisParam !== null) params.unshift(thisParam);
|
|
1885
1881
|
return {
|
|
1886
1882
|
type: 'TSMethodSignature',
|
|
1887
1883
|
start: deserializeU32(pos),
|
|
1888
1884
|
end: deserializeU32(pos + 4),
|
|
1889
1885
|
key: deserializePropertyKey(pos + 8),
|
|
1890
|
-
computed: deserializeBool(pos +
|
|
1891
|
-
optional: deserializeBool(pos +
|
|
1892
|
-
kind: deserializeTSMethodSignatureKind(pos +
|
|
1893
|
-
typeParameters: deserializeOptionBoxTSTypeParameterDeclaration(pos +
|
|
1886
|
+
computed: deserializeBool(pos + 60),
|
|
1887
|
+
optional: deserializeBool(pos + 61),
|
|
1888
|
+
kind: deserializeTSMethodSignatureKind(pos + 62),
|
|
1889
|
+
typeParameters: deserializeOptionBoxTSTypeParameterDeclaration(pos + 24),
|
|
1894
1890
|
params,
|
|
1895
|
-
returnType: deserializeOptionBoxTSTypeAnnotation(pos +
|
|
1891
|
+
returnType: deserializeOptionBoxTSTypeAnnotation(pos + 48),
|
|
1896
1892
|
accessibility: null,
|
|
1897
1893
|
readonly: false,
|
|
1898
1894
|
static: false,
|
|
@@ -1938,29 +1934,48 @@ function deserializeTSTypePredicate(pos) {
|
|
|
1938
1934
|
start: deserializeU32(pos),
|
|
1939
1935
|
end: deserializeU32(pos + 4),
|
|
1940
1936
|
parameterName: deserializeTSTypePredicateName(pos + 8),
|
|
1941
|
-
asserts: deserializeBool(pos +
|
|
1942
|
-
typeAnnotation: deserializeOptionBoxTSTypeAnnotation(pos +
|
|
1937
|
+
asserts: deserializeBool(pos + 32),
|
|
1938
|
+
typeAnnotation: deserializeOptionBoxTSTypeAnnotation(pos + 24),
|
|
1943
1939
|
};
|
|
1944
1940
|
}
|
|
1945
1941
|
|
|
1946
1942
|
function deserializeTSModuleDeclaration(pos) {
|
|
1947
|
-
const kind = deserializeTSModuleDeclarationKind(pos +
|
|
1943
|
+
const kind = deserializeTSModuleDeclarationKind(pos + 84),
|
|
1948
1944
|
global = kind === 'global',
|
|
1949
1945
|
start = deserializeU32(pos),
|
|
1950
1946
|
end = deserializeU32(pos + 4),
|
|
1951
|
-
declare = deserializeBool(pos +
|
|
1947
|
+
declare = deserializeBool(pos + 85);
|
|
1952
1948
|
let id = deserializeTSModuleDeclarationName(pos + 8),
|
|
1953
1949
|
body = deserializeOptionTSModuleDeclarationBody(pos + 64);
|
|
1954
1950
|
|
|
1955
1951
|
// Flatten `body`, and nest `id`
|
|
1956
1952
|
if (body !== null && body.type === 'TSModuleDeclaration') {
|
|
1957
|
-
|
|
1958
|
-
|
|
1959
|
-
|
|
1960
|
-
|
|
1961
|
-
|
|
1962
|
-
|
|
1963
|
-
|
|
1953
|
+
let innerId = body.id;
|
|
1954
|
+
if (innerId.type === 'Identifier') {
|
|
1955
|
+
id = {
|
|
1956
|
+
type: 'TSQualifiedName',
|
|
1957
|
+
start: id.start,
|
|
1958
|
+
end: innerId.end,
|
|
1959
|
+
left: id,
|
|
1960
|
+
right: innerId,
|
|
1961
|
+
};
|
|
1962
|
+
} else {
|
|
1963
|
+
// Replace `left` of innermost `TSQualifiedName` with a nested `TSQualifiedName` with `id` of
|
|
1964
|
+
// this module on left, and previous `left` of innermost `TSQualifiedName` on right
|
|
1965
|
+
while (true) {
|
|
1966
|
+
innerId.start = id.start;
|
|
1967
|
+
if (innerId.left.type === 'Identifier') break;
|
|
1968
|
+
innerId = innerId.left;
|
|
1969
|
+
}
|
|
1970
|
+
innerId.left = {
|
|
1971
|
+
type: 'TSQualifiedName',
|
|
1972
|
+
start: id.start,
|
|
1973
|
+
end: innerId.left.end,
|
|
1974
|
+
left: id,
|
|
1975
|
+
right: innerId.left,
|
|
1976
|
+
};
|
|
1977
|
+
id = body.id;
|
|
1978
|
+
}
|
|
1964
1979
|
body = Object.hasOwn(body, 'body') ? body.body : null;
|
|
1965
1980
|
}
|
|
1966
1981
|
|
|
@@ -1973,7 +1988,7 @@ function deserializeTSModuleDeclaration(pos) {
|
|
|
1973
1988
|
|
|
1974
1989
|
function deserializeTSModuleBlock(pos) {
|
|
1975
1990
|
const body = deserializeVecDirective(pos + 8);
|
|
1976
|
-
body.push(...deserializeVecStatement(pos +
|
|
1991
|
+
body.push(...deserializeVecStatement(pos + 32));
|
|
1977
1992
|
return {
|
|
1978
1993
|
type: 'TSModuleBlock',
|
|
1979
1994
|
start: deserializeU32(pos),
|
|
@@ -2041,15 +2056,15 @@ function deserializeTSConstructorType(pos) {
|
|
|
2041
2056
|
type: 'TSConstructorType',
|
|
2042
2057
|
start: deserializeU32(pos),
|
|
2043
2058
|
end: deserializeU32(pos + 4),
|
|
2044
|
-
abstract: deserializeBool(pos +
|
|
2045
|
-
typeParameters: deserializeOptionBoxTSTypeParameterDeclaration(pos +
|
|
2046
|
-
params: deserializeBoxFormalParameters(pos +
|
|
2047
|
-
returnType: deserializeBoxTSTypeAnnotation(pos +
|
|
2059
|
+
abstract: deserializeBool(pos + 32),
|
|
2060
|
+
typeParameters: deserializeOptionBoxTSTypeParameterDeclaration(pos + 8),
|
|
2061
|
+
params: deserializeBoxFormalParameters(pos + 16),
|
|
2062
|
+
returnType: deserializeBoxTSTypeAnnotation(pos + 24),
|
|
2048
2063
|
};
|
|
2049
2064
|
}
|
|
2050
2065
|
|
|
2051
2066
|
function deserializeTSMappedType(pos) {
|
|
2052
|
-
let optional = deserializeOptionTSMappedTypeModifierOperator(pos +
|
|
2067
|
+
let optional = deserializeOptionTSMappedTypeModifierOperator(pos + 52);
|
|
2053
2068
|
if (optional === null) optional = false;
|
|
2054
2069
|
const typeParameter = deserializeBoxTSTypeParameter(pos + 8);
|
|
2055
2070
|
return {
|
|
@@ -2059,7 +2074,7 @@ function deserializeTSMappedType(pos) {
|
|
|
2059
2074
|
nameType: deserializeOptionTSType(pos + 16),
|
|
2060
2075
|
typeAnnotation: deserializeOptionTSType(pos + 32),
|
|
2061
2076
|
optional,
|
|
2062
|
-
readonly: deserializeOptionTSMappedTypeModifierOperator(pos +
|
|
2077
|
+
readonly: deserializeOptionTSMappedTypeModifierOperator(pos + 53),
|
|
2063
2078
|
key: typeParameter.name,
|
|
2064
2079
|
constraint: typeParameter.constraint,
|
|
2065
2080
|
};
|
|
@@ -2071,7 +2086,7 @@ function deserializeTSTemplateLiteralType(pos) {
|
|
|
2071
2086
|
start: deserializeU32(pos),
|
|
2072
2087
|
end: deserializeU32(pos + 4),
|
|
2073
2088
|
quasis: deserializeVecTemplateElement(pos + 8),
|
|
2074
|
-
types: deserializeVecTSType(pos +
|
|
2089
|
+
types: deserializeVecTSType(pos + 32),
|
|
2075
2090
|
};
|
|
2076
2091
|
}
|
|
2077
2092
|
|
|
@@ -2214,9 +2229,9 @@ function deserializeComment(pos) {
|
|
|
2214
2229
|
|
|
2215
2230
|
function deserializeNameSpan(pos) {
|
|
2216
2231
|
return {
|
|
2217
|
-
value: deserializeStr(pos),
|
|
2218
|
-
start: deserializeU32(pos
|
|
2219
|
-
end: deserializeU32(pos +
|
|
2232
|
+
value: deserializeStr(pos + 8),
|
|
2233
|
+
start: deserializeU32(pos),
|
|
2234
|
+
end: deserializeU32(pos + 4),
|
|
2220
2235
|
};
|
|
2221
2236
|
}
|
|
2222
2237
|
|
|
@@ -2230,8 +2245,8 @@ function deserializeImportEntry(pos) {
|
|
|
2230
2245
|
|
|
2231
2246
|
function deserializeExportEntry(pos) {
|
|
2232
2247
|
return {
|
|
2233
|
-
start: deserializeU32(pos
|
|
2234
|
-
end: deserializeU32(pos +
|
|
2248
|
+
start: deserializeU32(pos),
|
|
2249
|
+
end: deserializeU32(pos + 4),
|
|
2235
2250
|
moduleRequest: deserializeOptionNameSpan(pos + 16),
|
|
2236
2251
|
importName: deserializeExportImportName(pos + 40),
|
|
2237
2252
|
exportName: deserializeExportExportName(pos + 72),
|
|
@@ -2264,36 +2279,36 @@ function deserializeSourceType(pos) {
|
|
|
2264
2279
|
function deserializeRawTransferData(pos) {
|
|
2265
2280
|
return {
|
|
2266
2281
|
program: deserializeProgram(pos),
|
|
2267
|
-
comments: deserializeVecComment(pos +
|
|
2268
|
-
module: deserializeEcmaScriptModule(pos +
|
|
2269
|
-
errors: deserializeVecError(pos +
|
|
2282
|
+
comments: deserializeVecComment(pos + 128),
|
|
2283
|
+
module: deserializeEcmaScriptModule(pos + 152),
|
|
2284
|
+
errors: deserializeVecError(pos + 256),
|
|
2270
2285
|
};
|
|
2271
2286
|
}
|
|
2272
2287
|
|
|
2273
2288
|
function deserializeError(pos) {
|
|
2274
2289
|
return {
|
|
2275
|
-
severity: deserializeErrorSeverity(pos),
|
|
2276
|
-
message: deserializeStr(pos
|
|
2277
|
-
labels: deserializeVecErrorLabel(pos +
|
|
2278
|
-
helpMessage: deserializeOptionStr(pos +
|
|
2290
|
+
severity: deserializeErrorSeverity(pos + 56),
|
|
2291
|
+
message: deserializeStr(pos),
|
|
2292
|
+
labels: deserializeVecErrorLabel(pos + 16),
|
|
2293
|
+
helpMessage: deserializeOptionStr(pos + 40),
|
|
2279
2294
|
};
|
|
2280
2295
|
}
|
|
2281
2296
|
|
|
2282
2297
|
function deserializeErrorLabel(pos) {
|
|
2283
2298
|
return {
|
|
2284
|
-
message: deserializeOptionStr(pos),
|
|
2285
|
-
start: deserializeU32(pos
|
|
2286
|
-
end: deserializeU32(pos +
|
|
2299
|
+
message: deserializeOptionStr(pos + 8),
|
|
2300
|
+
start: deserializeU32(pos),
|
|
2301
|
+
end: deserializeU32(pos + 4),
|
|
2287
2302
|
};
|
|
2288
2303
|
}
|
|
2289
2304
|
|
|
2290
2305
|
function deserializeEcmaScriptModule(pos) {
|
|
2291
2306
|
return {
|
|
2292
|
-
hasModuleSyntax: deserializeBool(pos),
|
|
2293
|
-
staticImports: deserializeVecStaticImport(pos
|
|
2294
|
-
staticExports: deserializeVecStaticExport(pos +
|
|
2295
|
-
dynamicImports: deserializeVecDynamicImport(pos +
|
|
2296
|
-
importMetas: deserializeVecSpan(pos +
|
|
2307
|
+
hasModuleSyntax: deserializeBool(pos + 96),
|
|
2308
|
+
staticImports: deserializeVecStaticImport(pos),
|
|
2309
|
+
staticExports: deserializeVecStaticExport(pos + 24),
|
|
2310
|
+
dynamicImports: deserializeVecDynamicImport(pos + 48),
|
|
2311
|
+
importMetas: deserializeVecSpan(pos + 72),
|
|
2297
2312
|
};
|
|
2298
2313
|
}
|
|
2299
2314
|
|
|
@@ -4188,11 +4203,11 @@ function deserializeStr(pos) {
|
|
|
4188
4203
|
function deserializeVecComment(pos) {
|
|
4189
4204
|
const arr = [],
|
|
4190
4205
|
pos32 = pos >> 2,
|
|
4191
|
-
len = uint32[pos32 +
|
|
4206
|
+
len = uint32[pos32 + 2];
|
|
4192
4207
|
pos = uint32[pos32];
|
|
4193
4208
|
for (let i = 0; i < len; i++) {
|
|
4194
4209
|
arr.push(deserializeComment(pos));
|
|
4195
|
-
pos +=
|
|
4210
|
+
pos += 16;
|
|
4196
4211
|
}
|
|
4197
4212
|
return arr;
|
|
4198
4213
|
}
|
|
@@ -4205,7 +4220,7 @@ function deserializeOptionHashbang(pos) {
|
|
|
4205
4220
|
function deserializeVecDirective(pos) {
|
|
4206
4221
|
const arr = [],
|
|
4207
4222
|
pos32 = pos >> 2,
|
|
4208
|
-
len = uint32[pos32 +
|
|
4223
|
+
len = uint32[pos32 + 2];
|
|
4209
4224
|
pos = uint32[pos32];
|
|
4210
4225
|
for (let i = 0; i < len; i++) {
|
|
4211
4226
|
arr.push(deserializeDirective(pos));
|
|
@@ -4217,7 +4232,7 @@ function deserializeVecDirective(pos) {
|
|
|
4217
4232
|
function deserializeVecStatement(pos) {
|
|
4218
4233
|
const arr = [],
|
|
4219
4234
|
pos32 = pos >> 2,
|
|
4220
|
-
len = uint32[pos32 +
|
|
4235
|
+
len = uint32[pos32 + 2];
|
|
4221
4236
|
pos = uint32[pos32];
|
|
4222
4237
|
for (let i = 0; i < len; i++) {
|
|
4223
4238
|
arr.push(deserializeStatement(pos));
|
|
@@ -4404,7 +4419,7 @@ function deserializeOptionSymbolId(pos) {
|
|
|
4404
4419
|
function deserializeVecArrayExpressionElement(pos) {
|
|
4405
4420
|
const arr = [],
|
|
4406
4421
|
pos32 = pos >> 2,
|
|
4407
|
-
len = uint32[pos32 +
|
|
4422
|
+
len = uint32[pos32 + 2];
|
|
4408
4423
|
pos = uint32[pos32];
|
|
4409
4424
|
for (let i = 0; i < len; i++) {
|
|
4410
4425
|
arr.push(deserializeArrayExpressionElement(pos));
|
|
@@ -4420,7 +4435,7 @@ function deserializeBoxSpreadElement(pos) {
|
|
|
4420
4435
|
function deserializeVecObjectPropertyKind(pos) {
|
|
4421
4436
|
const arr = [],
|
|
4422
4437
|
pos32 = pos >> 2,
|
|
4423
|
-
len = uint32[pos32 +
|
|
4438
|
+
len = uint32[pos32 + 2];
|
|
4424
4439
|
pos = uint32[pos32];
|
|
4425
4440
|
for (let i = 0; i < len; i++) {
|
|
4426
4441
|
arr.push(deserializeObjectPropertyKind(pos));
|
|
@@ -4448,7 +4463,7 @@ function deserializeBoxPrivateIdentifier(pos) {
|
|
|
4448
4463
|
function deserializeVecTemplateElement(pos) {
|
|
4449
4464
|
const arr = [],
|
|
4450
4465
|
pos32 = pos >> 2,
|
|
4451
|
-
len = uint32[pos32 +
|
|
4466
|
+
len = uint32[pos32 + 2];
|
|
4452
4467
|
pos = uint32[pos32];
|
|
4453
4468
|
for (let i = 0; i < len; i++) {
|
|
4454
4469
|
arr.push(deserializeTemplateElement(pos));
|
|
@@ -4460,7 +4475,7 @@ function deserializeVecTemplateElement(pos) {
|
|
|
4460
4475
|
function deserializeVecExpression(pos) {
|
|
4461
4476
|
const arr = [],
|
|
4462
4477
|
pos32 = pos >> 2,
|
|
4463
|
-
len = uint32[pos32 +
|
|
4478
|
+
len = uint32[pos32 + 2];
|
|
4464
4479
|
pos = uint32[pos32];
|
|
4465
4480
|
for (let i = 0; i < len; i++) {
|
|
4466
4481
|
arr.push(deserializeExpression(pos));
|
|
@@ -4498,7 +4513,7 @@ function deserializeBoxPrivateFieldExpression(pos) {
|
|
|
4498
4513
|
function deserializeVecArgument(pos) {
|
|
4499
4514
|
const arr = [],
|
|
4500
4515
|
pos32 = pos >> 2,
|
|
4501
|
-
len = uint32[pos32 +
|
|
4516
|
+
len = uint32[pos32 + 2];
|
|
4502
4517
|
pos = uint32[pos32];
|
|
4503
4518
|
for (let i = 0; i < len; i++) {
|
|
4504
4519
|
arr.push(deserializeArgument(pos));
|
|
@@ -4523,7 +4538,7 @@ function deserializeOptionAssignmentTargetMaybeDefault(pos) {
|
|
|
4523
4538
|
function deserializeVecOptionAssignmentTargetMaybeDefault(pos) {
|
|
4524
4539
|
const arr = [],
|
|
4525
4540
|
pos32 = pos >> 2,
|
|
4526
|
-
len = uint32[pos32 +
|
|
4541
|
+
len = uint32[pos32 + 2];
|
|
4527
4542
|
pos = uint32[pos32];
|
|
4528
4543
|
for (let i = 0; i < len; i++) {
|
|
4529
4544
|
arr.push(deserializeOptionAssignmentTargetMaybeDefault(pos));
|
|
@@ -4540,7 +4555,7 @@ function deserializeOptionAssignmentTargetRest(pos) {
|
|
|
4540
4555
|
function deserializeVecAssignmentTargetProperty(pos) {
|
|
4541
4556
|
const arr = [],
|
|
4542
4557
|
pos32 = pos >> 2,
|
|
4543
|
-
len = uint32[pos32 +
|
|
4558
|
+
len = uint32[pos32 + 2];
|
|
4544
4559
|
pos = uint32[pos32];
|
|
4545
4560
|
for (let i = 0; i < len; i++) {
|
|
4546
4561
|
arr.push(deserializeAssignmentTargetProperty(pos));
|
|
@@ -4665,11 +4680,11 @@ function deserializeBoxTSImportEqualsDeclaration(pos) {
|
|
|
4665
4680
|
function deserializeVecVariableDeclarator(pos) {
|
|
4666
4681
|
const arr = [],
|
|
4667
4682
|
pos32 = pos >> 2,
|
|
4668
|
-
len = uint32[pos32 +
|
|
4683
|
+
len = uint32[pos32 + 2];
|
|
4669
4684
|
pos = uint32[pos32];
|
|
4670
4685
|
for (let i = 0; i < len; i++) {
|
|
4671
4686
|
arr.push(deserializeVariableDeclarator(pos));
|
|
4672
|
-
pos +=
|
|
4687
|
+
pos += 64;
|
|
4673
4688
|
}
|
|
4674
4689
|
return arr;
|
|
4675
4690
|
}
|
|
@@ -4692,11 +4707,11 @@ function deserializeOptionLabelIdentifier(pos) {
|
|
|
4692
4707
|
function deserializeVecSwitchCase(pos) {
|
|
4693
4708
|
const arr = [],
|
|
4694
4709
|
pos32 = pos >> 2,
|
|
4695
|
-
len = uint32[pos32 +
|
|
4710
|
+
len = uint32[pos32 + 2];
|
|
4696
4711
|
pos = uint32[pos32];
|
|
4697
4712
|
for (let i = 0; i < len; i++) {
|
|
4698
4713
|
arr.push(deserializeSwitchCase(pos));
|
|
4699
|
-
pos +=
|
|
4714
|
+
pos += 48;
|
|
4700
4715
|
}
|
|
4701
4716
|
return arr;
|
|
4702
4717
|
}
|
|
@@ -4748,7 +4763,7 @@ function deserializeBoxAssignmentPattern(pos) {
|
|
|
4748
4763
|
function deserializeVecBindingProperty(pos) {
|
|
4749
4764
|
const arr = [],
|
|
4750
4765
|
pos32 = pos >> 2,
|
|
4751
|
-
len = uint32[pos32 +
|
|
4766
|
+
len = uint32[pos32 + 2];
|
|
4752
4767
|
pos = uint32[pos32];
|
|
4753
4768
|
for (let i = 0; i < len; i++) {
|
|
4754
4769
|
arr.push(deserializeBindingProperty(pos));
|
|
@@ -4774,7 +4789,7 @@ function deserializeOptionBindingPattern(pos) {
|
|
|
4774
4789
|
function deserializeVecOptionBindingPattern(pos) {
|
|
4775
4790
|
const arr = [],
|
|
4776
4791
|
pos32 = pos >> 2,
|
|
4777
|
-
len = uint32[pos32 +
|
|
4792
|
+
len = uint32[pos32 + 2];
|
|
4778
4793
|
pos = uint32[pos32];
|
|
4779
4794
|
for (let i = 0; i < len; i++) {
|
|
4780
4795
|
arr.push(deserializeOptionBindingPattern(pos));
|
|
@@ -4822,11 +4837,11 @@ function deserializeOptionBoxFunctionBody(pos) {
|
|
|
4822
4837
|
function deserializeVecFormalParameter(pos) {
|
|
4823
4838
|
const arr = [],
|
|
4824
4839
|
pos32 = pos >> 2,
|
|
4825
|
-
len = uint32[pos32 +
|
|
4840
|
+
len = uint32[pos32 + 2];
|
|
4826
4841
|
pos = uint32[pos32];
|
|
4827
4842
|
for (let i = 0; i < len; i++) {
|
|
4828
4843
|
arr.push(deserializeFormalParameter(pos));
|
|
4829
|
-
pos +=
|
|
4844
|
+
pos += 72;
|
|
4830
4845
|
}
|
|
4831
4846
|
return arr;
|
|
4832
4847
|
}
|
|
@@ -4834,7 +4849,7 @@ function deserializeVecFormalParameter(pos) {
|
|
|
4834
4849
|
function deserializeVecDecorator(pos) {
|
|
4835
4850
|
const arr = [],
|
|
4836
4851
|
pos32 = pos >> 2,
|
|
4837
|
-
len = uint32[pos32 +
|
|
4852
|
+
len = uint32[pos32 + 2];
|
|
4838
4853
|
pos = uint32[pos32];
|
|
4839
4854
|
for (let i = 0; i < len; i++) {
|
|
4840
4855
|
arr.push(deserializeDecorator(pos));
|
|
@@ -4851,7 +4866,7 @@ function deserializeOptionTSAccessibility(pos) {
|
|
|
4851
4866
|
function deserializeVecTSClassImplements(pos) {
|
|
4852
4867
|
const arr = [],
|
|
4853
4868
|
pos32 = pos >> 2,
|
|
4854
|
-
len = uint32[pos32 +
|
|
4869
|
+
len = uint32[pos32 + 2];
|
|
4855
4870
|
pos = uint32[pos32];
|
|
4856
4871
|
for (let i = 0; i < len; i++) {
|
|
4857
4872
|
arr.push(deserializeTSClassImplements(pos));
|
|
@@ -4867,7 +4882,7 @@ function deserializeBoxClassBody(pos) {
|
|
|
4867
4882
|
function deserializeVecClassElement(pos) {
|
|
4868
4883
|
const arr = [],
|
|
4869
4884
|
pos32 = pos >> 2,
|
|
4870
|
-
len = uint32[pos32 +
|
|
4885
|
+
len = uint32[pos32 + 2];
|
|
4871
4886
|
pos = uint32[pos32];
|
|
4872
4887
|
for (let i = 0; i < len; i++) {
|
|
4873
4888
|
arr.push(deserializeClassElement(pos));
|
|
@@ -4928,7 +4943,7 @@ function deserializeOptionImportPhase(pos) {
|
|
|
4928
4943
|
function deserializeVecImportDeclarationSpecifier(pos) {
|
|
4929
4944
|
const arr = [],
|
|
4930
4945
|
pos32 = pos >> 2,
|
|
4931
|
-
len = uint32[pos32 +
|
|
4946
|
+
len = uint32[pos32 + 2];
|
|
4932
4947
|
pos = uint32[pos32];
|
|
4933
4948
|
for (let i = 0; i < len; i++) {
|
|
4934
4949
|
arr.push(deserializeImportDeclarationSpecifier(pos));
|
|
@@ -4966,7 +4981,7 @@ function deserializeBoxImportNamespaceSpecifier(pos) {
|
|
|
4966
4981
|
function deserializeVecImportAttribute(pos) {
|
|
4967
4982
|
const arr = [],
|
|
4968
4983
|
pos32 = pos >> 2,
|
|
4969
|
-
len = uint32[pos32 +
|
|
4984
|
+
len = uint32[pos32 + 2];
|
|
4970
4985
|
pos = uint32[pos32];
|
|
4971
4986
|
for (let i = 0; i < len; i++) {
|
|
4972
4987
|
arr.push(deserializeImportAttribute(pos));
|
|
@@ -4983,7 +4998,7 @@ function deserializeOptionDeclaration(pos) {
|
|
|
4983
4998
|
function deserializeVecExportSpecifier(pos) {
|
|
4984
4999
|
const arr = [],
|
|
4985
5000
|
pos32 = pos >> 2,
|
|
4986
|
-
len = uint32[pos32 +
|
|
5001
|
+
len = uint32[pos32 + 2];
|
|
4987
5002
|
pos = uint32[pos32];
|
|
4988
5003
|
for (let i = 0; i < len; i++) {
|
|
4989
5004
|
arr.push(deserializeExportSpecifier(pos));
|
|
@@ -5026,7 +5041,7 @@ function deserializeBoxJSXOpeningElement(pos) {
|
|
|
5026
5041
|
function deserializeVecJSXChild(pos) {
|
|
5027
5042
|
const arr = [],
|
|
5028
5043
|
pos32 = pos >> 2,
|
|
5029
|
-
len = uint32[pos32 +
|
|
5044
|
+
len = uint32[pos32 + 2];
|
|
5030
5045
|
pos = uint32[pos32];
|
|
5031
5046
|
for (let i = 0; i < len; i++) {
|
|
5032
5047
|
arr.push(deserializeJSXChild(pos));
|
|
@@ -5047,7 +5062,7 @@ function deserializeOptionBoxJSXClosingElement(pos) {
|
|
|
5047
5062
|
function deserializeVecJSXAttributeItem(pos) {
|
|
5048
5063
|
const arr = [],
|
|
5049
5064
|
pos32 = pos >> 2,
|
|
5050
|
-
len = uint32[pos32 +
|
|
5065
|
+
len = uint32[pos32 + 2];
|
|
5051
5066
|
pos = uint32[pos32];
|
|
5052
5067
|
for (let i = 0; i < len; i++) {
|
|
5053
5068
|
arr.push(deserializeJSXAttributeItem(pos));
|
|
@@ -5096,7 +5111,7 @@ function deserializeBoxJSXSpreadChild(pos) {
|
|
|
5096
5111
|
function deserializeVecTSEnumMember(pos) {
|
|
5097
5112
|
const arr = [],
|
|
5098
5113
|
pos32 = pos >> 2,
|
|
5099
|
-
len = uint32[pos32 +
|
|
5114
|
+
len = uint32[pos32 + 2];
|
|
5100
5115
|
pos = uint32[pos32];
|
|
5101
5116
|
for (let i = 0; i < len; i++) {
|
|
5102
5117
|
arr.push(deserializeTSEnumMember(pos));
|
|
@@ -5256,7 +5271,7 @@ function deserializeBoxJSDocUnknownType(pos) {
|
|
|
5256
5271
|
function deserializeVecTSType(pos) {
|
|
5257
5272
|
const arr = [],
|
|
5258
5273
|
pos32 = pos >> 2,
|
|
5259
|
-
len = uint32[pos32 +
|
|
5274
|
+
len = uint32[pos32 + 2];
|
|
5260
5275
|
pos = uint32[pos32];
|
|
5261
5276
|
for (let i = 0; i < len; i++) {
|
|
5262
5277
|
arr.push(deserializeTSType(pos));
|
|
@@ -5268,7 +5283,7 @@ function deserializeVecTSType(pos) {
|
|
|
5268
5283
|
function deserializeVecTSTupleElement(pos) {
|
|
5269
5284
|
const arr = [],
|
|
5270
5285
|
pos32 = pos >> 2,
|
|
5271
|
-
len = uint32[pos32 +
|
|
5286
|
+
len = uint32[pos32 + 2];
|
|
5272
5287
|
pos = uint32[pos32];
|
|
5273
5288
|
for (let i = 0; i < len; i++) {
|
|
5274
5289
|
arr.push(deserializeTSTupleElement(pos));
|
|
@@ -5297,7 +5312,7 @@ function deserializeOptionTSType(pos) {
|
|
|
5297
5312
|
function deserializeVecTSTypeParameter(pos) {
|
|
5298
5313
|
const arr = [],
|
|
5299
5314
|
pos32 = pos >> 2,
|
|
5300
|
-
len = uint32[pos32 +
|
|
5315
|
+
len = uint32[pos32 + 2];
|
|
5301
5316
|
pos = uint32[pos32];
|
|
5302
5317
|
for (let i = 0; i < len; i++) {
|
|
5303
5318
|
arr.push(deserializeTSTypeParameter(pos));
|
|
@@ -5309,7 +5324,7 @@ function deserializeVecTSTypeParameter(pos) {
|
|
|
5309
5324
|
function deserializeVecTSInterfaceHeritage(pos) {
|
|
5310
5325
|
const arr = [],
|
|
5311
5326
|
pos32 = pos >> 2,
|
|
5312
|
-
len = uint32[pos32 +
|
|
5327
|
+
len = uint32[pos32 + 2];
|
|
5313
5328
|
pos = uint32[pos32];
|
|
5314
5329
|
for (let i = 0; i < len; i++) {
|
|
5315
5330
|
arr.push(deserializeTSInterfaceHeritage(pos));
|
|
@@ -5325,7 +5340,7 @@ function deserializeBoxTSInterfaceBody(pos) {
|
|
|
5325
5340
|
function deserializeVecTSSignature(pos) {
|
|
5326
5341
|
const arr = [],
|
|
5327
5342
|
pos32 = pos >> 2,
|
|
5328
|
-
len = uint32[pos32 +
|
|
5343
|
+
len = uint32[pos32 + 2];
|
|
5329
5344
|
pos = uint32[pos32];
|
|
5330
5345
|
for (let i = 0; i < len; i++) {
|
|
5331
5346
|
arr.push(deserializeTSSignature(pos));
|
|
@@ -5353,7 +5368,7 @@ function deserializeBoxTSMethodSignature(pos) {
|
|
|
5353
5368
|
function deserializeVecTSIndexSignatureName(pos) {
|
|
5354
5369
|
const arr = [],
|
|
5355
5370
|
pos32 = pos >> 2,
|
|
5356
|
-
len = uint32[pos32 +
|
|
5371
|
+
len = uint32[pos32 + 2];
|
|
5357
5372
|
pos = uint32[pos32];
|
|
5358
5373
|
for (let i = 0; i < len; i++) {
|
|
5359
5374
|
arr.push(deserializeTSIndexSignatureName(pos));
|
|
@@ -5399,18 +5414,18 @@ function deserializeU32(pos) {
|
|
|
5399
5414
|
}
|
|
5400
5415
|
|
|
5401
5416
|
function deserializeOptionNameSpan(pos) {
|
|
5402
|
-
if (uint32[pos >> 2] === 0 && uint32[(pos +
|
|
5417
|
+
if (uint32[(pos + 8) >> 2] === 0 && uint32[(pos + 12) >> 2] === 0) return null;
|
|
5403
5418
|
return deserializeNameSpan(pos);
|
|
5404
5419
|
}
|
|
5405
5420
|
|
|
5406
5421
|
function deserializeVecAlternative(pos) {
|
|
5407
5422
|
const arr = [],
|
|
5408
5423
|
pos32 = pos >> 2,
|
|
5409
|
-
len = uint32[pos32 +
|
|
5424
|
+
len = uint32[pos32 + 2];
|
|
5410
5425
|
pos = uint32[pos32];
|
|
5411
5426
|
for (let i = 0; i < len; i++) {
|
|
5412
5427
|
arr.push(deserializeAlternative(pos));
|
|
5413
|
-
pos +=
|
|
5428
|
+
pos += 32;
|
|
5414
5429
|
}
|
|
5415
5430
|
return arr;
|
|
5416
5431
|
}
|
|
@@ -5418,7 +5433,7 @@ function deserializeVecAlternative(pos) {
|
|
|
5418
5433
|
function deserializeVecTerm(pos) {
|
|
5419
5434
|
const arr = [],
|
|
5420
5435
|
pos32 = pos >> 2,
|
|
5421
|
-
len = uint32[pos32 +
|
|
5436
|
+
len = uint32[pos32 + 2];
|
|
5422
5437
|
pos = uint32[pos32];
|
|
5423
5438
|
for (let i = 0; i < len; i++) {
|
|
5424
5439
|
arr.push(deserializeTerm(pos));
|
|
@@ -5484,7 +5499,7 @@ function deserializeOptionU64(pos) {
|
|
|
5484
5499
|
function deserializeVecCharacterClassContents(pos) {
|
|
5485
5500
|
const arr = [],
|
|
5486
5501
|
pos32 = pos >> 2,
|
|
5487
|
-
len = uint32[pos32 +
|
|
5502
|
+
len = uint32[pos32 + 2];
|
|
5488
5503
|
pos = uint32[pos32];
|
|
5489
5504
|
for (let i = 0; i < len; i++) {
|
|
5490
5505
|
arr.push(deserializeCharacterClassContents(pos));
|
|
@@ -5504,11 +5519,11 @@ function deserializeBoxClassStringDisjunction(pos) {
|
|
|
5504
5519
|
function deserializeVecClassString(pos) {
|
|
5505
5520
|
const arr = [],
|
|
5506
5521
|
pos32 = pos >> 2,
|
|
5507
|
-
len = uint32[pos32 +
|
|
5522
|
+
len = uint32[pos32 + 2];
|
|
5508
5523
|
pos = uint32[pos32];
|
|
5509
5524
|
for (let i = 0; i < len; i++) {
|
|
5510
5525
|
arr.push(deserializeClassString(pos));
|
|
5511
|
-
pos +=
|
|
5526
|
+
pos += 40;
|
|
5512
5527
|
}
|
|
5513
5528
|
return arr;
|
|
5514
5529
|
}
|
|
@@ -5516,7 +5531,7 @@ function deserializeVecClassString(pos) {
|
|
|
5516
5531
|
function deserializeVecCharacter(pos) {
|
|
5517
5532
|
const arr = [],
|
|
5518
5533
|
pos32 = pos >> 2,
|
|
5519
|
-
len = uint32[pos32 +
|
|
5534
|
+
len = uint32[pos32 + 2];
|
|
5520
5535
|
pos = uint32[pos32];
|
|
5521
5536
|
for (let i = 0; i < len; i++) {
|
|
5522
5537
|
arr.push(deserializeCharacter(pos));
|
|
@@ -5526,23 +5541,18 @@ function deserializeVecCharacter(pos) {
|
|
|
5526
5541
|
}
|
|
5527
5542
|
|
|
5528
5543
|
function deserializeOptionModifiers(pos) {
|
|
5529
|
-
if (uint8[pos
|
|
5530
|
-
return deserializeModifiers(pos);
|
|
5531
|
-
}
|
|
5532
|
-
|
|
5533
|
-
function deserializeOptionModifier(pos) {
|
|
5534
|
-
if (uint8[pos] === 2) return null;
|
|
5535
|
-
return deserializeModifier(pos);
|
|
5544
|
+
if (uint8[pos] === 0) return null;
|
|
5545
|
+
return deserializeModifiers(pos + 8);
|
|
5536
5546
|
}
|
|
5537
5547
|
|
|
5538
5548
|
function deserializeVecError(pos) {
|
|
5539
5549
|
const arr = [],
|
|
5540
5550
|
pos32 = pos >> 2,
|
|
5541
|
-
len = uint32[pos32 +
|
|
5551
|
+
len = uint32[pos32 + 2];
|
|
5542
5552
|
pos = uint32[pos32];
|
|
5543
5553
|
for (let i = 0; i < len; i++) {
|
|
5544
5554
|
arr.push(deserializeError(pos));
|
|
5545
|
-
pos +=
|
|
5555
|
+
pos += 64;
|
|
5546
5556
|
}
|
|
5547
5557
|
return arr;
|
|
5548
5558
|
}
|
|
@@ -5550,7 +5560,7 @@ function deserializeVecError(pos) {
|
|
|
5550
5560
|
function deserializeVecErrorLabel(pos) {
|
|
5551
5561
|
const arr = [],
|
|
5552
5562
|
pos32 = pos >> 2,
|
|
5553
|
-
len = uint32[pos32 +
|
|
5563
|
+
len = uint32[pos32 + 2];
|
|
5554
5564
|
pos = uint32[pos32];
|
|
5555
5565
|
for (let i = 0; i < len; i++) {
|
|
5556
5566
|
arr.push(deserializeErrorLabel(pos));
|
|
@@ -5562,11 +5572,11 @@ function deserializeVecErrorLabel(pos) {
|
|
|
5562
5572
|
function deserializeVecStaticImport(pos) {
|
|
5563
5573
|
const arr = [],
|
|
5564
5574
|
pos32 = pos >> 2,
|
|
5565
|
-
len = uint32[pos32 +
|
|
5575
|
+
len = uint32[pos32 + 2];
|
|
5566
5576
|
pos = uint32[pos32];
|
|
5567
5577
|
for (let i = 0; i < len; i++) {
|
|
5568
5578
|
arr.push(deserializeStaticImport(pos));
|
|
5569
|
-
pos +=
|
|
5579
|
+
pos += 56;
|
|
5570
5580
|
}
|
|
5571
5581
|
return arr;
|
|
5572
5582
|
}
|
|
@@ -5574,11 +5584,11 @@ function deserializeVecStaticImport(pos) {
|
|
|
5574
5584
|
function deserializeVecStaticExport(pos) {
|
|
5575
5585
|
const arr = [],
|
|
5576
5586
|
pos32 = pos >> 2,
|
|
5577
|
-
len = uint32[pos32 +
|
|
5587
|
+
len = uint32[pos32 + 2];
|
|
5578
5588
|
pos = uint32[pos32];
|
|
5579
5589
|
for (let i = 0; i < len; i++) {
|
|
5580
5590
|
arr.push(deserializeStaticExport(pos));
|
|
5581
|
-
pos +=
|
|
5591
|
+
pos += 32;
|
|
5582
5592
|
}
|
|
5583
5593
|
return arr;
|
|
5584
5594
|
}
|
|
@@ -5586,7 +5596,7 @@ function deserializeVecStaticExport(pos) {
|
|
|
5586
5596
|
function deserializeVecDynamicImport(pos) {
|
|
5587
5597
|
const arr = [],
|
|
5588
5598
|
pos32 = pos >> 2,
|
|
5589
|
-
len = uint32[pos32 +
|
|
5599
|
+
len = uint32[pos32 + 2];
|
|
5590
5600
|
pos = uint32[pos32];
|
|
5591
5601
|
for (let i = 0; i < len; i++) {
|
|
5592
5602
|
arr.push(deserializeDynamicImport(pos));
|
|
@@ -5598,7 +5608,7 @@ function deserializeVecDynamicImport(pos) {
|
|
|
5598
5608
|
function deserializeVecSpan(pos) {
|
|
5599
5609
|
const arr = [],
|
|
5600
5610
|
pos32 = pos >> 2,
|
|
5601
|
-
len = uint32[pos32 +
|
|
5611
|
+
len = uint32[pos32 + 2];
|
|
5602
5612
|
pos = uint32[pos32];
|
|
5603
5613
|
for (let i = 0; i < len; i++) {
|
|
5604
5614
|
arr.push(deserializeSpan(pos));
|
|
@@ -5610,7 +5620,7 @@ function deserializeVecSpan(pos) {
|
|
|
5610
5620
|
function deserializeVecImportEntry(pos) {
|
|
5611
5621
|
const arr = [],
|
|
5612
5622
|
pos32 = pos >> 2,
|
|
5613
|
-
len = uint32[pos32 +
|
|
5623
|
+
len = uint32[pos32 + 2];
|
|
5614
5624
|
pos = uint32[pos32];
|
|
5615
5625
|
for (let i = 0; i < len; i++) {
|
|
5616
5626
|
arr.push(deserializeImportEntry(pos));
|
|
@@ -5622,7 +5632,7 @@ function deserializeVecImportEntry(pos) {
|
|
|
5622
5632
|
function deserializeVecExportEntry(pos) {
|
|
5623
5633
|
const arr = [],
|
|
5624
5634
|
pos32 = pos >> 2,
|
|
5625
|
-
len = uint32[pos32 +
|
|
5635
|
+
len = uint32[pos32 + 2];
|
|
5626
5636
|
pos = uint32[pos32];
|
|
5627
5637
|
for (let i = 0; i < len; i++) {
|
|
5628
5638
|
arr.push(deserializeExportEntry(pos));
|