@artel/artc 0.6.25223 → 0.6.25225
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 +85 -79
- package/build/api/ApiNodeJS.js +3 -3
- package/build/api/ApiServices.js +797 -674
- package/build/{chunk-DZNNWICP.js → chunk-TFTCV5R5.js} +6604 -5875
- package/build/{chunk-AX3LQ2CF.js → chunk-UB6LHKS5.js} +3 -3
- package/build/{chunk-LG4Z4SWO.js → chunk-Z6TZA6SN.js} +3 -3
- package/build/types/analysis/AccessedFunction.d.ts +53 -0
- package/build/types/analysis/AnalyzedTranslationPackage.d.ts +16 -15
- package/build/types/analysis/Analyzer.d.ts +142 -127
- package/build/types/analysis/CallExpressionMeaning.d.ts +10 -10
- package/build/types/analysis/DiagnosticCollector.d.ts +17 -17
- package/build/types/analysis/EntityLocalizationHelper.d.ts +6 -6
- package/build/types/analysis/IdentifierExpressionMeaning.d.ts +10 -10
- package/build/types/analysis/ImportedPackageNameTree.d.ts +1 -0
- package/build/types/analysis/LocalizationContext.d.ts +2 -2
- package/build/types/analysis/{PropertyAccessExpressionMeaning.d.ts → MemberAccessExpressionMeaning.d.ts} +27 -21
- package/build/types/analysis/NamedTypeResolver.d.ts +5 -1
- package/build/types/analysis/NamedTypeSpecifierResolver.d.ts +4 -1
- package/build/types/analysis/NodeTypeUtils.d.ts +13 -13
- package/build/types/analysis/OperationOverloadResolver.d.ts +1 -1
- package/build/types/analysis/Scope.d.ts +15 -15
- package/build/types/analysis/SemanticContext.d.ts +29 -29
- package/build/types/analysis/SemanticContextBuilder.d.ts +22 -22
- package/build/types/analysis/SourceFileMembers.d.ts +2 -2
- package/build/types/analysis/StatementBlockScopeBuilder.d.ts +12 -12
- package/build/types/analysis/{SubstitutedMethod.d.ts → SubstitutedFunction.d.ts} +14 -14
- package/build/types/analysis/TagMeaning.d.ts +23 -20
- package/build/types/analysis/Tags.d.ts +6 -6
- package/build/types/analysis/TypeNarrower.d.ts +21 -21
- package/build/types/analysis/Utils.d.ts +15 -3
- package/build/types/analysis/WellKnownDeclarations.d.ts +4 -4
- 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/api/Api.d.ts +3 -3
- package/build/types/common/HelperPhrases.d.ts +3 -2
- package/build/types/diagnostic/DiagnosticCode.d.ts +130 -131
- package/build/types/emitter/EmitPhaseName.d.ts +8 -8
- package/build/types/emitter/Emitter.d.ts +4 -4
- package/build/types/emitter/EmitterContext.d.ts +2 -2
- package/build/types/emitter/Entities.d.ts +31 -29
- package/build/types/emitter/EntityMap.d.ts +8 -8
- package/build/types/emitter/IrBuilder.d.ts +18 -18
- package/build/types/emitter/IrToJs.d.ts +9 -9
- package/build/types/emitter/Transformer.d.ts +37 -37
- package/build/types/emitter/ir/AccessedEntities.d.ts +5 -5
- package/build/types/emitter/ir/ComputedAccess.d.ts +5 -5
- package/build/types/emitter/ir/EmitOptions.d.ts +41 -27
- package/build/types/emitter/ir/Nodes.d.ts +141 -140
- package/build/types/emitter/ir/types.d.ts +8 -8
- package/build/types/entities/ConstructorEntity.d.ts +9 -9
- package/build/types/entities/DereferenceOperatorEntity.d.ts +4 -4
- package/build/types/entities/DestructorEntity.d.ts +4 -4
- package/build/types/entities/{MethodEntity.d.ts → FunctionEntity.d.ts} +36 -36
- package/build/types/entities/{MethodTypeEntity.d.ts → FunctionTypeEntity.d.ts} +23 -23
- package/build/types/entities/GetterEntity.d.ts +9 -9
- package/build/types/entities/IndexerEntity.d.ts +4 -4
- package/build/types/entities/SetterEntity.d.ts +9 -9
- package/build/types/entities/TypeEntity.d.ts +3 -3
- package/build/types/entities/TypeEntityMembers.d.ts +3 -3
- package/build/types/entities/TypeParameterEntity.d.ts +2 -2
- package/build/types/entities/VariableEntity.d.ts +32 -32
- package/build/types/entities/index.d.ts +14 -14
- package/build/types/services/CompletionService.d.ts +8 -9
- package/build/types/services/DisplayService.d.ts +72 -69
- package/build/types/services/HoverService.d.ts +1 -1
- package/build/types/services/NodeSemanticInfo.d.ts +26 -21
- package/build/types/services/SemanticTokensService.d.ts +6 -6
- package/build/types/services/SourceFileItemsService.d.ts +11 -11
- package/build/types/services/TypeDefinitionService.d.ts +2 -2
- package/build/types/services/signature-help/SignatureWithValueParameters.d.ts +10 -10
- package/build/types/services/signature-help/TypeParameterSignatureHelpProvider.d.ts +1 -1
- package/build/types/services/source-generation/EntityToSyntax.d.ts +10 -9
- package/build/types/tree/NodeKind.d.ts +27 -27
- package/build/types/tree/green/Nodes.d.ts +127 -128
- package/build/types/tree/green/SyntaxFactory.d.ts +20 -19
- package/build/types/tree/green/SyntaxToCode.d.ts +23 -21
- package/build/types/tree/red/Nodes.d.ts +173 -172
- package/build/types/ts-interop/Entities.d.ts +28 -28
- package/build/types/ts-interop/TsInteropContext.d.ts +2 -1
- package/build/types/ts-interop/TsPackageMembersCreator.d.ts +1 -1
- package/build/types/ts-interop/TsTypeMembersCreator.d.ts +1 -1
- package/build/types/types/{MethodType.d.ts → FunctionType.d.ts} +6 -6
- package/build/types/types/IntersectionType.d.ts +20 -0
- package/build/types/types/ParameterType.d.ts +6 -3
- package/build/types/types/StandardTypes.d.ts +2 -2
- package/build/types/types/Type.d.ts +3 -2
- package/build/types/types/TypeFactory.d.ts +8 -6
- package/build/types/types/TypeMembers.d.ts +8 -8
- package/build/types/types/index.d.ts +2 -1
- package/package.json +1 -1
- package/build/types/analysis/AccessedMethod.d.ts +0 -53
- package/build/types/analysis/ControlFlowGraphBuilder.d.ts +0 -129
@@ -14,14 +14,13 @@ import * as tree from '../tree/index.js';
|
|
14
14
|
import { TsInteropContext, TsProgramState } from '../ts-interop/TsInteropContext.js';
|
15
15
|
import * as types from '../types/index.js';
|
16
16
|
import { TypeFactory } from '../types/index.js';
|
17
|
-
import {
|
17
|
+
import { AccessedFunction } from './AccessedFunction.js';
|
18
18
|
import { AnalyzedTranslationPackage } from './AnalyzedTranslationPackage.js';
|
19
19
|
import { ArgumentToParameterMatchResult, MatchResultValueParameter } from './ArgumentToParameterMatchResult.js';
|
20
20
|
import * as autotypeCallExpressionMeaning from './AutotypeCallExpressionMeaning.js';
|
21
21
|
import * as baseExpressionMeaning from './BaseExpressionMeaning.js';
|
22
22
|
import * as callExpressionMeaning from './CallExpressionMeaning.js';
|
23
23
|
import * as constructorOverloadResolver from './ConstructorOverloadResolver.js';
|
24
|
-
import { ControlFlowGraphBuildResult } from './ControlFlowGraphBuilder.js';
|
25
24
|
import { DeclarationsUsageCountResult } from './DeclarationsUsageCounter.js';
|
26
25
|
import * as dereferenceExpressionMeaning from './DereferenceExpressionMeaning.js';
|
27
26
|
import { FoundAnonymousDeclaration } from './FoundDeclaration.js';
|
@@ -30,12 +29,12 @@ import { ImportedPackageNameTree, PackageNameTreeNode } from './ImportedPackageN
|
|
30
29
|
import * as indexedAccessExpressionMeaning from './IndexedAccessExpressionMeaning.js';
|
31
30
|
import { WithLocalization } from './Localization.js';
|
32
31
|
import { LocalizationContext } from './LocalizationContext.js';
|
32
|
+
import * as memberAccessExpressionResolution from './MemberAccessExpressionMeaning.js';
|
33
33
|
import { ModifierFlags } from './ModifierFlags.js';
|
34
34
|
import { NamedTypeSpecifierResolutionResult } from './NamedTypeSpecifierResolver.js';
|
35
|
-
import {
|
35
|
+
import { DereferencedVariableAccessorDeclaration, FieldAccessorDeclaration, FunctionTypeDeclaration, GetterDeclaration, IndexedElementAccessorDeclaration, PackageVariableAccessorDeclaration, SetterDeclaration, StructuredTypeDeclaration, VariantTypeDeclaration } from './NodeTypeUtils.js';
|
36
36
|
import * as objectExpressionMeaning from './ObjectExpressionMeaning.js';
|
37
37
|
import * as operationOverloadResolver from './OperationOverloadResolver.js';
|
38
|
-
import * as propertyAccessExpressionResolution from './PropertyAccessExpressionMeaning.js';
|
39
38
|
import * as scope from './Scope.js';
|
40
39
|
import { SemanticContextBuilder } from './SemanticContextBuilder.js';
|
41
40
|
import { SourceFileMembers as ActualSourceFileMembers } from './SourceFileMembers.js';
|
@@ -43,10 +42,11 @@ import * as tagMeaning from './TagMeaning.js';
|
|
43
42
|
import * as tags from './Tags.js';
|
44
43
|
import { TargetTypeHint } from './TargetTypeHint.js';
|
45
44
|
import * as typeOverloadResolver from './TypeOverloadResolver.js';
|
45
|
+
import * as controlFlow from './control-flow/index.js';
|
46
46
|
import { WellKnownDeclarations } from './index.js';
|
47
47
|
export declare class Analyzer {
|
48
48
|
static readonly enumeratorMethodName = "\u043F\u0435\u0440\u0435\u0431\u043E\u0440";
|
49
|
-
static readonly
|
49
|
+
static readonly functionTypeInvokeMethodName = "\u0432\u044B\u043F\u043E\u043B\u043D\u0438\u0442\u044C";
|
50
50
|
readonly compilation: project.Compilation;
|
51
51
|
/**
|
52
52
|
* Пакет с именем 'Артель', содержащий стандартные типы.
|
@@ -69,11 +69,12 @@ export declare class Analyzer {
|
|
69
69
|
readonly linkedEntity: LinkedEntity;
|
70
70
|
readonly owningPlainObjectModificationCheck: OwningPlainObjectModificationCheck;
|
71
71
|
readonly packageImports: PackageImports;
|
72
|
+
readonly typeUtils: TypeUtils;
|
72
73
|
private readonly _tsInteropInputs;
|
73
74
|
private readonly _targetType;
|
74
75
|
private readonly _typeAssignabilityCheck;
|
75
76
|
private readonly _tsInterop;
|
76
|
-
private readonly
|
77
|
+
private readonly _memberAccessExpressionResolutionResults;
|
77
78
|
private readonly _sourceFileMembers;
|
78
79
|
private readonly _callExpressionMeanings;
|
79
80
|
private readonly _indexedAccessExpressionResolutionResults;
|
@@ -87,8 +88,8 @@ export declare class Analyzer {
|
|
87
88
|
private readonly _prefixUnaryExpressionOperatorResolutionResults;
|
88
89
|
private readonly _binaryExpressionUserDefinableOperatorResolutionResults;
|
89
90
|
private readonly _assignmentStatementOperatorResolutionResults;
|
90
|
-
private readonly
|
91
|
-
private readonly
|
91
|
+
private readonly _functionEntitySignatureTypes;
|
92
|
+
private readonly _valueParametersOfFunctionBlockLiterals;
|
92
93
|
private readonly _extendedTypes;
|
93
94
|
private readonly _analyzedTranslationPackages;
|
94
95
|
private readonly _linkedMultiPlatformPackagesByPlatform;
|
@@ -112,14 +113,14 @@ export declare class Analyzer {
|
|
112
113
|
getSyntacticAccessKind(node: tree.Expression): SyntacticAccessKind;
|
113
114
|
getTypeMemberEntityContainer(node: tree.TypeMemberDeclaration): e.TypeMemberEntityContainer;
|
114
115
|
getTargetTypeOfExpression(node: tree.Expression, hint?: TargetTypeHint): types.Type | undefined;
|
115
|
-
|
116
|
+
getUnambiguousTargetFunctionType(targetType: types.Type | undefined): types.FunctionType | undefined;
|
116
117
|
getUnambiguousTargetArrayType(targetType: types.Type | undefined): types.Type | undefined;
|
117
118
|
getEnumeratorElementType(node: tree.Node): types.Type | undefined;
|
118
|
-
|
119
|
-
|
119
|
+
resolveFunctionOverloadByCallExpression<TCandidate extends operationOverloadResolver.ICandidate<TValueParameter>, TValueParameter extends operationOverloadResolver.IValueParameter>(candidates: readonly TCandidate[], node: tree.CallExpression): readonly TCandidate[];
|
120
|
+
resolveFunctionOverloadByTargetType<TCandidate extends operationOverloadResolver.ICandidate<TValueParameter>, TValueParameter extends operationOverloadResolver.IValueParameter>(candidates: readonly TCandidate[], targetType: types.FunctionType): readonly TCandidate[];
|
120
121
|
resolveConstructorOverload<TCandidate extends constructorOverloadResolver.ICandidate<TValueParameter>, TValueParameter extends constructorOverloadResolver.IValueParameter>(candidates: readonly TCandidate[], args: readonly tree.Argument[]): readonly TCandidate[];
|
121
122
|
resolveTypeOverloadByArgumentCount<TCandidate extends typeOverloadResolver.ICandidate>(candidates: readonly TCandidate[], argumentCount: number): readonly TCandidate[];
|
122
|
-
|
123
|
+
resolveMemberAccessExpression(node: tree.MemberAccessExpression, targetTypeHint?: TargetTypeHint): memberAccessExpressionResolution.ResolutionResult;
|
123
124
|
enumeratePackageImports(packageImportDirectives: Iterable<tree.PackageImportDirective>): Iterable<tree.PackageImport>;
|
124
125
|
getSourceFileMembers(node: tree.SourceFile): ActualSourceFileMembers;
|
125
126
|
getCallExpressionMeaning(node: tree.CallExpression): callExpressionMeaning.Meaning;
|
@@ -161,7 +162,7 @@ export declare class Analyzer {
|
|
161
162
|
*/
|
162
163
|
isExpressionOptionalChainingSyntactically(node: tree.Expression): boolean;
|
163
164
|
isExpressionValidOutermostOptionalChaining(node: tree.Expression): boolean;
|
164
|
-
|
165
|
+
includeNoneToTypeIfExpressionValidOutermostOptionalChaining(type: types.Type, node: tree.Expression): types.Type;
|
165
166
|
checkIdentifierNameIsReserved(name: string, locale: PackageLocale): ReservedIdentifierKind | undefined;
|
166
167
|
getReservedIdentifierName(reservedIdentifierKind: ReservedIdentifierKind, locale: PackageLocale): string;
|
167
168
|
createNameFromIdentifier(node: tree.Identifier): Name;
|
@@ -171,7 +172,7 @@ export declare class Analyzer {
|
|
171
172
|
typeIsValidBaseAspectType(type: types.Type): boolean;
|
172
173
|
getImplicitBaseTypeForStructuredType(entity: e.StructuredTypeEntity): types.StructuredType | undefined;
|
173
174
|
getImplicitBaseTypeForVariantType(): types.StructuredType;
|
174
|
-
|
175
|
+
getImplicitBaseTypeForFunctionType(): types.StructuredType;
|
175
176
|
resolveNamedTypeSpecifier(node: tree.NamedTypeSpecifier): NamedTypeSpecifierResolutionResult;
|
176
177
|
checkExpressionDenotesType(expression: tree.Expression): {
|
177
178
|
type: types.Type | undefined;
|
@@ -179,7 +180,7 @@ export declare class Analyzer {
|
|
179
180
|
checkExpressionDenotesPackageAlias(expression: tree.Expression): {
|
180
181
|
packageAlias: e.PackageAliasEntity;
|
181
182
|
} | undefined;
|
182
|
-
|
183
|
+
checkExpressionDenotesFunction(expression: tree.Expression): ExpressionDenotesFunctionCheckResult | undefined;
|
183
184
|
checkExpressionDenotesOperator(expression: tree.Expression): ExpressionDenotesOperatorCheckResult | undefined;
|
184
185
|
checkExpressionDenotesPackageNameSegment(expression: tree.Expression): {
|
185
186
|
packageTreeNode: PackageNameTreeNode;
|
@@ -194,7 +195,7 @@ export declare class Analyzer {
|
|
194
195
|
getBinaryOperatorKindIfCompoundAssignmentOperator(operator: tree.AssignmentStatementOperator): BinaryOperatorKind | undefined;
|
195
196
|
getPackageEntities(): readonly e.PackageEntity[];
|
196
197
|
getPackageEntity(name: PackageName): e.PackageEntity | undefined;
|
197
|
-
|
198
|
+
createFunctionTypeInvokeMethod(entity: e.FunctionTypeEntity): e.MethodEntity;
|
198
199
|
/**
|
199
200
|
* Преобразует тип таким образом, чтобы он не мог содержать значение `пусто`.
|
200
201
|
* После преобразования метод `canTypeBeNone` вернёт `true` для полученного типа.
|
@@ -223,7 +224,7 @@ export declare class Analyzer {
|
|
223
224
|
* - Т: Объект? -> (Т: Объект?) | Пусто (см. метод isNoneAssignableToType)
|
224
225
|
* - Т: Объект -> (Т: Объект) | Пусто
|
225
226
|
*/
|
226
|
-
|
227
|
+
includeNoneToType(type: types.Type): types.Type;
|
227
228
|
/**
|
228
229
|
* Отвечает на вопрос "Совместим ли тип `Пусто` с данным типом?" (Можно ли присвоить `пусто` в переменную с данным типом?).
|
229
230
|
* @example Для следующих типов метод вернёт:
|
@@ -233,15 +234,14 @@ export declare class Analyzer {
|
|
233
234
|
*/
|
234
235
|
isNoneAssignableToType(type: types.Type): boolean;
|
235
236
|
excludeTypeFromUnion(initialType: types.Type, excludedType: types.Type): types.Type;
|
236
|
-
|
237
|
+
isValueParameterVariadic(entity: e.VariableEntity): boolean;
|
237
238
|
getDefaultTypeParameterConstraint(): types.Type;
|
238
|
-
|
239
|
-
|
239
|
+
getOriginalSignatureTypeOfFunctionEntity(entity: e.FunctionEntity): types.FunctionType;
|
240
|
+
getFunctionBlockLiteralValueParameters(node: tree.FunctionBlockLiteral): readonly e.VariableEntity[];
|
240
241
|
getExtendedType(node: tree.TypeExtensionDeclaration): WithDiagnostics<e.NamedTypeEntity>;
|
241
242
|
getAnalyzedTranslationPackageIfTargetResolved(package_: project.TranslationPackage): AnalyzedTranslationPackage | undefined;
|
242
243
|
getAnalyzedTranslationPackageForPackage(entity: e.PackageEntity, locale: PackageLocale): AnalyzedTranslationPackage | undefined;
|
243
244
|
enumerateAnalyzedTranslationPackages(): Iterable<AnalyzedTranslationPackage>;
|
244
|
-
getCommonObjectAndAspectTypesOfUnion(_unionType: types.UnionType): readonly types.StructuredType[];
|
245
245
|
getLinkedMultiPlatformPackagesByPlatform(entity: e.PackageEntity): ReadonlyMap<PlatformKind, LinkedMultiPlatformPackage> | undefined;
|
246
246
|
getLinkedMultiPlatformPackage(entity: e.PackageEntity, platform: PlatformKind): LinkedMultiPlatformPackage | undefined;
|
247
247
|
createPackageMembers(pkg: SourcePackage): OriginalPackageMembers;
|
@@ -253,17 +253,21 @@ export declare class Analyzer {
|
|
253
253
|
isFunctionResultNone(node: tree.FunctionBlock): boolean;
|
254
254
|
isExpressionImplicitlyReturnedFromSubprogram(node: tree.ExpressionStatement): boolean;
|
255
255
|
createBackingPackageVariables(declaredMembers: readonly (e.NamedPackageMemberEntity | e.PackageAliasEntity)[], pkg: e.PackageEntity): e.PackageVariableEntity[];
|
256
|
-
|
256
|
+
createBackingFields(declaredMembers: readonly NamedTypeMemberEntity[], type: e.TypeEntity): e.FieldEntity[];
|
257
257
|
createNodeDiagnostic(code: DiagnosticCode, node: tree.Node, formatArguments?: readonly string[], kind?: DiagnosticKind, flags?: DiagnosticFlags): Diagnostic;
|
258
258
|
createSourceFileRangeDiagnostic(code: DiagnosticCode, range: Range, nodeOrSourceFile: tree.Node | project.SourceFile, formatArguments?: readonly string[], kind?: DiagnosticKind, flags?: DiagnosticFlags): Diagnostic;
|
259
259
|
createDiagnostic(code: DiagnosticCode, location: DiagnosticLocation | undefined, formatArguments?: readonly string[], kind?: DiagnosticKind, flags?: DiagnosticFlags): Diagnostic;
|
260
260
|
createNodeDiagnosticLocation(node: tree.Node): DiagnosticLocation;
|
261
261
|
getDeclaredTypeMemberEntities(node: tree.TypeMemberDeclarationBlock): DeclaredTypeMemberEntities;
|
262
|
-
getRedefinableMethodOfOriginalTypeForRedefinableMethodOfAliasType(entity: e.
|
263
|
-
checkBodyOfRedefinableAliasTypeMethod(node: tree.
|
264
|
-
redefinableMethodOfOriginalType: e.
|
262
|
+
getRedefinableMethodOfOriginalTypeForRedefinableMethodOfAliasType(entity: e.MethodEntity): e.MethodEntity | undefined;
|
263
|
+
checkBodyOfRedefinableAliasTypeMethod(node: tree.MethodDeclaration, diagnostics?: DiagnosticAcceptor): {
|
264
|
+
redefinableMethodOfOriginalType: e.MethodEntity;
|
265
265
|
} | undefined;
|
266
|
-
getControlFlowGraph(sourceFile: project.SourceFile):
|
266
|
+
getControlFlowGraph(sourceFile: project.SourceFile): controlFlow.GraphBuildResult;
|
267
|
+
createAmbiguousEntityAccessDiagnostic(entities: readonly WithLocalization<e.Entity>[], lctx: LocalizationContext, node: tree.Node): Diagnostic;
|
268
|
+
createAmbiguousFunctionAccessDiagnostic(functions: readonly WithLocalization<AccessedFunction>[], lctx: LocalizationContext, node: tree.Node): Diagnostic;
|
269
|
+
createAmbiguousTypeMemberAccessDiagnostic(members: readonly WithLocalization<types.TypeMember>[], lctx: LocalizationContext, node: tree.Node): Diagnostic;
|
270
|
+
createAmbiguousNamedScopeDeclarationAccessDiagnostic(declarations: readonly WithLocalization<scope.NamedDeclaration>[], lctx: LocalizationContext, node: tree.Node): Diagnostic;
|
267
271
|
private createTsInterop;
|
268
272
|
}
|
269
273
|
export declare class TsInteropInputs {
|
@@ -292,15 +296,16 @@ export declare const enum SyntacticAccessKind {
|
|
292
296
|
declare class Type {
|
293
297
|
private readonly _analyzer;
|
294
298
|
private readonly _unionTypeSpecifierTypes;
|
295
|
-
private readonly
|
296
|
-
private readonly
|
299
|
+
private readonly _intersectionTypeSpecifierTypes;
|
300
|
+
private readonly _functionLiteralTypes;
|
301
|
+
private readonly _functionBlockLiteralTypes;
|
297
302
|
constructor(_analyzer: Analyzer);
|
298
303
|
ofExpression(node: tree.Expression, targetTypeHint?: TargetTypeHint): types.Type;
|
299
304
|
ofTypeSpecifier(node: tree.TypeSpecifier): types.Type;
|
300
|
-
|
305
|
+
ofAccessedFunction(accessedFunction: WithLocalization<AccessedFunction>): types.Type;
|
301
306
|
ofAccessedOperator(operator: WithLocalization<types.Operator>): types.Type;
|
302
|
-
|
303
|
-
|
307
|
+
ofFunctionBlockLiteral(node: tree.FunctionBlockLiteral, targetTypeHint?: TargetTypeHint): types.FunctionType;
|
308
|
+
ofFunctionLiteral(node: tree.FunctionLiteral, targetTypeHint?: TargetTypeHint): types.FunctionType;
|
304
309
|
private ofArrayLiteral;
|
305
310
|
private ofAssertionExpression;
|
306
311
|
private ofAssumptionExpression;
|
@@ -313,7 +318,7 @@ declare class Type {
|
|
313
318
|
private ofIsExpression;
|
314
319
|
private ofParenthesizedExpression;
|
315
320
|
private ofPrefixUnaryExpression;
|
316
|
-
private
|
321
|
+
private ofMemberAccessExpression;
|
317
322
|
private ofReferenceExpression;
|
318
323
|
private ofDereferenceExpression;
|
319
324
|
private ofWhenTernaryExpression;
|
@@ -330,29 +335,30 @@ declare class Type {
|
|
330
335
|
private ofParenthesizedTypeSpecifier;
|
331
336
|
private ofNullableTypeSpecifier;
|
332
337
|
private ofUnionTypeSpecifier;
|
338
|
+
private ofIntersectionTypeSpecifier;
|
333
339
|
private ofInvalidTypeSpecifier;
|
334
|
-
private
|
335
|
-
private
|
336
|
-
private
|
340
|
+
private getTargetlessFunctionBlockLiteralType;
|
341
|
+
private inferFunctionLiteralTypeFromNodeWithFallbackToTargetType;
|
342
|
+
private inferFunctionLiteralTypeFromNode;
|
337
343
|
private getNarrowedTypeIfNarrowableReference;
|
338
344
|
}
|
339
345
|
declare class ReturnType {
|
340
346
|
private readonly _analyzer;
|
341
347
|
constructor(_analyzer: Analyzer);
|
342
|
-
|
343
|
-
|
344
|
-
|
345
|
-
|
346
|
-
|
347
|
-
|
348
|
-
|
348
|
+
ofAnonymousFunctionTypeDeclaration(node: tree.AnonymousFunctionTypeDeclaration): types.Type;
|
349
|
+
ofFunctionBlockLiteral(node: tree.FunctionBlockLiteral): types.Type;
|
350
|
+
ofPackageFunctionDeclaration(node: tree.PackageFunctionDeclaration): types.Type;
|
351
|
+
ofPackageFunctionTypeDeclaration(node: tree.PackageFunctionTypeDeclaration): types.Type;
|
352
|
+
ofNestedFunctionDeclaration(node: tree.NestedFunctionDeclaration): types.Type;
|
353
|
+
ofFunctionLiteral(node: tree.FunctionLiteral): types.Type;
|
354
|
+
ofMethodDeclaration(node: tree.MethodDeclaration): types.Type;
|
349
355
|
ofOperatorDeclaration(node: tree.OperatorDeclaration): types.Type;
|
350
356
|
}
|
351
357
|
declare class Entity {
|
352
358
|
private readonly _analyzer;
|
353
359
|
private readonly _packageEntities;
|
354
360
|
private readonly _packageVariableEntities;
|
355
|
-
private readonly
|
361
|
+
private readonly _fieldEntities;
|
356
362
|
private readonly _parameterVariableEntities;
|
357
363
|
private readonly _localVariableEntities;
|
358
364
|
private readonly _typeParameterEntities;
|
@@ -362,12 +368,12 @@ declare class Entity {
|
|
362
368
|
private readonly _anonymousStructuredTypeEntities;
|
363
369
|
private readonly _packageVariantTypeEntities;
|
364
370
|
private readonly _anonymousVariantTypeEntities;
|
365
|
-
private readonly
|
366
|
-
private readonly
|
371
|
+
private readonly _packageFunctionTypeEntities;
|
372
|
+
private readonly _anonymousFunctionTypeEntities;
|
367
373
|
private readonly _aliasTypeEntities;
|
368
|
-
private readonly
|
369
|
-
private readonly
|
370
|
-
private readonly
|
374
|
+
private readonly _packageFunctionEntities;
|
375
|
+
private readonly _methodEntities;
|
376
|
+
private readonly _nestedFunctionEntities;
|
371
377
|
private readonly _constructorEntities;
|
372
378
|
private readonly _operatorEntities;
|
373
379
|
private readonly _destructorEntities;
|
@@ -379,49 +385,49 @@ declare class Entity {
|
|
379
385
|
ofPackage(pkg: SourcePackage): e.PackageEntity;
|
380
386
|
ofPackageVariableDeclaration(node: tree.PackageVariableDeclaration): e.PackageVariableEntity;
|
381
387
|
ofComputedPackageVariableDeclaration(node: PackageVariableAccessorDeclaration): e.PackageVariableEntity;
|
382
|
-
|
383
|
-
|
388
|
+
ofFieldDeclaration(node: tree.FieldDeclaration): e.FieldEntity;
|
389
|
+
ofComputedFieldDeclaration(node: FieldAccessorDeclaration): e.FieldEntity;
|
384
390
|
ofLocalVariableDeclaration(node: tree.LocalVariableDeclaration): e.LocalVariableEntity;
|
385
391
|
ofEnumerationVariableDeclaration(node: tree.EnumerationVariableDeclaration): e.LocalVariableEntity;
|
386
392
|
ofErrorVariableDeclaration(node: tree.ErrorVariableDeclaration): e.LocalVariableEntity;
|
387
393
|
ofParameterDeclaration(node: tree.ParameterDeclaration): e.ParameterVariableEntity;
|
388
394
|
ofTypeParameterDeclaration(node: tree.TypeParameterDeclaration): e.TypeParameterEntity;
|
389
|
-
|
390
|
-
|
395
|
+
ofIndexerDeclaration(node: IndexedElementAccessorDeclaration): e.SourceIndexerEntity;
|
396
|
+
ofDereferenceOperatorDeclaration(node: DereferencedVariableAccessorDeclaration): e.DereferenceOperatorEntity;
|
391
397
|
ofPackageStructuredTypeDeclaration(node: tree.PackageStructuredTypeDeclaration): e.PackageStructuredTypeEntity;
|
392
398
|
ofAnonymousStructuredTypeDeclaration(node: tree.AnonymousStructuredTypeDeclaration): e.AnonymousStructuredTypeEntity;
|
393
399
|
ofStructuredTypeDeclaration(node: StructuredTypeDeclaration): e.StructuredTypeEntity;
|
394
|
-
|
395
|
-
|
396
|
-
|
400
|
+
ofPackageFunctionTypeDeclaration(node: tree.PackageFunctionTypeDeclaration): e.PackageFunctionTypeEntity;
|
401
|
+
ofAnonymousFunctionTypeDeclaration(node: tree.AnonymousFunctionTypeDeclaration): e.AnonymousFunctionTypeEntity;
|
402
|
+
ofFunctionTypeDeclaration(node: FunctionTypeDeclaration): e.FunctionTypeEntity;
|
397
403
|
ofPackageVariantTypeDeclaration(node: tree.PackageVariantTypeDeclaration): e.PackageVariantTypeEntity;
|
398
404
|
ofAnonymousVariantTypeDeclaration(node: tree.AnonymousVariantTypeDeclaration): e.AnonymousVariantTypeEntity;
|
399
405
|
ofVariantTypeDeclaration(node: VariantTypeDeclaration): e.VariantTypeEntity;
|
400
406
|
ofPackageAliasTypeDeclaration(node: tree.PackageAliasTypeDeclaration): e.AliasTypeEntity;
|
401
|
-
|
402
|
-
|
403
|
-
|
407
|
+
ofPackageFunctionDeclaration(node: tree.PackageFunctionDeclaration): e.PackageFunctionEntity;
|
408
|
+
ofMethodDeclaration(node: tree.MethodDeclaration): e.MethodEntity;
|
409
|
+
ofNestedFunctionDeclaration(node: tree.NestedFunctionDeclaration): e.NestedFunctionEntity;
|
404
410
|
ofOperatorDeclaration(node: tree.OperatorDeclaration): e.OperatorEntity;
|
405
411
|
ofPackageVariableGetterDeclaration(node: tree.PackageVariableGetterDeclaration): e.GetterEntity;
|
406
|
-
|
407
|
-
|
408
|
-
|
412
|
+
ofFieldGetterDeclaration(node: tree.FieldGetterDeclaration): e.GetterEntity;
|
413
|
+
ofIndexedElementGetterDeclaration(node: tree.IndexedElementGetterDeclaration): e.GetterEntity;
|
414
|
+
ofDereferencedVariableGetterDeclaration(node: tree.DereferencedVariableGetterDeclaration): e.GetterEntity;
|
409
415
|
ofGetterDeclaration(node: GetterDeclaration): e.GetterEntity;
|
410
416
|
ofPackageVariableSetterDeclaration(node: tree.PackageVariableSetterDeclaration): e.SetterEntity;
|
411
|
-
|
412
|
-
|
413
|
-
|
417
|
+
ofFieldSetterDeclaration(node: tree.FieldSetterDeclaration): e.SetterEntity;
|
418
|
+
ofIndexedElementSetterDeclaration(node: tree.IndexedElementSetterDeclaration): e.SetterEntity;
|
419
|
+
ofDereferencedVariableSetterDeclaration(node: tree.DereferencedVariableSetterDeclaration): e.SetterEntity;
|
414
420
|
ofSetterDeclaration(node: SetterDeclaration): e.SetterEntity;
|
415
|
-
|
416
|
-
|
417
|
-
ofVariantDeclaration(node: tree.VariantDeclaration): e.
|
421
|
+
ofConstructorDeclaration(node: tree.ConstructorDeclaration): e.ConstructorEntity;
|
422
|
+
ofDestructorDeclaration(node: tree.DestructorDeclaration): e.DestructorEntity;
|
423
|
+
ofVariantDeclaration(node: tree.VariantDeclaration): e.FieldEntity;
|
418
424
|
ofTypeExtensionDeclaration(node: tree.TypeExtensionDeclaration): e.TypeExtensionEntity;
|
419
425
|
ofPackageImport(node: tree.PackageImport): e.PackageAliasEntity;
|
420
426
|
private getContainingPackageLoadedFromDts;
|
421
|
-
private
|
422
|
-
private
|
423
|
-
private
|
424
|
-
private
|
427
|
+
private createComputedFieldEntities;
|
428
|
+
private createDereferenceOperatorEntities;
|
429
|
+
private createIndexerEntities;
|
430
|
+
private areIndexedElementAccessorDeclarationsEqual;
|
425
431
|
}
|
426
432
|
type EntityClassMembers = Entity[keyof Entity];
|
427
433
|
type GetNodesFromMethodsParameter<T> = T extends (node: infer TNode) => e.Entity ? (TNode extends tree.Node ? TNode : never) : never;
|
@@ -430,16 +436,16 @@ declare class ResultLocalVariableEntity {
|
|
430
436
|
private readonly _analyzer;
|
431
437
|
private readonly _entities;
|
432
438
|
constructor(_analyzer: Analyzer);
|
433
|
-
|
434
|
-
|
435
|
-
|
436
|
-
|
437
|
-
|
439
|
+
ofPackageFunctionDeclaration(node: tree.PackageFunctionDeclaration): e.LocalVariableEntity;
|
440
|
+
ofMethodDeclaration(node: tree.MethodDeclaration): e.LocalVariableEntity;
|
441
|
+
ofNestedFunctionDeclaration(node: tree.NestedFunctionDeclaration): e.LocalVariableEntity;
|
442
|
+
ofFunctionLiteral(node: tree.FunctionLiteral): e.LocalVariableEntity;
|
443
|
+
ofFunctionBlockLiteral(node: tree.FunctionBlockLiteral): e.LocalVariableEntity;
|
438
444
|
ofOperatorDeclaration(node: tree.OperatorDeclaration): e.LocalVariableEntity;
|
439
445
|
ofPackageVariableGetterDeclaration(node: tree.PackageVariableGetterDeclaration): e.LocalVariableEntity;
|
440
|
-
|
441
|
-
|
442
|
-
|
446
|
+
ofFieldGetterDeclaration(node: tree.FieldGetterDeclaration): e.LocalVariableEntity;
|
447
|
+
ofIndexedElementGetterDeclaration(node: tree.IndexedElementGetterDeclaration): e.LocalVariableEntity;
|
448
|
+
ofDereferencedVariableGetterDeclaration(node: tree.DereferencedVariableGetterDeclaration): e.LocalVariableEntity;
|
443
449
|
private createResultLocalVariableEntity;
|
444
450
|
}
|
445
451
|
declare class ValueLocalVariableEntity {
|
@@ -447,64 +453,64 @@ declare class ValueLocalVariableEntity {
|
|
447
453
|
private readonly _entities;
|
448
454
|
constructor(_analyzer: Analyzer);
|
449
455
|
ofPackageVariableSetterDeclaration(node: tree.PackageVariableSetterDeclaration): e.VariableEntity;
|
450
|
-
|
451
|
-
|
452
|
-
|
456
|
+
ofFieldSetterDeclaration(node: tree.FieldSetterDeclaration): e.VariableEntity;
|
457
|
+
ofIndexedElementSetterDeclaration(node: tree.IndexedElementSetterDeclaration): e.VariableEntity;
|
458
|
+
ofDereferencedVariableSetterDeclaration(node: tree.DereferencedVariableSetterDeclaration): e.VariableEntity;
|
453
459
|
}
|
454
460
|
declare class Scope {
|
455
461
|
private readonly _analyzer;
|
456
462
|
private readonly _sourceFileScopes;
|
457
|
-
private readonly
|
458
|
-
private readonly
|
459
|
-
private readonly
|
460
|
-
private readonly
|
461
|
-
private readonly
|
462
|
-
private readonly
|
463
|
-
private readonly
|
464
|
-
private readonly
|
463
|
+
private readonly _functionBlockLiteralScopes;
|
464
|
+
private readonly _packageFunctionDeclarationTypeParametersScopes;
|
465
|
+
private readonly _packageFunctionDeclarationValueParametersScopes;
|
466
|
+
private readonly _structuredMethodDeclarationTypeParametersScopes;
|
467
|
+
private readonly _structuredMethodDeclarationValueParametersScopes;
|
468
|
+
private readonly _nestedFunctionDeclarationTypeParametersScopes;
|
469
|
+
private readonly _nestedFunctionDeclarationValueParametersScopes;
|
470
|
+
private readonly _functionLiteralScopes;
|
465
471
|
private readonly _functionBlockScopes;
|
466
472
|
private readonly _statementBlockScopes;
|
467
473
|
private readonly _forEachStatementScopes;
|
468
474
|
private readonly _catchClauseScopes;
|
469
475
|
private readonly _packageStructuredTypeDeclarationTypeParametersScopes;
|
470
476
|
private readonly _structuredTypeDeclarationBodyScopes;
|
471
|
-
private readonly
|
472
|
-
private readonly
|
477
|
+
private readonly _packageFunctionTypeDeclarationTypeParametersScopes;
|
478
|
+
private readonly _functionTypeDeclarationBodyScopes;
|
473
479
|
private readonly _packageVariantTypeDeclarationTypeParametersScopes;
|
474
480
|
private readonly _variantTypeDeclarationBodyScopes;
|
475
481
|
private readonly _aliasTypeDeclarationBodyScopes;
|
476
482
|
private readonly _packageAliasTypeDeclarationTypeParametersScopes;
|
477
483
|
private readonly _operatorDeclarationScopes;
|
478
|
-
private readonly
|
479
|
-
private readonly
|
480
|
-
private readonly
|
484
|
+
private readonly _structuredConstructorDeclarationScopes;
|
485
|
+
private readonly _structuredDestructorDeclarationScopes;
|
486
|
+
private readonly _indexedElementAccessorDeclarationParametersScopes;
|
481
487
|
private readonly _typeExtensionDeclarationScopes;
|
482
488
|
constructor(_analyzer: Analyzer);
|
483
489
|
ofSourceFile(node: tree.SourceFile): scope.IScope;
|
484
|
-
|
485
|
-
|
486
|
-
|
487
|
-
|
488
|
-
|
489
|
-
|
490
|
-
|
491
|
-
|
490
|
+
ofFunctionBlockLiteral(node: tree.FunctionBlockLiteral): scope.IScope;
|
491
|
+
ofPackageFunctionDeclarationTypeParameters(node: tree.PackageFunctionDeclaration): scope.IScope;
|
492
|
+
ofPackageFunctionDeclarationValueParameters(node: tree.PackageFunctionDeclaration): scope.IScope;
|
493
|
+
ofMethodDeclarationTypeParameters(node: tree.MethodDeclaration): scope.IScope;
|
494
|
+
ofMethodDeclarationValueParameters(node: tree.MethodDeclaration): scope.IScope;
|
495
|
+
ofNestedFunctionDeclarationTypeParameters(node: tree.NestedFunctionDeclaration): scope.IScope;
|
496
|
+
ofNestedFunctionDeclarationValueParameters(node: tree.NestedFunctionDeclaration): scope.IScope;
|
497
|
+
ofFunctionLiteral(node: tree.FunctionLiteral): scope.IScope;
|
492
498
|
ofFunctionBlock(node: tree.FunctionBlock): scope.IScope;
|
493
499
|
ofStatementBlock(node: tree.StatementBlock): scope.IScope;
|
494
500
|
ofForStatement(node: tree.ForStatement): scope.IScope;
|
495
501
|
ofCatchClause(node: tree.CatchClause): scope.IScope;
|
496
502
|
ofPackageStructuredTypeDeclarationTypeParameters(node: tree.PackageStructuredTypeDeclaration): scope.IScope;
|
497
503
|
ofStructuredTypeDeclarationBody(node: tree.StructuredTypeDeclarationBody): scope.IScope;
|
498
|
-
|
499
|
-
|
504
|
+
ofPackageFunctionTypeDeclarationTypeParameters(node: tree.PackageFunctionTypeDeclaration): scope.IScope;
|
505
|
+
ofFunctionTypeDeclarationBody(node: tree.FunctionTypeDeclarationBody): scope.IScope;
|
500
506
|
ofPackageVariantTypeDeclarationTypeParameters(node: tree.PackageVariantTypeDeclaration): scope.IScope;
|
501
507
|
ofVariantTypeDeclarationBody(node: tree.VariantTypeDeclarationBody): scope.IScope;
|
502
508
|
ofAliasTypeDeclarationBody(node: tree.AliasTypeDeclarationBody): scope.IScope;
|
503
509
|
ofPackageAliasTypeDeclarationTypeParameters(node: tree.PackageAliasTypeDeclaration): scope.IScope;
|
504
510
|
ofOperatorDeclaration(node: tree.OperatorDeclaration): scope.IScope;
|
505
|
-
|
506
|
-
|
507
|
-
|
511
|
+
ofConstructorDeclaration(node: tree.ConstructorDeclaration): scope.IScope;
|
512
|
+
ofDestructorDeclaration(node: tree.DestructorDeclaration): scope.IScope;
|
513
|
+
ofIndexedElementAccessorDeclarationParameters(node: IndexedElementAccessorDeclaration): scope.IScope;
|
508
514
|
ofTypeExtensionDeclaration(node: tree.TypeExtensionDeclaration): scope.IScope;
|
509
515
|
}
|
510
516
|
declare class DefaultConstructors {
|
@@ -518,11 +524,11 @@ declare class DefaultConstructors {
|
|
518
524
|
declare class OverriddenMember {
|
519
525
|
private readonly _analyzer;
|
520
526
|
constructor(_analyzer: Analyzer);
|
521
|
-
getOverriddenVariables(node: tree.
|
522
|
-
getOverriddenMethods(node: tree.
|
527
|
+
getOverriddenVariables(node: tree.FieldDeclaration | FieldAccessorDeclaration): types.Variable[];
|
528
|
+
getOverriddenMethods(node: tree.MethodDeclaration): types.Method[];
|
523
529
|
getOverriddenOperators(node: tree.OperatorDeclaration): types.Operator[];
|
524
|
-
getOverriddenIndexers(node:
|
525
|
-
getOverriddenDereferenceOperators(node:
|
530
|
+
getOverriddenIndexers(node: IndexedElementAccessorDeclaration): types.Indexer[];
|
531
|
+
getOverriddenDereferenceOperators(node: DereferencedVariableAccessorDeclaration): types.DereferenceOperator[];
|
526
532
|
private findOverriddenVariableInType;
|
527
533
|
private findOverriddenMethodInType;
|
528
534
|
private findOverriddenOperatorInType;
|
@@ -555,9 +561,9 @@ declare class LinkedEntity {
|
|
555
561
|
ofTypeWithMembers(entity: e.TypeEntityWithMembers, platform: PlatformKind): e.TypeEntityWithMembers | undefined;
|
556
562
|
ofParameterType(entity: e.TypeParameterEntity, platform: PlatformKind): e.TypeParameterEntity | undefined;
|
557
563
|
ofPackageVariable(entity: e.PackageVariableEntity, platform: PlatformKind): e.PackageVariableEntity | undefined;
|
558
|
-
|
559
|
-
|
560
|
-
|
564
|
+
ofPackageFunction(entity: e.PackageFunctionEntity, platform: PlatformKind): e.PackageFunctionEntity | undefined;
|
565
|
+
ofField(entity: e.FieldEntity, platform: PlatformKind): e.FieldEntity | undefined;
|
566
|
+
ofMethod(entity: e.MethodEntity, platform: PlatformKind): e.MethodEntity | undefined;
|
561
567
|
ofOperator(entity: e.OperatorEntity, platform: PlatformKind): e.OperatorEntity | undefined;
|
562
568
|
ofConstructor(entity: e.ConstructorEntity, platform: PlatformKind): e.ConstructorEntity | undefined;
|
563
569
|
ofIndexer(entity: e.IndexerEntity, platform: PlatformKind): e.IndexerEntity | undefined;
|
@@ -576,7 +582,7 @@ export declare class LinkedMultiPlatformPackage {
|
|
576
582
|
private get memberLookup();
|
577
583
|
constructor(analyzer: Analyzer, pkg: e.PackageEntity, implementationPackage: e.PackageEntity, targetPlatform: PlatformKind);
|
578
584
|
getLinkedVariable(entity: e.PackageVariableEntity): e.PackageVariableEntity | undefined;
|
579
|
-
getLinkedMethod(entity: e.
|
585
|
+
getLinkedMethod(entity: e.PackageFunctionEntity): e.PackageFunctionEntity | undefined;
|
580
586
|
getLinkedTypeWithMembers(entity: e.TypeEntityWithMembers): LinkedTypeWithMembers | undefined;
|
581
587
|
getLinkedParameterType(entity: e.TypeParameterEntity): e.TypeParameterEntity | undefined;
|
582
588
|
/**
|
@@ -596,8 +602,8 @@ export declare class LinkedTypeWithMembers {
|
|
596
602
|
private readonly _memberLookup;
|
597
603
|
private get memberLookup();
|
598
604
|
constructor(analyzer: Analyzer, externalType: e.TypeEntityWithMembers, targetType: e.TypeEntityWithMembers, linkedPackage: LinkedMultiPlatformPackage);
|
599
|
-
getLinkedVariable(entity: e.
|
600
|
-
getLinkedMethod(entity: e.
|
605
|
+
getLinkedVariable(entity: e.FieldEntity): e.FieldEntity | undefined;
|
606
|
+
getLinkedMethod(entity: e.MethodEntity): e.MethodEntity | undefined;
|
601
607
|
getLinkedOperator(entity: e.OperatorEntity): e.OperatorEntity | undefined;
|
602
608
|
getLinkedConstructor(entity: e.ConstructorEntity): e.ConstructorEntity | undefined;
|
603
609
|
getLinkedIndexer(entity: e.IndexerEntity): e.IndexerEntity | undefined;
|
@@ -616,7 +622,7 @@ export declare enum TypeAssignabilityFlags {
|
|
616
622
|
NotAssignable = 0,
|
617
623
|
Identity = 1,
|
618
624
|
DerivedToBase = 2,
|
619
|
-
|
625
|
+
FunctionTypes = 4,
|
620
626
|
ImplicitConversion = 8,
|
621
627
|
First = 1,
|
622
628
|
Last = 8
|
@@ -652,11 +658,20 @@ export declare class PackageImportInfo {
|
|
652
658
|
readonly isAliasedImport: e.PackageAliasEntity | undefined;
|
653
659
|
constructor(entity: e.PackageEntity, translationPackage: AnalyzedTranslationPackage | undefined, isAliasedImport: e.PackageAliasEntity | undefined);
|
654
660
|
}
|
655
|
-
export declare class
|
656
|
-
|
657
|
-
|
658
|
-
|
659
|
-
|
661
|
+
export declare class TypeUtils {
|
662
|
+
private readonly _analyzer;
|
663
|
+
constructor(_analyzer: Analyzer);
|
664
|
+
getCommonObjectAndAspectTypesOfUnion(unionType: types.UnionType): readonly types.StructuredType[];
|
665
|
+
private getTypesForCommonTypesSearch;
|
666
|
+
private addTypeAndCollectAllBaseTypes;
|
667
|
+
private addTypeIfUnique;
|
668
|
+
private removeBaseTypes;
|
669
|
+
}
|
670
|
+
export declare class ExpressionDenotesFunctionCheckResult {
|
671
|
+
readonly candidates: readonly WithLocalization<AccessedFunction>[];
|
672
|
+
readonly suitableFunctions: readonly WithLocalization<AccessedFunction>[];
|
673
|
+
get singleSuitableFunction(): WithLocalization<AccessedFunction> | undefined;
|
674
|
+
constructor(candidates: readonly WithLocalization<AccessedFunction>[], suitableFunctions: readonly WithLocalization<AccessedFunction>[]);
|
660
675
|
}
|
661
676
|
export declare class ExpressionDenotesOperatorCheckResult {
|
662
677
|
readonly candidates: readonly WithLocalization<types.Operator>[];
|
@@ -693,14 +708,14 @@ declare namespace AvailablePackage {
|
|
693
708
|
export {};
|
694
709
|
}
|
695
710
|
export declare class DeclaredTypeMemberEntities {
|
696
|
-
readonly variables: readonly e.
|
697
|
-
readonly methods: readonly e.
|
711
|
+
readonly variables: readonly e.FieldEntity[];
|
712
|
+
readonly methods: readonly e.MethodEntity[];
|
698
713
|
readonly operators: readonly e.OperatorEntity[];
|
699
714
|
readonly constructors: readonly e.ConstructorEntity[];
|
700
715
|
readonly destructors: readonly e.DestructorEntity[];
|
701
716
|
readonly indexers: readonly e.SourceIndexerEntity[];
|
702
717
|
readonly dereferenceOperators: readonly e.DereferenceOperatorEntity[];
|
703
718
|
get namedMembers(): NamedTypeMemberEntity[];
|
704
|
-
constructor(variables: readonly e.
|
719
|
+
constructor(variables: readonly e.FieldEntity[], methods: readonly e.MethodEntity[], operators: readonly e.OperatorEntity[], constructors: readonly e.ConstructorEntity[], destructors: readonly e.DestructorEntity[], indexers: readonly e.SourceIndexerEntity[], dereferenceOperators: readonly e.DereferenceOperatorEntity[]);
|
705
720
|
}
|
706
721
|
export {};
|
@@ -1,7 +1,7 @@
|
|
1
1
|
import { Diagnostic } from '../diagnostic/Diagnostic.js';
|
2
2
|
import { CallExpression } from '../tree/index.js';
|
3
3
|
import * as types from '../types/index.js';
|
4
|
-
import {
|
4
|
+
import { AccessedFunction } from './AccessedFunction.js';
|
5
5
|
import { FoundAnonymousDeclaration } from './FoundDeclaration.js';
|
6
6
|
import { WithLocalization } from './Localization.js';
|
7
7
|
import { Analyzer } from './index.js';
|
@@ -14,21 +14,21 @@ export declare class Resolver {
|
|
14
14
|
private resolveConstructorCallExpressionMeaning;
|
15
15
|
private getNodeForDiagnostics;
|
16
16
|
}
|
17
|
-
export type Meaning =
|
18
|
-
declare class
|
19
|
-
readonly
|
20
|
-
readonly kind = "
|
21
|
-
constructor(
|
17
|
+
export type Meaning = Meaning_functionCall | Meaning_operatorCall | Meaning_objectFunctionCall | Meaning_constructorCall | Meaning_unresolved;
|
18
|
+
declare class Meaning_functionCall {
|
19
|
+
readonly func: WithLocalization<AccessedFunction>;
|
20
|
+
readonly kind = "function-call";
|
21
|
+
constructor(func: WithLocalization<AccessedFunction>);
|
22
22
|
}
|
23
23
|
declare class Meaning_operatorCall {
|
24
24
|
readonly operator: WithLocalization<types.Operator>;
|
25
25
|
readonly kind = "operator-call";
|
26
26
|
constructor(operator: WithLocalization<types.Operator>);
|
27
27
|
}
|
28
|
-
declare class
|
29
|
-
readonly type: types.
|
30
|
-
readonly kind = "object-
|
31
|
-
constructor(type: types.
|
28
|
+
declare class Meaning_objectFunctionCall {
|
29
|
+
readonly type: types.FunctionType;
|
30
|
+
readonly kind = "object-function-call";
|
31
|
+
constructor(type: types.FunctionType);
|
32
32
|
}
|
33
33
|
declare class Meaning_constructorCall {
|
34
34
|
/**
|