@artel/artc 0.6.25222 → 0.6.25224
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/build/Cli.js +3 -3
- package/build/api/Api.js +12 -2
- package/build/api/ApiNodeJS.js +3 -3
- package/build/api/ApiServices.js +635 -532
- package/build/{chunk-ODWG5ZXF.js → chunk-24QZJOMF.js} +4477 -3240
- package/build/{chunk-MBMOAUK7.js → chunk-62KHK23H.js} +2 -2
- package/build/{chunk-UZK7JCND.js → chunk-Y6DODJCG.js} +1 -1
- package/build/types/analysis/AnalyzedTranslationPackage.d.ts +1 -0
- package/build/types/analysis/Analyzer.d.ts +17 -11
- package/build/types/analysis/DiagnosticCollector.d.ts +1 -1
- package/build/types/analysis/ImportedPackageNameTree.d.ts +1 -0
- package/build/types/analysis/LocalizationContext.d.ts +2 -2
- package/build/types/analysis/Lookup.d.ts +4 -4
- package/build/types/analysis/NamedTypeResolver.d.ts +5 -1
- package/build/types/analysis/NamedTypeSpecifierResolver.d.ts +4 -1
- package/build/types/analysis/PropertyAccessExpressionMeaning.d.ts +9 -3
- package/build/types/analysis/Scope.d.ts +21 -44
- package/build/types/analysis/SemanticContext.d.ts +14 -1
- package/build/types/analysis/SemanticContextBuilder.d.ts +1 -0
- package/build/types/analysis/StatementBlockScopeBuilder.d.ts +1 -0
- package/build/types/analysis/TagMeaning.d.ts +4 -1
- package/build/types/analysis/TypeMemberLookup.d.ts +39 -11
- package/build/types/analysis/TypeNarrower.d.ts +49 -14
- package/build/types/analysis/Utils.d.ts +12 -0
- package/build/types/analysis/control-flow/GraphBuilder.d.ts +43 -0
- package/build/types/analysis/{ControlFlowGraphVisualizer.d.ts → control-flow/GraphVisualizer.d.ts} +3 -3
- package/build/types/analysis/control-flow/NarrowableExpression.d.ts +5 -0
- package/build/types/analysis/control-flow/Nodes.d.ts +91 -0
- package/build/types/analysis/control-flow/index.d.ts +4 -0
- package/build/types/common/HelperPhrases.d.ts +3 -2
- package/build/types/diagnostic/DiagnosticCode.d.ts +5 -5
- package/build/types/emitter/Entities.d.ts +5 -4
- package/build/types/emitter/ir/Nodes.d.ts +2 -2
- package/build/types/entities/index.d.ts +3 -0
- package/build/types/parser/Scanner.d.ts +1 -2
- package/build/types/services/CompletionService.d.ts +0 -1
- package/build/types/services/DisplayService.d.ts +11 -8
- package/build/types/services/NodeSemanticInfo.d.ts +11 -6
- package/build/types/services/source-generation/EntityToSyntax.d.ts +1 -0
- package/build/types/tree/NodeKind.d.ts +146 -144
- package/build/types/tree/green/Nodes.d.ts +28 -10
- package/build/types/tree/green/SyntaxFactory.d.ts +1 -0
- package/build/types/tree/green/SyntaxToCode.d.ts +5 -1
- package/build/types/tree/red/Nodes.d.ts +33 -8
- package/build/types/ts-interop/TsInteropContext.d.ts +1 -0
- package/build/types/types/IntersectionType.d.ts +20 -0
- package/build/types/types/ParameterType.d.ts +6 -3
- package/build/types/types/Type.d.ts +2 -1
- package/build/types/types/TypeFactory.d.ts +4 -1
- package/build/types/types/TypeMembers.d.ts +5 -0
- package/build/types/types/index.d.ts +1 -0
- package/package.json +1 -1
- package/build/types/analysis/ControlFlowGraphBuilder.d.ts +0 -121
@@ -12,148 +12,150 @@ export declare enum NodeKind {
|
|
12
12
|
NamedTypeSpecifier = 10,
|
13
13
|
UnionTypeSpecifier = 11,
|
14
14
|
UnionTypeSpecifierTypeList = 12,
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
|
71
|
-
|
72
|
-
|
73
|
-
|
74
|
-
|
75
|
-
|
76
|
-
|
77
|
-
|
78
|
-
|
79
|
-
|
80
|
-
|
81
|
-
|
82
|
-
|
83
|
-
|
84
|
-
|
85
|
-
|
86
|
-
|
87
|
-
|
88
|
-
|
89
|
-
|
90
|
-
|
91
|
-
|
92
|
-
|
93
|
-
|
94
|
-
|
95
|
-
|
96
|
-
|
97
|
-
|
98
|
-
|
99
|
-
|
100
|
-
|
101
|
-
|
102
|
-
|
103
|
-
|
104
|
-
|
105
|
-
|
106
|
-
|
107
|
-
|
108
|
-
|
109
|
-
|
110
|
-
|
111
|
-
|
112
|
-
|
113
|
-
|
114
|
-
|
115
|
-
|
116
|
-
|
117
|
-
|
118
|
-
|
119
|
-
|
120
|
-
|
121
|
-
|
122
|
-
|
123
|
-
|
124
|
-
|
125
|
-
|
126
|
-
|
127
|
-
|
128
|
-
|
129
|
-
|
130
|
-
|
131
|
-
|
132
|
-
|
133
|
-
|
134
|
-
|
135
|
-
|
136
|
-
|
137
|
-
|
138
|
-
|
139
|
-
|
140
|
-
|
141
|
-
|
142
|
-
|
143
|
-
|
144
|
-
|
145
|
-
|
146
|
-
|
147
|
-
|
148
|
-
|
149
|
-
|
150
|
-
|
151
|
-
|
152
|
-
|
153
|
-
|
154
|
-
|
155
|
-
|
156
|
-
|
157
|
-
|
158
|
-
|
15
|
+
IntersectionTypeSpecifier = 13,
|
16
|
+
IntersectionTypeSpecifierTypeList = 14,
|
17
|
+
ParenthesizedTypeSpecifier = 15,
|
18
|
+
NullableTypeSpecifier = 16,
|
19
|
+
AnonymousTypeSpecifier = 17,
|
20
|
+
InvalidTypeSpecifier = 18,
|
21
|
+
AnonymousMethodTypeDeclaration = 19,
|
22
|
+
AnonymousStructuredTypeDeclaration = 20,
|
23
|
+
AnonymousVariantTypeDeclaration = 21,
|
24
|
+
TopLevelTranslationList = 22,
|
25
|
+
TranslationsDeclaration = 23,
|
26
|
+
PackageAliasTypeDeclaration = 24,
|
27
|
+
AliasTypeDeclarationBody = 25,
|
28
|
+
PackageMemberGroupDeclaration = 26,
|
29
|
+
PackageConstructorDeclaration = 27,
|
30
|
+
PackageEntryPointDeclaration = 28,
|
31
|
+
PackageMethodDeclaration = 29,
|
32
|
+
PackageMethodTypeDeclaration = 30,
|
33
|
+
MethodTypeDeclarationBody = 31,
|
34
|
+
BaseTypeList = 32,
|
35
|
+
TypeMemberDeclarationList = 33,
|
36
|
+
TypeMemberDeclarationBlock = 34,
|
37
|
+
PackageStructuredTypeDeclaration = 35,
|
38
|
+
StructuredTypeDeclarationBody = 36,
|
39
|
+
PackageVariableDeclaration = 37,
|
40
|
+
PackageVariableGetterDeclaration = 38,
|
41
|
+
PackageVariableSetterDeclaration = 39,
|
42
|
+
PackageVariantTypeDeclaration = 40,
|
43
|
+
VariantTypeDeclarationBody = 41,
|
44
|
+
TypeExtensionDeclaration = 42,
|
45
|
+
ExtendedTypeClauseCommaList = 43,
|
46
|
+
ExtendedTypeClause = 44,
|
47
|
+
InvalidPackageMemberDeclaration = 45,
|
48
|
+
TypeMemberGroupDeclaration = 46,
|
49
|
+
TypeConstructorDeclaration = 47,
|
50
|
+
TypeDestructorDeclaration = 48,
|
51
|
+
TypeIndexedGetterDeclaration = 49,
|
52
|
+
TypeIndexedSetterDeclaration = 50,
|
53
|
+
TypeIndexerParameterClause = 51,
|
54
|
+
TypeDereferencedVariableGetterDeclaration = 52,
|
55
|
+
TypeDereferencedVariableSetterDeclaration = 53,
|
56
|
+
TypeMethodDeclaration = 54,
|
57
|
+
OperatorDeclaration = 55,
|
58
|
+
TypeVariableDeclaration = 56,
|
59
|
+
TypeVariableGetterDeclaration = 57,
|
60
|
+
TypeVariableSetterDeclaration = 58,
|
61
|
+
InvalidTypeMemberDeclaration = 59,
|
62
|
+
NestedMethodDeclaration = 60,
|
63
|
+
LocalVariableDeclaration = 61,
|
64
|
+
EnumerationVariableDeclaration = 62,
|
65
|
+
ArrayLiteral = 63,
|
66
|
+
ArrayLiteralElementList = 64,
|
67
|
+
AssertionExpression = 65,
|
68
|
+
AssumptionExpression = 66,
|
69
|
+
AsExpression = 67,
|
70
|
+
BinaryExpression = 68,
|
71
|
+
MethodBlockLiteral = 69,
|
72
|
+
ArgumentList = 70,
|
73
|
+
CallExpression = 71,
|
74
|
+
AutotypeCallExpression = 72,
|
75
|
+
IndexedAccessExpression = 73,
|
76
|
+
InvalidExpression = 74,
|
77
|
+
IsExpression = 75,
|
78
|
+
MethodLiteral = 76,
|
79
|
+
ParenthesizedExpression = 77,
|
80
|
+
WhenTernaryExpression = 78,
|
81
|
+
PrefixUnaryExpression = 79,
|
82
|
+
PropertyAccessExpression = 80,
|
83
|
+
ReferenceExpression = 81,
|
84
|
+
DereferenceExpression = 82,
|
85
|
+
TextTemplateLiteral = 83,
|
86
|
+
TextTemplateSpanList = 84,
|
87
|
+
TextTemplateSpan = 85,
|
88
|
+
TokenExpression = 86,
|
89
|
+
KeywordExpression = 87,
|
90
|
+
ObjectExpression = 88,
|
91
|
+
BaseExpression = 89,
|
92
|
+
IdentifierExpression = 90,
|
93
|
+
GenericSpecializationExpression = 91,
|
94
|
+
DefaultMatchExpression = 92,
|
95
|
+
AssignmentStatement = 93,
|
96
|
+
StatementList = 94,
|
97
|
+
StatementBlock = 95,
|
98
|
+
FunctionBlock = 96,
|
99
|
+
BreakLoopStatement = 97,
|
100
|
+
ContinueLoopStatement = 98,
|
101
|
+
DisposeStatement = 99,
|
102
|
+
RunStatement = 100,
|
103
|
+
TryStatement = 101,
|
104
|
+
CatchClause = 102,
|
105
|
+
ErrorVariableDeclaration = 103,
|
106
|
+
FinallyClause = 104,
|
107
|
+
EmptyStatement = 105,
|
108
|
+
ErrorStatement = 106,
|
109
|
+
ImportantStatement = 107,
|
110
|
+
ExpressionStatement = 108,
|
111
|
+
EnumerationVariableList = 109,
|
112
|
+
ForStatement = 110,
|
113
|
+
IfStatement = 111,
|
114
|
+
ElseIfClauseList = 112,
|
115
|
+
ElseIfClause = 113,
|
116
|
+
ElseClause = 114,
|
117
|
+
InvalidStatement = 115,
|
118
|
+
NestedMethodDeclarationStatement = 116,
|
119
|
+
LocalVariableDeclarationStatement = 117,
|
120
|
+
LoopStatement = 118,
|
121
|
+
ReturnStatement = 119,
|
122
|
+
CaseClauseList = 120,
|
123
|
+
SwitchStatement = 121,
|
124
|
+
MatchExpressionList = 122,
|
125
|
+
CaseClause = 123,
|
126
|
+
WhileStatement = 124,
|
127
|
+
YieldStatement = 125,
|
128
|
+
TranslationParameterList = 126,
|
129
|
+
TranslationParameterClause = 127,
|
130
|
+
ConstructorTranslation = 128,
|
131
|
+
IndexerTranslationParameterClause = 129,
|
132
|
+
IndexerTranslation = 130,
|
133
|
+
TranslationTypeParameterList = 131,
|
134
|
+
TranslationTypeParameterClause = 132,
|
135
|
+
PackageMethodTranslation = 133,
|
136
|
+
TypeMethodTranslation = 134,
|
137
|
+
MethodTypeTranslation = 135,
|
138
|
+
PackageImportTranslation = 136,
|
139
|
+
QualifiedName = 137,
|
140
|
+
PackageVariableTranslation = 138,
|
141
|
+
TypeVariableOrVariantTranslation = 139,
|
142
|
+
TypeMemberTranslationList = 140,
|
143
|
+
TypeTranslation = 141,
|
144
|
+
TextLiteralTranslation = 142,
|
145
|
+
TextTemplateLiteralTranslation = 143,
|
146
|
+
VariantDeclaration = 144,
|
147
|
+
TypeParameterDeclaration = 145,
|
148
|
+
ParameterDeclaration = 146,
|
149
|
+
Argument = 147,
|
150
|
+
TagList = 148,
|
151
|
+
Tag = 149,
|
152
|
+
ModifierList = 150,
|
153
|
+
Modifier = 151,
|
154
|
+
ParameterClause = 152,
|
155
|
+
ParameterList = 153,
|
156
|
+
TypeArgumentClause = 154,
|
157
|
+
TypeArgumentList = 155,
|
158
|
+
TypeParameterClause = 156,
|
159
|
+
TypeParameterList = 157,
|
160
|
+
TypeAnnotation = 158
|
159
161
|
}
|
@@ -111,7 +111,7 @@ export declare class PackagePath extends BaseNode {
|
|
111
111
|
constructor(parts: readonly PackagePathPart[]);
|
112
112
|
toRed(rangeStart: number, parent: red.PackagePathParent): red.PackagePath;
|
113
113
|
}
|
114
|
-
export type TypeSpecifier = NamedTypeSpecifier | AnonymousTypeSpecifier | UnionTypeSpecifier | ParenthesizedTypeSpecifier | NullableTypeSpecifier | InvalidTypeSpecifier;
|
114
|
+
export type TypeSpecifier = NamedTypeSpecifier | AnonymousTypeSpecifier | UnionTypeSpecifier | IntersectionTypeSpecifier | ParenthesizedTypeSpecifier | NullableTypeSpecifier | InvalidTypeSpecifier;
|
115
115
|
export declare class NamedTypeSpecifier extends BaseNode {
|
116
116
|
readonly kind = NodeKind.NamedTypeSpecifier;
|
117
117
|
readonly children: readonly [
|
@@ -143,6 +143,25 @@ export declare class UnionTypeSpecifierTypeList extends BaseNode {
|
|
143
143
|
constructor(elements: readonly UnionTypeSpecifierTypeListElement[]);
|
144
144
|
toRed(rangeStart: number, parent: red.UnionTypeSpecifierTypeListParent): red.UnionTypeSpecifierTypeList;
|
145
145
|
}
|
146
|
+
export declare class IntersectionTypeSpecifier extends BaseNode {
|
147
|
+
readonly kind = NodeKind.IntersectionTypeSpecifier;
|
148
|
+
readonly children: readonly [
|
149
|
+
IntersectionTypeSpecifierTypeList
|
150
|
+
];
|
151
|
+
get typeList(): IntersectionTypeSpecifierTypeList;
|
152
|
+
protected get thisAsNode(): Node;
|
153
|
+
constructor(typeList: IntersectionTypeSpecifierTypeList);
|
154
|
+
toRed(rangeStart: number, parent: red.NonNamedTypeSpecifierParent): red.IntersectionTypeSpecifier;
|
155
|
+
}
|
156
|
+
export type IntersectionTypeSpecifierTypeListElement = TypeSpecifier | Token<TokenKind.Ampersand>;
|
157
|
+
export declare class IntersectionTypeSpecifierTypeList extends BaseNode {
|
158
|
+
readonly kind = NodeKind.IntersectionTypeSpecifierTypeList;
|
159
|
+
readonly children: readonly IntersectionTypeSpecifierTypeListElement[];
|
160
|
+
get elements(): readonly IntersectionTypeSpecifierTypeListElement[];
|
161
|
+
protected get thisAsNode(): Node;
|
162
|
+
constructor(elements: readonly IntersectionTypeSpecifierTypeListElement[]);
|
163
|
+
toRed(rangeStart: number, parent: red.IntersectionTypeSpecifierTypeListParent): red.IntersectionTypeSpecifierTypeList;
|
164
|
+
}
|
146
165
|
export declare class ParenthesizedTypeSpecifier extends BaseNode {
|
147
166
|
readonly kind = NodeKind.ParenthesizedTypeSpecifier;
|
148
167
|
readonly children: readonly [
|
@@ -1338,20 +1357,19 @@ export declare class StatementBlock extends BaseNode {
|
|
1338
1357
|
constructor(openBraceToken: Token<TokenKind.OpenBrace>, statementList: StatementList, closeBraceToken: Token<TokenKind.CloseBrace>);
|
1339
1358
|
toRed(rangeStart: number, parent: red.StatementBlockParent): red.StatementBlock;
|
1340
1359
|
}
|
1360
|
+
export type ExpressionOrStatementList = Expression | StatementList;
|
1341
1361
|
export declare class FunctionBlock extends BaseNode {
|
1342
1362
|
readonly kind = NodeKind.FunctionBlock;
|
1343
1363
|
readonly children: readonly [
|
1344
1364
|
Token<TokenKind.OpenBrace>,
|
1345
|
-
|
1346
|
-
StatementList | undefined,
|
1365
|
+
ExpressionOrStatementList,
|
1347
1366
|
Token<TokenKind.CloseBrace>
|
1348
1367
|
];
|
1349
1368
|
get openBraceToken(): Token<TokenKind.OpenBrace>;
|
1350
|
-
get
|
1351
|
-
get statementList(): StatementList | undefined;
|
1369
|
+
get expressionOrStatementList(): ExpressionOrStatementList;
|
1352
1370
|
get closeBraceToken(): Token<TokenKind.CloseBrace>;
|
1353
1371
|
protected get thisAsNode(): Node;
|
1354
|
-
constructor(openBraceToken: Token<TokenKind.OpenBrace>,
|
1372
|
+
constructor(openBraceToken: Token<TokenKind.OpenBrace>, expressionOrStatementList: ExpressionOrStatementList, closeBraceToken: Token<TokenKind.CloseBrace>);
|
1355
1373
|
toRed(rangeStart: number, parent: red.FunctionBlockParent): red.FunctionBlock;
|
1356
1374
|
}
|
1357
1375
|
export declare class BreakLoopStatement extends BaseNode {
|
@@ -1466,12 +1484,12 @@ export declare class ErrorStatement extends BaseNode {
|
|
1466
1484
|
readonly kind = NodeKind.ErrorStatement;
|
1467
1485
|
readonly children: readonly [
|
1468
1486
|
Keyword<KeywordKind.Error>,
|
1469
|
-
Expression
|
1487
|
+
Expression
|
1470
1488
|
];
|
1471
1489
|
get errorKeyword(): Keyword<KeywordKind.Error>;
|
1472
|
-
get expression(): Expression
|
1490
|
+
get expression(): Expression;
|
1473
1491
|
protected get thisAsNode(): Node;
|
1474
|
-
constructor(errorKeyword: Keyword<KeywordKind.Error>, expression: Expression
|
1492
|
+
constructor(errorKeyword: Keyword<KeywordKind.Error>, expression: Expression);
|
1475
1493
|
toRed(rangeStart: number, parent: red.ErrorStatementParent): red.ErrorStatement;
|
1476
1494
|
}
|
1477
1495
|
export declare class ImportantStatement extends BaseNode {
|
@@ -2185,4 +2203,4 @@ export declare class TypeAnnotation extends BaseNode {
|
|
2185
2203
|
constructor(colonToken: Token<TokenKind.Colon>, typeSpecifier: TypeSpecifier);
|
2186
2204
|
toRed(rangeStart: number, parent: red.TypeAnnotationParent): red.TypeAnnotation;
|
2187
2205
|
}
|
2188
|
-
export type Node = SourceFile | PackageMemberDeclarationList | Keyword | PackageImportDirectiveList | SinglePackageImportDirective | PackageGroupImportDirective | PackageImportList | PackageImport | PackagePath | NamedTypeSpecifier | UnionTypeSpecifier | UnionTypeSpecifierTypeList | ParenthesizedTypeSpecifier | NullableTypeSpecifier | AnonymousTypeSpecifier | InvalidTypeSpecifier | AnonymousMethodTypeDeclaration | AnonymousStructuredTypeDeclaration | AnonymousVariantTypeDeclaration | TopLevelTranslationList | TranslationsDeclaration | PackageAliasTypeDeclaration | AliasTypeDeclarationBody | PackageMemberGroupDeclaration | PackageConstructorDeclaration | PackageEntryPointDeclaration | PackageMethodDeclaration | PackageMethodTypeDeclaration | MethodTypeDeclarationBody | BaseTypeList | TypeMemberDeclarationList | TypeMemberDeclarationBlock | PackageStructuredTypeDeclaration | StructuredTypeDeclarationBody | PackageVariableDeclaration | PackageVariableGetterDeclaration | PackageVariableSetterDeclaration | PackageVariantTypeDeclaration | VariantTypeDeclarationBody | TypeExtensionDeclaration | ExtendedTypeClauseCommaList | ExtendedTypeClause | InvalidPackageMemberDeclaration | TypeMemberGroupDeclaration | TypeConstructorDeclaration | TypeDestructorDeclaration | TypeIndexedGetterDeclaration | TypeIndexedSetterDeclaration | TypeIndexerParameterClause | TypeDereferencedVariableGetterDeclaration | TypeDereferencedVariableSetterDeclaration | TypeMethodDeclaration | OperatorDeclaration | TypeVariableDeclaration | TypeVariableGetterDeclaration | TypeVariableSetterDeclaration | InvalidTypeMemberDeclaration | NestedMethodDeclaration | LocalVariableDeclaration | EnumerationVariableDeclaration | ArrayLiteral | ArrayLiteralElementList | AssertionExpression | AssumptionExpression | AsExpression | BinaryExpression | MethodBlockLiteral | ArgumentList | CallExpression | AutotypeCallExpression | IndexedAccessExpression | InvalidExpression | IsExpression | MethodLiteral | ParenthesizedExpression | WhenTernaryExpression | PrefixUnaryExpression | PropertyAccessExpression | ReferenceExpression | DereferenceExpression | TextTemplateLiteral | TextTemplateSpanList | TextTemplateSpan | TokenExpression | KeywordExpression | ObjectExpression | BaseExpression | IdentifierExpression | GenericSpecializationExpression | DefaultMatchExpression | AssignmentStatement | StatementList | StatementBlock | FunctionBlock | BreakLoopStatement | ContinueLoopStatement | DisposeStatement | RunStatement | TryStatement | CatchClause | ErrorVariableDeclaration | FinallyClause | EmptyStatement | ErrorStatement | ImportantStatement | ExpressionStatement | EnumerationVariableList | ForStatement | IfStatement | ElseIfClauseList | ElseIfClause | ElseClause | InvalidStatement | NestedMethodDeclarationStatement | LocalVariableDeclarationStatement | LoopStatement | ReturnStatement | CaseClauseList | SwitchStatement | MatchExpressionList | CaseClause | WhileStatement | YieldStatement | TranslationParameterList | TranslationParameterClause | ConstructorTranslation | IndexerTranslationParameterClause | IndexerTranslation | TranslationTypeParameterList | TranslationTypeParameterClause | PackageMethodTranslation | TypeMethodTranslation | MethodTypeTranslation | PackageImportTranslation | QualifiedName | PackageVariableTranslation | TypeVariableOrVariantTranslation | TypeMemberTranslationList | TypeTranslation | TextLiteralTranslation | TextTemplateLiteralTranslation | VariantDeclaration | TypeParameterDeclaration | ParameterDeclaration | Argument | TagList | Tag | ModifierList | Modifier | ParameterClause | ParameterList | TypeArgumentClause | TypeArgumentList | TypeParameterClause | TypeParameterList | TypeAnnotation | Token;
|
2206
|
+
export type Node = SourceFile | PackageMemberDeclarationList | Keyword | PackageImportDirectiveList | SinglePackageImportDirective | PackageGroupImportDirective | PackageImportList | PackageImport | PackagePath | NamedTypeSpecifier | UnionTypeSpecifier | UnionTypeSpecifierTypeList | IntersectionTypeSpecifier | IntersectionTypeSpecifierTypeList | ParenthesizedTypeSpecifier | NullableTypeSpecifier | AnonymousTypeSpecifier | InvalidTypeSpecifier | AnonymousMethodTypeDeclaration | AnonymousStructuredTypeDeclaration | AnonymousVariantTypeDeclaration | TopLevelTranslationList | TranslationsDeclaration | PackageAliasTypeDeclaration | AliasTypeDeclarationBody | PackageMemberGroupDeclaration | PackageConstructorDeclaration | PackageEntryPointDeclaration | PackageMethodDeclaration | PackageMethodTypeDeclaration | MethodTypeDeclarationBody | BaseTypeList | TypeMemberDeclarationList | TypeMemberDeclarationBlock | PackageStructuredTypeDeclaration | StructuredTypeDeclarationBody | PackageVariableDeclaration | PackageVariableGetterDeclaration | PackageVariableSetterDeclaration | PackageVariantTypeDeclaration | VariantTypeDeclarationBody | TypeExtensionDeclaration | ExtendedTypeClauseCommaList | ExtendedTypeClause | InvalidPackageMemberDeclaration | TypeMemberGroupDeclaration | TypeConstructorDeclaration | TypeDestructorDeclaration | TypeIndexedGetterDeclaration | TypeIndexedSetterDeclaration | TypeIndexerParameterClause | TypeDereferencedVariableGetterDeclaration | TypeDereferencedVariableSetterDeclaration | TypeMethodDeclaration | OperatorDeclaration | TypeVariableDeclaration | TypeVariableGetterDeclaration | TypeVariableSetterDeclaration | InvalidTypeMemberDeclaration | NestedMethodDeclaration | LocalVariableDeclaration | EnumerationVariableDeclaration | ArrayLiteral | ArrayLiteralElementList | AssertionExpression | AssumptionExpression | AsExpression | BinaryExpression | MethodBlockLiteral | ArgumentList | CallExpression | AutotypeCallExpression | IndexedAccessExpression | InvalidExpression | IsExpression | MethodLiteral | ParenthesizedExpression | WhenTernaryExpression | PrefixUnaryExpression | PropertyAccessExpression | ReferenceExpression | DereferenceExpression | TextTemplateLiteral | TextTemplateSpanList | TextTemplateSpan | TokenExpression | KeywordExpression | ObjectExpression | BaseExpression | IdentifierExpression | GenericSpecializationExpression | DefaultMatchExpression | AssignmentStatement | StatementList | StatementBlock | FunctionBlock | BreakLoopStatement | ContinueLoopStatement | DisposeStatement | RunStatement | TryStatement | CatchClause | ErrorVariableDeclaration | FinallyClause | EmptyStatement | ErrorStatement | ImportantStatement | ExpressionStatement | EnumerationVariableList | ForStatement | IfStatement | ElseIfClauseList | ElseIfClause | ElseClause | InvalidStatement | NestedMethodDeclarationStatement | LocalVariableDeclarationStatement | LoopStatement | ReturnStatement | CaseClauseList | SwitchStatement | MatchExpressionList | CaseClause | WhileStatement | YieldStatement | TranslationParameterList | TranslationParameterClause | ConstructorTranslation | IndexerTranslationParameterClause | IndexerTranslation | TranslationTypeParameterList | TranslationTypeParameterClause | PackageMethodTranslation | TypeMethodTranslation | MethodTypeTranslation | PackageImportTranslation | QualifiedName | PackageVariableTranslation | TypeVariableOrVariantTranslation | TypeMemberTranslationList | TypeTranslation | TextLiteralTranslation | TextTemplateLiteralTranslation | VariantDeclaration | TypeParameterDeclaration | ParameterDeclaration | Argument | TagList | Tag | ModifierList | Modifier | ParameterClause | ParameterList | TypeArgumentClause | TypeArgumentList | TypeParameterClause | TypeParameterList | TypeAnnotation | Token;
|
@@ -31,6 +31,7 @@ export declare class SyntaxFactory {
|
|
31
31
|
static indexerParameterClause(indexerParameters: readonly tree.ParameterDeclaration[]): tree.TypeIndexerParameterClause;
|
32
32
|
static namedTypeSpecifier(name: string | readonly string[], typeArguments?: readonly tree.TypeSpecifier[]): tree.NamedTypeSpecifier;
|
33
33
|
static unionTypeSpecifier(typeSpecifiers: readonly tree.TypeSpecifier[]): tree.UnionTypeSpecifier;
|
34
|
+
static intersectionTypeSpecifier(typeSpecifiers: readonly tree.TypeSpecifier[]): tree.IntersectionTypeSpecifier;
|
34
35
|
static nullableTypeSpecifier(typeSpecifier: tree.TypeSpecifier): tree.NullableTypeSpecifier;
|
35
36
|
static parenthesizedTypeSpecifier(typeSpecifier: tree.TypeSpecifier): tree.ParenthesizedTypeSpecifier;
|
36
37
|
static anonymousStructuredTypeSpecifier(body: tree.StructuredTypeDeclarationBody): tree.AnonymousTypeSpecifier;
|
@@ -67,9 +67,13 @@ export declare class SyntaxToCode {
|
|
67
67
|
private writeAnonymousStructuredTypeDeclaration;
|
68
68
|
private writeAnonymousVariantTypeDeclaration;
|
69
69
|
private writeUnionTypeSpecifier;
|
70
|
+
private writeUnionTypeSpecifierTypeList;
|
71
|
+
private writeIntersectionTypeSpecifier;
|
72
|
+
private writeIntersectionTypeSpecifierTypeList;
|
70
73
|
private writeParenthesizedTypeSpecifier;
|
71
74
|
private writeNullableTypeSpecifier;
|
72
|
-
private
|
75
|
+
private doesUnionTypeElementRequireParenthesis;
|
76
|
+
private doesIntersectionTypeElementRequireParenthesis;
|
73
77
|
private doesTypeMadeNullableRequireParenthesis;
|
74
78
|
private writeQualifiedName;
|
75
79
|
private writeTypeArgumentClause;
|
@@ -133,9 +133,9 @@ export declare class PackagePath extends BaseNode {
|
|
133
133
|
constructor(green: green.PackagePath, rangeStart: number, parent: PackagePathParent);
|
134
134
|
private createChildren;
|
135
135
|
}
|
136
|
-
export type TypeSpecifier = NamedTypeSpecifier | AnonymousTypeSpecifier | UnionTypeSpecifier | ParenthesizedTypeSpecifier | NullableTypeSpecifier | InvalidTypeSpecifier;
|
136
|
+
export type TypeSpecifier = NamedTypeSpecifier | AnonymousTypeSpecifier | UnionTypeSpecifier | IntersectionTypeSpecifier | ParenthesizedTypeSpecifier | NullableTypeSpecifier | InvalidTypeSpecifier;
|
137
137
|
export type NamedTypeSpecifierParent = BaseTypeList | NonNamedTypeSpecifierParent;
|
138
|
-
export type NonNamedTypeSpecifierParent = AliasTypeDeclarationBody | AsExpression | IsExpression | TypeParameterDeclaration | TypeArgumentList | TypeAnnotation | ParenthesizedTypeSpecifier | NullableTypeSpecifier | UnionTypeSpecifierTypeList;
|
138
|
+
export type NonNamedTypeSpecifierParent = AliasTypeDeclarationBody | AsExpression | IsExpression | TypeParameterDeclaration | TypeArgumentList | TypeAnnotation | ParenthesizedTypeSpecifier | NullableTypeSpecifier | UnionTypeSpecifierTypeList | IntersectionTypeSpecifierTypeList;
|
139
139
|
export declare class NamedTypeSpecifier extends BaseNode {
|
140
140
|
readonly kind = NodeKind.NamedTypeSpecifier;
|
141
141
|
readonly green: green.NamedTypeSpecifier;
|
@@ -173,6 +173,31 @@ export declare class UnionTypeSpecifierTypeList extends BaseNode {
|
|
173
173
|
constructor(green: green.UnionTypeSpecifierTypeList, rangeStart: number, parent: UnionTypeSpecifierTypeListParent);
|
174
174
|
private createChildren;
|
175
175
|
}
|
176
|
+
export declare class IntersectionTypeSpecifier extends BaseNode {
|
177
|
+
readonly kind = NodeKind.IntersectionTypeSpecifier;
|
178
|
+
readonly green: green.IntersectionTypeSpecifier;
|
179
|
+
readonly parent: NonNamedTypeSpecifierParent;
|
180
|
+
private _children;
|
181
|
+
get children(): readonly [IntersectionTypeSpecifierTypeList];
|
182
|
+
get typeList(): IntersectionTypeSpecifierTypeList;
|
183
|
+
protected get thisAsNode(): Node;
|
184
|
+
constructor(green: green.IntersectionTypeSpecifier, rangeStart: number, parent: NonNamedTypeSpecifierParent);
|
185
|
+
private createChildren;
|
186
|
+
}
|
187
|
+
export type IntersectionTypeSpecifierTypeListElement = TypeSpecifier | Token<TokenKind.Ampersand>;
|
188
|
+
export type IntersectionTypeSpecifierTypeListParent = IntersectionTypeSpecifier;
|
189
|
+
export declare class IntersectionTypeSpecifierTypeList extends BaseNode {
|
190
|
+
readonly kind = NodeKind.IntersectionTypeSpecifierTypeList;
|
191
|
+
readonly green: green.IntersectionTypeSpecifierTypeList;
|
192
|
+
readonly parent: IntersectionTypeSpecifierTypeListParent;
|
193
|
+
private _children;
|
194
|
+
get children(): readonly IntersectionTypeSpecifierTypeListElement[];
|
195
|
+
get elements(): readonly IntersectionTypeSpecifierTypeListElement[];
|
196
|
+
get types(): Query<TypeSpecifier>;
|
197
|
+
protected get thisAsNode(): Node;
|
198
|
+
constructor(green: green.IntersectionTypeSpecifierTypeList, rangeStart: number, parent: IntersectionTypeSpecifierTypeListParent);
|
199
|
+
private createChildren;
|
200
|
+
}
|
176
201
|
export declare class ParenthesizedTypeSpecifier extends BaseNode {
|
177
202
|
readonly kind = NodeKind.ParenthesizedTypeSpecifier;
|
178
203
|
readonly green: green.ParenthesizedTypeSpecifier;
|
@@ -1306,15 +1331,15 @@ export declare class StatementBlock extends BaseNode {
|
|
1306
1331
|
private createChildren;
|
1307
1332
|
}
|
1308
1333
|
export type FunctionBlockParent = PackageVariableGetterDeclaration | PackageVariableSetterDeclaration | PackageMethodDeclaration | TypeVariableGetterDeclaration | TypeVariableSetterDeclaration | TypeIndexedGetterDeclaration | TypeIndexedSetterDeclaration | TypeDereferencedVariableGetterDeclaration | TypeDereferencedVariableSetterDeclaration | TypeMethodDeclaration | OperatorDeclaration | NestedMethodDeclaration | MethodLiteral | MethodBlockLiteral | PackageConstructorDeclaration | PackageEntryPointDeclaration | TypeConstructorDeclaration | TypeDestructorDeclaration;
|
1334
|
+
export type ExpressionOrStatementList = Expression | StatementList;
|
1309
1335
|
export declare class FunctionBlock extends BaseNode {
|
1310
1336
|
readonly kind = NodeKind.FunctionBlock;
|
1311
1337
|
readonly green: green.FunctionBlock;
|
1312
1338
|
readonly parent: FunctionBlockParent;
|
1313
1339
|
private _children;
|
1314
|
-
get children(): readonly [Token<green.TokenKind.OpenBrace>,
|
1340
|
+
get children(): readonly [Token<green.TokenKind.OpenBrace>, ExpressionOrStatementList, Token<green.TokenKind.CloseBrace>];
|
1315
1341
|
get openBraceToken(): Token<TokenKind.OpenBrace>;
|
1316
|
-
get
|
1317
|
-
get statementList(): StatementList | undefined;
|
1342
|
+
get expressionOrStatementList(): ExpressionOrStatementList;
|
1318
1343
|
get closeBraceToken(): Token<TokenKind.CloseBrace>;
|
1319
1344
|
protected get thisAsNode(): Node;
|
1320
1345
|
constructor(green: green.FunctionBlock, rangeStart: number, parent: FunctionBlockParent);
|
@@ -1439,9 +1464,9 @@ export declare class ErrorStatement extends BaseNode {
|
|
1439
1464
|
readonly green: green.ErrorStatement;
|
1440
1465
|
readonly parent: ErrorStatementParent;
|
1441
1466
|
private _children;
|
1442
|
-
get children(): readonly [Keyword<green.KeywordKind.Error>, Expression
|
1467
|
+
get children(): readonly [Keyword<green.KeywordKind.Error>, Expression];
|
1443
1468
|
get errorKeyword(): Keyword<KeywordKind.Error>;
|
1444
|
-
get expression(): Expression
|
1469
|
+
get expression(): Expression;
|
1445
1470
|
protected get thisAsNode(): Node;
|
1446
1471
|
constructor(green: green.ErrorStatement, rangeStart: number, parent: ErrorStatementParent);
|
1447
1472
|
private createChildren;
|
@@ -2182,4 +2207,4 @@ export declare class TypeAnnotation extends BaseNode {
|
|
2182
2207
|
constructor(green: green.TypeAnnotation, rangeStart: number, parent: TypeAnnotationParent);
|
2183
2208
|
private createChildren;
|
2184
2209
|
}
|
2185
|
-
export type Node = SourceFile | PackageMemberDeclarationList | Keyword | PackageImportDirectiveList | SinglePackageImportDirective | PackageGroupImportDirective | PackageImportList | PackageImport | PackagePath | NamedTypeSpecifier | UnionTypeSpecifier | UnionTypeSpecifierTypeList | ParenthesizedTypeSpecifier | NullableTypeSpecifier | AnonymousTypeSpecifier | InvalidTypeSpecifier | AnonymousMethodTypeDeclaration | AnonymousStructuredTypeDeclaration | AnonymousVariantTypeDeclaration | TopLevelTranslationList | TranslationsDeclaration | PackageAliasTypeDeclaration | AliasTypeDeclarationBody | PackageMemberGroupDeclaration | PackageConstructorDeclaration | PackageEntryPointDeclaration | PackageMethodDeclaration | PackageMethodTypeDeclaration | MethodTypeDeclarationBody | BaseTypeList | TypeMemberDeclarationList | TypeMemberDeclarationBlock | PackageStructuredTypeDeclaration | StructuredTypeDeclarationBody | PackageVariableDeclaration | PackageVariableGetterDeclaration | PackageVariableSetterDeclaration | PackageVariantTypeDeclaration | VariantTypeDeclarationBody | TypeExtensionDeclaration | ExtendedTypeClauseCommaList | ExtendedTypeClause | InvalidPackageMemberDeclaration | TypeMemberGroupDeclaration | TypeConstructorDeclaration | TypeDestructorDeclaration | TypeIndexedGetterDeclaration | TypeIndexedSetterDeclaration | TypeIndexerParameterClause | TypeDereferencedVariableGetterDeclaration | TypeDereferencedVariableSetterDeclaration | TypeMethodDeclaration | OperatorDeclaration | TypeVariableDeclaration | TypeVariableGetterDeclaration | TypeVariableSetterDeclaration | InvalidTypeMemberDeclaration | NestedMethodDeclaration | LocalVariableDeclaration | EnumerationVariableDeclaration | ArrayLiteral | ArrayLiteralElementList | AssertionExpression | AssumptionExpression | AsExpression | BinaryExpression | MethodBlockLiteral | ArgumentList | CallExpression | AutotypeCallExpression | IndexedAccessExpression | InvalidExpression | IsExpression | MethodLiteral | ParenthesizedExpression | WhenTernaryExpression | PrefixUnaryExpression | PropertyAccessExpression | ReferenceExpression | DereferenceExpression | TextTemplateLiteral | TextTemplateSpanList | TextTemplateSpan | TokenExpression | KeywordExpression | ObjectExpression | BaseExpression | IdentifierExpression | GenericSpecializationExpression | DefaultMatchExpression | AssignmentStatement | StatementList | StatementBlock | FunctionBlock | BreakLoopStatement | ContinueLoopStatement | DisposeStatement | RunStatement | TryStatement | CatchClause | ErrorVariableDeclaration | FinallyClause | EmptyStatement | ErrorStatement | ImportantStatement | ExpressionStatement | EnumerationVariableList | ForStatement | IfStatement | ElseIfClauseList | ElseIfClause | ElseClause | InvalidStatement | NestedMethodDeclarationStatement | LocalVariableDeclarationStatement | LoopStatement | ReturnStatement | CaseClauseList | SwitchStatement | MatchExpressionList | CaseClause | WhileStatement | YieldStatement | TranslationParameterList | TranslationParameterClause | ConstructorTranslation | IndexerTranslationParameterClause | IndexerTranslation | TranslationTypeParameterList | TranslationTypeParameterClause | PackageMethodTranslation | TypeMethodTranslation | MethodTypeTranslation | PackageImportTranslation | QualifiedName | PackageVariableTranslation | TypeVariableOrVariantTranslation | TypeMemberTranslationList | TypeTranslation | TextLiteralTranslation | TextTemplateLiteralTranslation | VariantDeclaration | TypeParameterDeclaration | ParameterDeclaration | Argument | TagList | Tag | ModifierList | Modifier | ParameterClause | ParameterList | TypeArgumentClause | TypeArgumentList | TypeParameterClause | TypeParameterList | TypeAnnotation | Token;
|
2210
|
+
export type Node = SourceFile | PackageMemberDeclarationList | Keyword | PackageImportDirectiveList | SinglePackageImportDirective | PackageGroupImportDirective | PackageImportList | PackageImport | PackagePath | NamedTypeSpecifier | UnionTypeSpecifier | UnionTypeSpecifierTypeList | IntersectionTypeSpecifier | IntersectionTypeSpecifierTypeList | ParenthesizedTypeSpecifier | NullableTypeSpecifier | AnonymousTypeSpecifier | InvalidTypeSpecifier | AnonymousMethodTypeDeclaration | AnonymousStructuredTypeDeclaration | AnonymousVariantTypeDeclaration | TopLevelTranslationList | TranslationsDeclaration | PackageAliasTypeDeclaration | AliasTypeDeclarationBody | PackageMemberGroupDeclaration | PackageConstructorDeclaration | PackageEntryPointDeclaration | PackageMethodDeclaration | PackageMethodTypeDeclaration | MethodTypeDeclarationBody | BaseTypeList | TypeMemberDeclarationList | TypeMemberDeclarationBlock | PackageStructuredTypeDeclaration | StructuredTypeDeclarationBody | PackageVariableDeclaration | PackageVariableGetterDeclaration | PackageVariableSetterDeclaration | PackageVariantTypeDeclaration | VariantTypeDeclarationBody | TypeExtensionDeclaration | ExtendedTypeClauseCommaList | ExtendedTypeClause | InvalidPackageMemberDeclaration | TypeMemberGroupDeclaration | TypeConstructorDeclaration | TypeDestructorDeclaration | TypeIndexedGetterDeclaration | TypeIndexedSetterDeclaration | TypeIndexerParameterClause | TypeDereferencedVariableGetterDeclaration | TypeDereferencedVariableSetterDeclaration | TypeMethodDeclaration | OperatorDeclaration | TypeVariableDeclaration | TypeVariableGetterDeclaration | TypeVariableSetterDeclaration | InvalidTypeMemberDeclaration | NestedMethodDeclaration | LocalVariableDeclaration | EnumerationVariableDeclaration | ArrayLiteral | ArrayLiteralElementList | AssertionExpression | AssumptionExpression | AsExpression | BinaryExpression | MethodBlockLiteral | ArgumentList | CallExpression | AutotypeCallExpression | IndexedAccessExpression | InvalidExpression | IsExpression | MethodLiteral | ParenthesizedExpression | WhenTernaryExpression | PrefixUnaryExpression | PropertyAccessExpression | ReferenceExpression | DereferenceExpression | TextTemplateLiteral | TextTemplateSpanList | TextTemplateSpan | TokenExpression | KeywordExpression | ObjectExpression | BaseExpression | IdentifierExpression | GenericSpecializationExpression | DefaultMatchExpression | AssignmentStatement | StatementList | StatementBlock | FunctionBlock | BreakLoopStatement | ContinueLoopStatement | DisposeStatement | RunStatement | TryStatement | CatchClause | ErrorVariableDeclaration | FinallyClause | EmptyStatement | ErrorStatement | ImportantStatement | ExpressionStatement | EnumerationVariableList | ForStatement | IfStatement | ElseIfClauseList | ElseIfClause | ElseClause | InvalidStatement | NestedMethodDeclarationStatement | LocalVariableDeclarationStatement | LoopStatement | ReturnStatement | CaseClauseList | SwitchStatement | MatchExpressionList | CaseClause | WhileStatement | YieldStatement | TranslationParameterList | TranslationParameterClause | ConstructorTranslation | IndexerTranslationParameterClause | IndexerTranslation | TranslationTypeParameterList | TranslationTypeParameterClause | PackageMethodTranslation | TypeMethodTranslation | MethodTypeTranslation | PackageImportTranslation | QualifiedName | PackageVariableTranslation | TypeVariableOrVariantTranslation | TypeMemberTranslationList | TypeTranslation | TextLiteralTranslation | TextTemplateLiteralTranslation | VariantDeclaration | TypeParameterDeclaration | ParameterDeclaration | Argument | TagList | Tag | ModifierList | Modifier | ParameterClause | ParameterList | TypeArgumentClause | TypeArgumentList | TypeParameterClause | TypeParameterList | TypeAnnotation | Token;
|
@@ -0,0 +1,20 @@
|
|
1
|
+
import { Analyzer } from '../analysis/index.js';
|
2
|
+
import { TypeEntity } from '../entities/index.js';
|
3
|
+
import { SubstitutionMap, Substitutions } from './Substitutions.js';
|
4
|
+
import { IType, Type } from './index.js';
|
5
|
+
export declare class IntersectionType implements IType {
|
6
|
+
readonly kind = "intersection";
|
7
|
+
readonly originalTypes: readonly Type[];
|
8
|
+
private readonly _analyzer;
|
9
|
+
private readonly _unaliasedFlattenedTypes;
|
10
|
+
get unaliasedFlattenedTypes(): readonly Type[];
|
11
|
+
get debuggerDisplay(): string;
|
12
|
+
constructor(analyzer: Analyzer, originalTypes: readonly Type[]);
|
13
|
+
equals(other: Type): boolean;
|
14
|
+
getSubstitutions(): Substitutions;
|
15
|
+
applySubstitutions(map: SubstitutionMap): Type;
|
16
|
+
getEntity(): TypeEntity | undefined;
|
17
|
+
getBaseObjectTypeOrAliasedType(): Type | undefined;
|
18
|
+
toString(): string;
|
19
|
+
private unaliasAndFlattenType;
|
20
|
+
}
|
@@ -4,12 +4,15 @@ import { IType, SubstitutionMap, Substitutions, Type } from './index.js';
|
|
4
4
|
export declare class ParameterType implements IType {
|
5
5
|
private readonly _analyzer;
|
6
6
|
private readonly _entity;
|
7
|
-
|
7
|
+
readonly isNoneExcluded: boolean;
|
8
8
|
readonly kind = "parameter";
|
9
|
-
|
9
|
+
private readonly _constraint;
|
10
|
+
/**
|
11
|
+
* Ограничение параметра типа с учётом флага {@link isNoneExcluded}.
|
12
|
+
*/
|
10
13
|
get constraint(): Type | undefined;
|
11
14
|
get debuggerDisplay(): string;
|
12
|
-
constructor(_analyzer: Analyzer, _entity: TypeParameterEntity,
|
15
|
+
constructor(_analyzer: Analyzer, _entity: TypeParameterEntity, isNoneExcluded: boolean);
|
13
16
|
getSubstitutions(): Substitutions;
|
14
17
|
getEntity(): TypeParameterEntity;
|
15
18
|
applySubstitutions(map: SubstitutionMap): Type;
|
@@ -1,12 +1,13 @@
|
|
1
1
|
import { TypeEntity } from '../entities/index.js';
|
2
2
|
import { AliasType } from './AliasType.js';
|
3
|
+
import { IntersectionType } from './IntersectionType.js';
|
3
4
|
import { MethodType } from './MethodType.js';
|
4
5
|
import { ParameterType } from './ParameterType.js';
|
5
6
|
import { StructuredType } from './StructuredType.js';
|
6
7
|
import { UnresolvedType } from './UnresolvedType.js';
|
7
8
|
import { VariantType } from './VariantType.js';
|
8
9
|
import { SubstitutionMap, Substitutions, UnionType } from './index.js';
|
9
|
-
export type Type = StructuredType | VariantType | MethodType | AliasType | UnresolvedType | ParameterType | UnionType;
|
10
|
+
export type Type = StructuredType | VariantType | MethodType | AliasType | UnresolvedType | ParameterType | UnionType | IntersectionType;
|
10
11
|
export interface IType {
|
11
12
|
getSubstitutions(): Substitutions;
|
12
13
|
applySubstitutions(map: SubstitutionMap): Type;
|
@@ -9,8 +9,11 @@ export declare class TypeFactory {
|
|
9
9
|
getVariantType(entity: VariantTypeEntity, substitutions: Substitutions): VariantType;
|
10
10
|
getMethodType(entity: MethodTypeEntity, substitutions: Substitutions): MethodType;
|
11
11
|
getAliasType(entity: AliasTypeEntity, substitutions: Substitutions): AliasType;
|
12
|
-
getUnionType(types: readonly Type[], excludeDuplicates?: boolean): Type;
|
12
|
+
getUnionType(types: readonly Type[], excludeDuplicates?: boolean, reduce?: boolean): Type;
|
13
|
+
getIntersectionType(types: readonly Type[], excludeDuplicates?: boolean, reduce?: boolean): Type;
|
13
14
|
getUnresolvedType(): UnresolvedType;
|
14
15
|
private getUniqueFlattenedConstituentTypes;
|
15
16
|
private excludeDuplicateTypesComparingWithEqualsMethod;
|
17
|
+
private removeBaseTypes;
|
18
|
+
private removeDerivedTypes;
|
16
19
|
}
|
@@ -86,6 +86,7 @@ export declare class Constructor implements ITypeMember {
|
|
86
86
|
getEntity(): ConstructorEntity;
|
87
87
|
getSubstitutions(): Substitutions;
|
88
88
|
isHidden(): EntityHidingLevel | undefined;
|
89
|
+
isStatic(): boolean;
|
89
90
|
equals(other: TypeMember): boolean;
|
90
91
|
}
|
91
92
|
export declare class Destructor implements ITypeMember {
|
@@ -98,6 +99,7 @@ export declare class Destructor implements ITypeMember {
|
|
98
99
|
getEntity(): DestructorEntity;
|
99
100
|
getSubstitutions(): Substitutions;
|
100
101
|
isHidden(): EntityHidingLevel | undefined;
|
102
|
+
isStatic(): boolean;
|
101
103
|
applySubstitutions(substitutions: Substitutions): Destructor;
|
102
104
|
equals(other: TypeMember): boolean;
|
103
105
|
}
|
@@ -112,6 +114,7 @@ export declare class Indexer implements ITypeMember {
|
|
112
114
|
getEntity(): IndexerEntity;
|
113
115
|
getSubstitutions(): Substitutions;
|
114
116
|
isHidden(): EntityHidingLevel | undefined;
|
117
|
+
isStatic(): boolean;
|
115
118
|
applySubstitutions(substitutions: Substitutions): Indexer;
|
116
119
|
equals(other: TypeMember): boolean;
|
117
120
|
}
|
@@ -124,11 +127,13 @@ export declare class DereferenceOperator implements ITypeMember {
|
|
124
127
|
getEntity(): DereferenceOperatorEntity;
|
125
128
|
getSubstitutions(): Substitutions;
|
126
129
|
isHidden(): EntityHidingLevel | undefined;
|
130
|
+
isStatic(): boolean;
|
127
131
|
applySubstitutions(substitutions: Substitutions): DereferenceOperator;
|
128
132
|
equals(other: TypeMember): boolean;
|
129
133
|
}
|
130
134
|
export interface ITypeMember {
|
131
135
|
isHidden(): EntityHidingLevel | undefined;
|
136
|
+
isStatic(): boolean;
|
132
137
|
getSubstitutions(): Substitutions;
|
133
138
|
equals(other: TypeMember): boolean;
|
134
139
|
}
|