@artel/artc 0.6.26039 → 0.9.26001
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 +19 -15
- package/build/api/ApiNodeJS.js +3 -3
- package/build/api/ApiServices.js +11426 -5066
- package/build/{chunk-LTJPPRSR.js → chunk-FLMCFMMG.js} +87218 -50777
- package/build/{chunk-AEW4TILW.js → chunk-V2TFXOVJ.js} +1 -1
- package/build/{chunk-5VVFNKOH.js → chunk-XMOVE7NP.js} +2 -2
- package/build/types/analysis/Analyzer.d.ts +6 -1
- package/build/types/analysis/TypeMemberLookup.d.ts +3 -1
- package/build/types/analysis/WellKnownDeclarations.d.ts +54 -0
- package/build/types/analysis/a/Analyzer.d.ts +10 -10
- package/build/types/analysis/a/IdentifierExpressionMeaning.d.ts +3 -3
- package/build/types/analysis/a/MemberAccessExpressionMeaning.d.ts +3 -3
- package/build/types/analysis/a/ModifierValidator.d.ts +3 -2
- package/build/types/analysis/a/ResolvedTranslationPackage.d.ts +2 -1
- package/build/types/analysis/a/SourceFileAnalyzer.d.ts +1 -1
- package/build/types/analysis/a/SourcePackageMembersCreator.d.ts +1 -2
- package/build/types/analysis/a/TreeQuery.d.ts +1 -2
- package/build/types/analysis/a/TypeMemberLookup.d.ts +3 -1
- package/build/types/analysis/a/semantic-context/FieldWithInitializerSemanticContext.d.ts +3 -3
- package/build/types/analysis/a/semantic-context/SemanticContext.d.ts +2 -2
- package/build/types/analysis/a/semantic-context/SemanticContextBuilder.d.ts +10 -12
- package/build/types/analysis/a/semantic-context/SpecialLocalDeclarationsBuilder.d.ts +0 -1
- package/build/types/analysis/a/semantic-context/SubprogramBodyAndParametersSemanticContext.d.ts +5 -4
- package/build/types/analysis/a/semantic-context/SubprogramSemanticContext.d.ts +11 -10
- package/build/types/analysis/a/semantic-context/TypeSemanticContext.d.ts +13 -13
- package/build/types/analysis/m/Analyzer.d.ts +425 -1
- package/build/types/analysis/m/ArgumentToParameterMatchResult.d.ts +23 -0
- package/build/types/analysis/m/ArgumentsToParametersMatcher.d.ts +40 -0
- package/build/types/analysis/m/BaseExpressionMeaning.d.ts +25 -0
- package/build/types/analysis/m/CallExpressionMeaning.d.ts +72 -0
- package/build/types/analysis/m/ConstructorCallResolver.d.ts +24 -0
- package/build/types/analysis/m/DeclarationsUsageCounter.d.ts +12 -0
- package/build/types/analysis/m/DereferenceExpressionMeaning.d.ts +28 -0
- package/build/types/analysis/m/ExpressionAnalysisOptions.d.ts +21 -0
- package/build/types/analysis/m/FunctionAccessResolver.d.ts +19 -0
- package/build/types/analysis/m/IdentifierExpressionMeaning.d.ts +137 -0
- package/build/types/analysis/m/IndexedAccessExpressionMeaning.d.ts +32 -0
- package/build/types/analysis/m/InstanceFieldsInitializationValidator.d.ts +18 -0
- package/build/types/analysis/m/MemberAccessExpressionMeaning.d.ts +137 -0
- package/build/types/analysis/m/ModifierFlags.d.ts +20 -0
- package/build/types/analysis/m/NamedTypeResolver.d.ts +44 -0
- package/build/types/analysis/m/NamedTypeSpecifierResolver.d.ts +19 -0
- package/build/types/analysis/m/ObjectExpressionMeaning.d.ts +29 -0
- package/build/types/analysis/m/OverloadResolver.d.ts +104 -0
- package/build/types/analysis/m/OwnAndBaseConstructorCallsChecker.d.ts +36 -0
- package/build/types/analysis/m/PackageAndStaticVariablesInitializationValidator.d.ts +17 -0
- package/build/types/analysis/m/ReachabilityChecker.d.ts +27 -0
- package/build/types/analysis/m/ReductionSourceMemberFinder.d.ts +17 -0
- package/build/types/analysis/m/ReservedNameDictionary.d.ts +15 -0
- package/build/types/analysis/m/ResolvedTranslationPackage.d.ts +68 -0
- package/build/types/analysis/m/ReturnTypeInferrer.d.ts +13 -0
- package/build/types/analysis/m/SourceFileAnalyzer.d.ts +131 -0
- package/build/types/analysis/m/SourcePackageMembersCreator.d.ts +7 -0
- package/build/types/analysis/m/SourceTypeMembersCreator.d.ts +9 -0
- package/build/types/analysis/m/StaticDeclarationMeaning.d.ts +32 -0
- package/build/types/analysis/m/SyntacticAccessKind.d.ts +6 -0
- package/build/types/analysis/m/TagMeaning.d.ts +70 -0
- package/build/types/analysis/m/TextIdentity.d.ts +7 -0
- package/build/types/analysis/m/TranslatedEntityNameConflictsValidator.d.ts +28 -0
- package/build/types/analysis/m/TreeQuery.d.ts +15 -0
- package/build/types/analysis/m/TypeArgumentInferrer.d.ts +52 -0
- package/build/types/analysis/m/TypeInferrer.d.ts +11 -0
- package/build/types/analysis/m/TypeMemberLookup.d.ts +4 -1
- package/build/types/analysis/m/TypeNarrower.d.ts +31 -0
- package/build/types/analysis/m/TypeOverloadResolver.d.ts +9 -0
- package/build/types/analysis/m/UserDefinableBinaryOperatorResolver.d.ts +34 -0
- package/build/types/analysis/m/UserDefinableUnaryOperatorResolver.d.ts +23 -0
- package/build/types/analysis/m/VariableIsAssignedChecker.d.ts +11 -0
- package/build/types/analysis/m/VariableIsNotAssignedChecker.d.ts +12 -0
- package/build/types/analysis/m/control-flow/GraphBuilder.d.ts +52 -0
- package/build/types/analysis/m/control-flow/GraphVisualizer.d.ts +12 -0
- package/build/types/analysis/m/control-flow/NarrowableExpression.d.ts +5 -0
- package/build/types/analysis/m/control-flow/NarrowableReference.d.ts +72 -0
- package/build/types/analysis/m/control-flow/Nodes.d.ts +112 -0
- package/build/types/analysis/m/control-flow/index.d.ts +5 -0
- package/build/types/analysis/m/semantic-context/Declarations.d.ts +94 -0
- package/build/types/analysis/m/semantic-context/FieldWithInitializerSemanticContext.d.ts +28 -0
- package/build/types/analysis/m/semantic-context/SemanticContext.d.ts +14 -0
- package/build/types/analysis/m/semantic-context/SemanticContextBase.d.ts +190 -0
- package/build/types/analysis/m/semantic-context/SemanticContextBuilder.d.ts +69 -0
- package/build/types/analysis/m/semantic-context/SemanticContextValidatingNameConflicts.d.ts +51 -0
- package/build/types/analysis/m/semantic-context/SemanticContextWithParent.d.ts +12 -0
- package/build/types/analysis/m/semantic-context/SourceFileSemanticContext.d.ts +63 -0
- package/build/types/analysis/m/semantic-context/StaticDeclarationSemanticContext.d.ts +26 -0
- package/build/types/analysis/m/semantic-context/SubprogramBodyAndParametersSemanticContext.d.ts +108 -0
- package/build/types/analysis/m/semantic-context/SubprogramSemanticContext.d.ts +92 -0
- package/build/types/analysis/m/semantic-context/TypeSemanticContext.d.ts +93 -0
- package/build/types/analysis/m/semantic-context/index.d.ts +10 -0
- package/build/types/common/LocalizationHelper.d.ts +3 -1
- package/build/types/common/LocalizationHelperA.d.ts +0 -2
- package/build/types/common/LocalizationHelperM.d.ts +13 -0
- package/build/types/common/Name.d.ts +1 -1
- package/build/types/common/index.d.ts +1 -0
- package/build/types/diagnostic/DiagnosticCode.d.ts +211 -192
- package/build/types/diagnostic/TokenDiagnosticM.d.ts +2 -0
- package/build/types/emitter/EmitPhaseName.d.ts +2 -2
- package/build/types/emitter/EmitterContext.d.ts +4 -4
- package/build/types/emitter/Entities.d.ts +4 -2
- package/build/types/emitter/IrBuilderM.d.ts +124 -0
- package/build/types/emitter/IrFactory.d.ts +2 -2
- package/build/types/entities/Entity.d.ts +8 -5
- package/build/types/entities/EntityLocalizationContext.d.ts +3 -2
- package/build/types/entities/OperatorKind.d.ts +13 -18
- package/build/types/entities/Translation.d.ts +4 -3
- package/build/types/entities/interfaces/AliasTypeEntity.d.ts +4 -1
- package/build/types/entities/interfaces/DereferenceOperatorEntity.d.ts +3 -1
- package/build/types/entities/interfaces/FunctionEntity.d.ts +3 -1
- package/build/types/entities/interfaces/FunctionTypeEntity.d.ts +3 -1
- package/build/types/entities/interfaces/IndexerEntity.d.ts +4 -1
- package/build/types/entities/interfaces/PackageAliasEntity.d.ts +4 -1
- package/build/types/entities/interfaces/PackageEntity.d.ts +2 -1
- package/build/types/entities/interfaces/ReducedTypeEntity.d.ts +3 -1
- package/build/types/entities/interfaces/StructuredTypeEntity.d.ts +9 -2
- package/build/types/entities/interfaces/TextTranslationEntity.d.ts +4 -1
- package/build/types/entities/interfaces/TypeExtensionEntity.d.ts +4 -1
- package/build/types/entities/interfaces/TypeParameterEntity.d.ts +7 -3
- package/build/types/entities/interfaces/VariableEntity.d.ts +3 -2
- package/build/types/entities/interfaces/VariantTypeEntity.d.ts +3 -1
- package/build/types/entities/interfaces/m/ConstructorEntityM.d.ts +10 -0
- package/build/types/entities/interfaces/m/DestructorEntityM.d.ts +8 -0
- package/build/types/entities/interfaces/m/index.d.ts +2 -0
- package/build/types/entities/source/a/SourceFunctionEntity.d.ts +1 -1
- package/build/types/entities/source/a/SourcePackageEntity.d.ts +2 -1
- package/build/types/entities/source/a/SourceStructuredTypeEntity.d.ts +3 -5
- package/build/types/entities/source/m/SourceAliasTypeEntity.d.ts +32 -0
- package/build/types/entities/source/m/SourceConstructorEntity.d.ts +40 -0
- package/build/types/entities/source/m/SourceDestructorEntity.d.ts +38 -0
- package/build/types/entities/source/m/SourceFunctionEntity.d.ts +252 -0
- package/build/types/entities/source/m/SourceFunctionTypeEntity.d.ts +35 -0
- package/build/types/entities/source/m/SourceGetterEntity.d.ts +122 -0
- package/build/types/entities/source/m/SourceIndexerEntity.d.ts +36 -0
- package/build/types/entities/source/m/SourcePackageAliasEntity.d.ts +22 -0
- package/build/types/entities/source/m/SourcePackageEntity.d.ts +68 -0
- package/build/types/entities/source/m/SourceSetterEntity.d.ts +122 -0
- package/build/types/entities/source/m/SourceStructuredTypeEntity.d.ts +111 -0
- package/build/types/entities/source/m/SourceTextTranslationEntity.d.ts +29 -0
- package/build/types/entities/source/m/SourceTypeParameterEntity.d.ts +30 -0
- package/build/types/entities/source/m/SourceVariableEntity.d.ts +447 -0
- package/build/types/entities/source/m/SourceVariantTypeEntity.d.ts +38 -0
- package/build/types/entities/source/m/index.d.ts +15 -0
- package/build/types/entities/translated/TranslatedPackageEntity.d.ts +2 -1
- package/build/types/entities/translated/TranslatedStructuredTypeEntity.d.ts +33 -1
- package/build/types/entities/translated/source/a/SourceTranslatedPackageStructuredTypeEntity.d.ts +8 -2
- package/build/types/entities/translated/source/m/SourceTranslatedAliasTypeEntity.d.ts +14 -0
- package/build/types/entities/translated/source/m/SourceTranslatedDestructorEntity.d.ts +12 -0
- package/build/types/entities/translated/source/m/SourceTranslatedFunctionEntity.d.ts +24 -0
- package/build/types/entities/translated/source/m/SourceTranslatedFunctionTypeEntity.d.ts +13 -0
- package/build/types/entities/translated/source/m/SourceTranslatedIndexerEntity.d.ts +12 -0
- package/build/types/entities/translated/source/m/SourceTranslatedPackageEntity.d.ts +19 -0
- package/build/types/entities/translated/source/m/SourceTranslatedPackageStructuredTypeEntity.d.ts +26 -0
- package/build/types/entities/translated/source/m/SourceTranslatedPackageVariantTypeEntity.d.ts +14 -0
- package/build/types/entities/translated/source/m/SourceTranslatedReducedTypeEntity.d.ts +14 -0
- package/build/types/entities/translated/source/m/index.d.ts +9 -0
- package/build/types/parser/a/KeywordDictionary.d.ts +2 -3
- package/build/types/parser/a/Parser.d.ts +2 -2
- package/build/types/parser/m/ConvertTokenKind.d.ts +3 -0
- package/build/types/parser/m/KeywordDictionary.d.ts +33 -0
- package/build/types/parser/m/Parser.d.ts +7 -0
- package/build/types/parser/m/Scanner.d.ts +56 -0
- package/build/types/parser/m/TokenKind.d.ts +81 -0
- package/build/types/parser/m/TriviaInterner.d.ts +8 -0
- package/build/types/project/SourceFile.d.ts +5 -6
- package/build/types/services/LanguageServer.d.ts +23 -12
- package/build/types/services/a/NodeSemanticInfo.d.ts +2 -2
- package/build/types/services/common/WorkspaceItemsService.d.ts +1 -0
- package/build/types/services/common/completion/Types.d.ts +8 -2
- package/build/types/services/common/display/DisplayService.d.ts +3 -0
- package/build/types/services/common/display/Types.d.ts +2 -2
- package/build/types/services/m/CodeActionsService.d.ts +10 -0
- package/build/types/services/m/CompletionService.d.ts +60 -0
- package/build/types/services/m/DefinitionService.d.ts +11 -0
- package/build/types/services/m/DisplayService.d.ts +52 -0
- package/build/types/services/m/EvaluatableExpressionService.d.ts +10 -0
- package/build/types/services/m/HoverService.d.ts +11 -0
- package/build/types/services/m/NodeSemanticInfo.d.ts +46 -0
- package/build/types/services/m/RenameService.d.ts +11 -0
- package/build/types/services/m/SelectionRangeService.d.ts +7 -0
- package/build/types/services/m/SemanticTokensService.d.ts +11 -0
- package/build/types/services/m/SourceFileItemsService.d.ts +10 -0
- package/build/types/services/m/TranslationService.d.ts +23 -0
- package/build/types/services/m/TranslationsGenerationService.d.ts +7 -0
- package/build/types/services/m/TreeUtils.d.ts +58 -0
- package/build/types/services/m/references/DefinitionInfoFinder.d.ts +6 -0
- package/build/types/services/m/references/ReferencesFinder.d.ts +7 -0
- package/build/types/services/m/signature-help/ParametersSignatureHelpProvider.d.ts +15 -0
- package/build/types/services/m/signature-help/SignatureHelpService.d.ts +6 -0
- package/build/types/services/m/signature-help/SignatureWithParameters.d.ts +94 -0
- package/build/types/services/m/signature-help/TypeParameterSignatureHelpProvider.d.ts +21 -0
- package/build/types/services/m/signature-help/utils.d.ts +9 -0
- package/build/types/tree/a/KeywordKind.d.ts +1 -3
- package/build/types/tree/a/NodeKind.d.ts +113 -114
- package/build/types/tree/a/Nodes.d.ts +6 -5
- package/build/types/tree/a/OperatorKind.d.ts +5 -0
- package/build/types/tree/a/Types.d.ts +9 -4
- package/build/types/tree/m/BaseNode.d.ts +8 -40
- package/build/types/tree/m/KeywordFlags.d.ts +4 -0
- package/build/types/tree/m/KeywordKind.d.ts +40 -0
- package/build/types/tree/m/NodeKind.d.ts +147 -2
- package/build/types/tree/m/Nodes.d.ts +2064 -9
- package/build/types/tree/m/NodesDebug.d.ts +9 -0
- package/build/types/tree/m/OperatorKind.d.ts +39 -0
- package/build/types/tree/m/SyntaxToCode.d.ts +107 -0
- package/build/types/tree/m/Token.d.ts +46 -0
- package/build/types/tree/m/TokenFlags.d.ts +12 -0
- package/build/types/tree/m/TokenKind.d.ts +61 -60
- package/build/types/tree/m/TreeTraversal.d.ts +18 -0
- package/build/types/tree/m/Types.d.ts +46 -0
- package/build/types/tree/m/Utils.d.ts +7 -0
- package/build/types/tree/m/index.d.ts +9 -0
- package/build/types/types/StandardTypes.d.ts +2 -0
- package/package.json +2 -2
- /package/build/types/diagnostic/{TokenDiagnostic.d.ts → TokenDiagnosticA.d.ts} +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
Compiler
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-V2TFXOVJ.js";
|
|
4
4
|
import {
|
|
5
5
|
ArtelVersion,
|
|
6
6
|
Cached,
|
|
@@ -16,7 +16,7 @@ import {
|
|
|
16
16
|
__async,
|
|
17
17
|
performanceMeasurementStageNames,
|
|
18
18
|
performanceMeasurementStages
|
|
19
|
-
} from "./chunk-
|
|
19
|
+
} from "./chunk-FLMCFMMG.js";
|
|
20
20
|
|
|
21
21
|
// source/executor/FileSystemUri.ts
|
|
22
22
|
import { platform } from "os";
|
|
@@ -39,6 +39,10 @@ export declare abstract class Analyzer {
|
|
|
39
39
|
* Пакет с именем 'Артель', содержащий стандартные типы.
|
|
40
40
|
*/
|
|
41
41
|
get systemPackage(): e.PackageEntity;
|
|
42
|
+
/**
|
|
43
|
+
* Пакет с именем 'Артель.М', содержащий теги для диалекта М.
|
|
44
|
+
*/
|
|
45
|
+
get systemPackageM(): e.PackageEntity;
|
|
42
46
|
/**
|
|
43
47
|
* Стандартные объявления на языке оригинала. Для получения стандартных объявлений на желаемом языке используйте
|
|
44
48
|
* {@link getLocalizedWellKnownDeclarations}.
|
|
@@ -181,6 +185,7 @@ export declare abstract class Analyzer {
|
|
|
181
185
|
export declare class CommonAnalyzerState {
|
|
182
186
|
readonly compilation: project.Compilation;
|
|
183
187
|
systemPackage: e.PackageEntity;
|
|
188
|
+
systemPackageM: e.PackageEntity;
|
|
184
189
|
originalWellKnownDeclarations: WellKnownDeclarations;
|
|
185
190
|
originalStandardTypes: types.StandardTypes;
|
|
186
191
|
typeFactory: TypeFactory;
|
|
@@ -315,7 +320,7 @@ declare class TypeUtils {
|
|
|
315
320
|
removeDerivedTypesInPlace(types: types.Type[]): void;
|
|
316
321
|
getBaseOrAliasedTypes(type: types.Type): readonly types.Type[];
|
|
317
322
|
getPossiblyAliasedBaseObjectType(type: types.Type): types.Type | undefined;
|
|
318
|
-
getPossiblyAliasedBaseObjectTypeOfEntity(type: e.TypeEntity): types.Type | undefined;
|
|
323
|
+
getPossiblyAliasedBaseObjectTypeOfEntity(type: e.TypeEntity | e.TypeExtensionEntity): types.Type | undefined;
|
|
319
324
|
getPossiblyAliasedBaseAspectTypes(type: types.Type): readonly types.Type[] | undefined;
|
|
320
325
|
getBaseObjectTypeOrAliasedType(type: types.Type): types.Type | undefined;
|
|
321
326
|
getBaseAndAliasedTypesRecursively(type: types.Type): readonly types.Type[];
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Name, PackageLocale } from '../common/index.js';
|
|
2
|
-
import { NamedTypeMemberEntity, PackageEntity, TypeEntity, TypeExtensionEntity, TypeOrExtensionEntity } from '../entities/index.js';
|
|
2
|
+
import { NamedTypeMemberEntity, OperatorKind, PackageEntity, TypeEntity, TypeExtensionEntity, TypeOrExtensionEntity } from '../entities/index.js';
|
|
3
3
|
import { TypeMemberKindFlags } from '../entities/TypeMemberKindFlags.js';
|
|
4
4
|
import { SourceFile } from '../project/SourceFile.js';
|
|
5
5
|
import * as types from '../types/index.js';
|
|
@@ -17,6 +17,8 @@ export declare class TypeMemberLookup {
|
|
|
17
17
|
getMatchingNamedMembersByName(name: Name, memberToMatch: NamedTypeMemberEntity, context: TypeMemberLookupContext | undefined, options?: TypeMemberLookupOptions): readonly types.NamedTypeMember[];
|
|
18
18
|
getConstructors(context: TypeMemberLookupContext | undefined, options?: TypeMemberLookupOptions): readonly types.Method[];
|
|
19
19
|
getDestructors(context: TypeMemberLookupContext | undefined, options?: TypeMemberLookupOptions): readonly types.Method[];
|
|
20
|
+
getOperators(context: TypeMemberLookupContext | undefined, options?: TypeMemberLookupOptions): readonly types.Method[];
|
|
21
|
+
getOperatorsByKind(kind: OperatorKind, context: TypeMemberLookupContext | undefined, options?: TypeMemberLookupOptions): readonly types.Method[];
|
|
20
22
|
getIndexers(context: TypeMemberLookupContext | undefined, options?: TypeMemberLookupOptions): readonly types.Indexer[];
|
|
21
23
|
getDereferenceOperators(context: TypeMemberLookupContext | undefined, options?: TypeMemberLookupOptions): readonly types.DereferenceOperator[];
|
|
22
24
|
}
|
|
@@ -38,6 +38,24 @@ export interface WellKnownDeclarations {
|
|
|
38
38
|
readonly builtIntoPlatform: StructuredTypeEntity;
|
|
39
39
|
readonly fieldProxy: StructuredTypeEntity;
|
|
40
40
|
readonly javaScriptDecorator: StructuredTypeEntity;
|
|
41
|
+
readonly typeDesignator: StructuredTypeEntity;
|
|
42
|
+
readonly asFunction: MethodEntity;
|
|
43
|
+
readonly isFunction: MethodEntity;
|
|
44
|
+
readonly tagNewModifierM: StructuredTypeEntity;
|
|
45
|
+
readonly tagPlainM: StructuredTypeEntity;
|
|
46
|
+
readonly tagAspectM: StructuredTypeEntity;
|
|
47
|
+
readonly tagExtensionM: StructuredTypeEntity;
|
|
48
|
+
readonly tagWrapperM: StructuredTypeEntity;
|
|
49
|
+
readonly tagBasicM: StructuredTypeEntity;
|
|
50
|
+
readonly tagOverrideM: StructuredTypeEntity;
|
|
51
|
+
readonly tagAbstractM: StructuredTypeEntity;
|
|
52
|
+
readonly tagHiddenInTypeM: StructuredTypeEntity;
|
|
53
|
+
readonly tagHiddenInTypeHierarchyM: StructuredTypeEntity;
|
|
54
|
+
readonly tagHiddenInFileM: StructuredTypeEntity;
|
|
55
|
+
readonly tagHiddenInPackageM: StructuredTypeEntity;
|
|
56
|
+
readonly tagConstM: StructuredTypeEntity;
|
|
57
|
+
readonly tagAsyncM: StructuredTypeEntity;
|
|
58
|
+
readonly tagIntermediateM: StructuredTypeEntity;
|
|
41
59
|
}
|
|
42
60
|
export declare class LocalizedWellKnownDeclarations implements WellKnownDeclarations {
|
|
43
61
|
private readonly analyzer;
|
|
@@ -73,6 +91,24 @@ export declare class LocalizedWellKnownDeclarations implements WellKnownDeclarat
|
|
|
73
91
|
private builtIntoPlatform_;
|
|
74
92
|
private fieldProxy_;
|
|
75
93
|
private javaScriptDecorator_;
|
|
94
|
+
private typeDesignator_;
|
|
95
|
+
private asFunction_;
|
|
96
|
+
private isFunction_;
|
|
97
|
+
private tagNewModifierM_;
|
|
98
|
+
private tagPlainM_;
|
|
99
|
+
private tagAspectM_;
|
|
100
|
+
private tagExtensionM_;
|
|
101
|
+
private tagWrapperM_;
|
|
102
|
+
private tagBasicM_;
|
|
103
|
+
private tagOverrideM_;
|
|
104
|
+
private tagAbstractM_;
|
|
105
|
+
private tagHiddenInTypeM_;
|
|
106
|
+
private tagHiddenInTypeHierarchyM_;
|
|
107
|
+
private tagHiddenInFileM_;
|
|
108
|
+
private tagHiddenInPackageM_;
|
|
109
|
+
private tagConstM_;
|
|
110
|
+
private tagAsyncM_;
|
|
111
|
+
private tagIntermediateM_;
|
|
76
112
|
constructor(analyzer: Analyzer, locale: PackageLocale);
|
|
77
113
|
get object(): StructuredTypeEntity;
|
|
78
114
|
get structure(): StructuredTypeEntity;
|
|
@@ -105,6 +141,24 @@ export declare class LocalizedWellKnownDeclarations implements WellKnownDeclarat
|
|
|
105
141
|
get builtIntoPlatform(): StructuredTypeEntity;
|
|
106
142
|
get fieldProxy(): StructuredTypeEntity;
|
|
107
143
|
get javaScriptDecorator(): StructuredTypeEntity;
|
|
144
|
+
get typeDesignator(): StructuredTypeEntity;
|
|
145
|
+
get asFunction(): MethodEntity;
|
|
146
|
+
get isFunction(): MethodEntity;
|
|
147
|
+
get tagNewModifierM(): StructuredTypeEntity;
|
|
148
|
+
get tagPlainM(): StructuredTypeEntity;
|
|
149
|
+
get tagAspectM(): StructuredTypeEntity;
|
|
150
|
+
get tagExtensionM(): StructuredTypeEntity;
|
|
151
|
+
get tagWrapperM(): StructuredTypeEntity;
|
|
152
|
+
get tagBasicM(): StructuredTypeEntity;
|
|
153
|
+
get tagOverrideM(): StructuredTypeEntity;
|
|
154
|
+
get tagAbstractM(): StructuredTypeEntity;
|
|
155
|
+
get tagHiddenInTypeM(): StructuredTypeEntity;
|
|
156
|
+
get tagHiddenInTypeHierarchyM(): StructuredTypeEntity;
|
|
157
|
+
get tagHiddenInFileM(): StructuredTypeEntity;
|
|
158
|
+
get tagHiddenInPackageM(): StructuredTypeEntity;
|
|
159
|
+
get tagConstM(): StructuredTypeEntity;
|
|
160
|
+
get tagAsyncM(): StructuredTypeEntity;
|
|
161
|
+
get tagIntermediateM(): StructuredTypeEntity;
|
|
108
162
|
private getLocalizedStructuredType;
|
|
109
163
|
private getLocalizedReducedType;
|
|
110
164
|
private getLocalizedAliasType;
|
|
@@ -34,7 +34,6 @@ import { ReductionSourceMemberFinder } from './ReductionSourceMemberFinder.js';
|
|
|
34
34
|
import { ReservedNameKind } from './ReservedNameDictionary.js';
|
|
35
35
|
import { SyntacticAccessKind } from './SyntacticAccessKind.js';
|
|
36
36
|
import * as tagMeaning from './TagMeaning.js';
|
|
37
|
-
import { TypeWithMembersOrTypeExtensionDeclaration } from './TreeQuery.js';
|
|
38
37
|
import * as controlFlow from './control-flow/index.js';
|
|
39
38
|
import * as semanticContext from './semantic-context/index.js';
|
|
40
39
|
/**
|
|
@@ -175,13 +174,14 @@ export declare class Analyzer extends BaseAnalyzer {
|
|
|
175
174
|
validateSourcePackageMemberConflicts(pkg: project.ProgramOrTextTranslationPackage): readonly Diagnostic[];
|
|
176
175
|
determineUnderlyingTypeOfSourceVariantType(memberList: tree.TypeMemberDeclarationList): types.Type;
|
|
177
176
|
getOwnAndBaseConstructorCallsCheckResult(node: tree.TypeWithMembersDeclaration): OwnAndBaseConstructorCallsCheckResult;
|
|
178
|
-
|
|
177
|
+
isCallingOwnConstructorCorrectly(node: tree.ConstructorDeclaration): boolean;
|
|
178
|
+
isOwnOrBaseConstructorCalledCorrectly(node: tree.OwnConstructorCallExpression | tree.BaseExpression): boolean;
|
|
179
179
|
ifCalleeThenCallExpression(node: tree.Expression): tree.CallExpression | undefined;
|
|
180
180
|
getNodeForAmbiguousAccessDiagnostic(access: tree.Expression): tree.Node;
|
|
181
181
|
isPossibleWrappedTargetTypeDependentFunctionLiteral(node: tree.Expression): boolean;
|
|
182
182
|
isTargetTypeDependentFunctionLiteral(node: tree.Expression): node is tree.RegularOrBlockFunctionLiteral;
|
|
183
183
|
checkTypeArgumentCount(typeArgumentCount: number, typeParameters: readonly e.TypeParameterEntity[], diagnostics?: DiagnosticAcceptor, diagnosticLocation?: NodeOrDiagnosticLocation): boolean;
|
|
184
|
-
checkTypeCanBeUsedAsValue(typeAccess: tree.
|
|
184
|
+
checkTypeCanBeUsedAsValue(typeAccess: tree.IdentifierExpression | tree.MemberAccessExpression): boolean;
|
|
185
185
|
isPossiblyCastedBaseExpression(node: tree.Expression): boolean;
|
|
186
186
|
createAmbiguousNamedScopeDeclarationAccessDiagnostic(declarations: readonly semanticContext.NamedDeclaration[], nodeOrLocation: NodeOrDiagnosticLocation): Diagnostic;
|
|
187
187
|
/**
|
|
@@ -263,18 +263,18 @@ declare class Type {
|
|
|
263
263
|
/**
|
|
264
264
|
* По умолчанию литерал шаблона текста имеет тип Текст.
|
|
265
265
|
*
|
|
266
|
-
* Литерал шаблона текста имеет тип
|
|
267
|
-
* - если он присваивается в переменную, имеющую тип
|
|
268
|
-
* - если он присваивается в переменную, имеющую
|
|
266
|
+
* Литерал шаблона текста имеет тип ТекстШаблонный в следующих случаях:
|
|
267
|
+
* - если он присваивается в переменную, имеющую тип ТекстШаблонный;
|
|
268
|
+
* - если он присваивается в переменную, имеющую множественный тип, содержащий тип ТекстШаблонный
|
|
269
269
|
* и не содержащий тип Текст.
|
|
270
270
|
*/
|
|
271
271
|
private ofTextTemplateLiteral;
|
|
272
272
|
/**
|
|
273
273
|
* По умолчанию литерал шаблона текста имеет тип Текст.
|
|
274
274
|
*
|
|
275
|
-
* Литерал переводимого шаблона текста имеет тип
|
|
276
|
-
* - если он присваивается в переменную, имеющую тип
|
|
277
|
-
* - если он присваивается в переменную, имеющую
|
|
275
|
+
* Литерал переводимого шаблона текста имеет тип ТекстПереводимый в следующих случаях:
|
|
276
|
+
* - если он присваивается в переменную, имеющую тип ТекстПереводимый;
|
|
277
|
+
* - если он присваивается в переменную, имеющую множественный тип, содержащий тип ТекстПереводимый
|
|
278
278
|
* и не содержащий тип Текст.
|
|
279
279
|
*/
|
|
280
280
|
private ofLocalizableTextTemplateLiteral;
|
|
@@ -387,7 +387,7 @@ declare class Entity {
|
|
|
387
387
|
ofTypeExtensionDeclaration(node: tree.TypeExtensionDeclaration): e.TypeExtensionEntity;
|
|
388
388
|
ofPackageImport(node: tree.PackageImport): e.PackageAliasEntity;
|
|
389
389
|
ofTypeWithMembersDeclaration(node: tree.TypeWithMembersDeclaration): e.TypeEntityWithMembers;
|
|
390
|
-
ofTypeWithMembersOrExtensionDeclaration(node:
|
|
390
|
+
ofTypeWithMembersOrExtensionDeclaration(node: tree.TypeWithMembersOrExtensionDeclaration): e.TypeWithMembersOrExtensionEntity;
|
|
391
391
|
ofTranslationTextTemplateParameter(node: tree.TranslationTextTemplateParameter): e.ParameterEntity;
|
|
392
392
|
ofTextTranslationDeclaration(node: tree.TextTranslationSource): e.TextTranslationEntity;
|
|
393
393
|
ofFunctionLiteral(node: tree.FunctionLiteral): e.AnonymousFunctionEntity;
|
|
@@ -42,7 +42,7 @@ export declare class SecondStageResolver {
|
|
|
42
42
|
private resolveFunctionAccess;
|
|
43
43
|
private resolveNotCalledFunctionsAccess;
|
|
44
44
|
}
|
|
45
|
-
export type Meaning = Meaning_variableAccess | Meaning_functionAccess | Meaning_packageNameSegmentAccess | Meaning_packageAliasAccess | Meaning_typeAccess |
|
|
45
|
+
export type Meaning = Meaning_variableAccess | Meaning_functionAccess | Meaning_packageNameSegmentAccess | Meaning_packageAliasAccess | Meaning_typeAccess | Meaning_typeAccessAtConstructorCall | Meaning_mixedAmbiguousAccess | Meaning_unresolved;
|
|
46
46
|
declare class Meaning_variableAccess {
|
|
47
47
|
readonly variable: AccessedVariable;
|
|
48
48
|
readonly access: ComputedAccess;
|
|
@@ -74,10 +74,10 @@ declare class Meaning_typeAccess {
|
|
|
74
74
|
get singleSuitableType(): types.Type | undefined;
|
|
75
75
|
constructor(candidates: readonly NamedTypeEntity[], suitableTypes: readonly types.Type[]);
|
|
76
76
|
}
|
|
77
|
-
declare class
|
|
77
|
+
declare class Meaning_typeAccessAtConstructorCall {
|
|
78
78
|
readonly typeCandidates: readonly NamedTypeEntity[];
|
|
79
79
|
readonly callExpressionMeaning: callExpressionMeaning.Meaning_constructorCall;
|
|
80
|
-
readonly kind = "constructor-
|
|
80
|
+
readonly kind = "type-access-at-constructor-call";
|
|
81
81
|
constructor(typeCandidates: readonly NamedTypeEntity[], callExpressionMeaning: callExpressionMeaning.Meaning_constructorCall);
|
|
82
82
|
}
|
|
83
83
|
declare class Meaning_mixedAmbiguousAccess {
|
|
@@ -46,7 +46,7 @@ export declare class SecondStageResolver {
|
|
|
46
46
|
private resolveInstanceMethodAccess;
|
|
47
47
|
private resolveNotCalledFunctionsAccess;
|
|
48
48
|
}
|
|
49
|
-
export type Meaning = Meaning_packageVariableAccess | Meaning_packageFunctionAccess | Meaning_packageTypeAccess |
|
|
49
|
+
export type Meaning = Meaning_packageVariableAccess | Meaning_packageFunctionAccess | Meaning_packageTypeAccess | Meaning_typeAccessAtConstructorCall | Meaning_packageNameSegmentAccess | Meaning_staticFieldAccess | Meaning_staticMethodAccess | Meaning_instanceFieldAccess | Meaning_instanceMethodAccess | Meaning_mixedAmbiguousAccess | Meaning_unresolved;
|
|
50
50
|
declare class Meaning_packageVariableAccess {
|
|
51
51
|
readonly variable: PackageVariableEntity;
|
|
52
52
|
readonly access: ComputedAccess;
|
|
@@ -66,10 +66,10 @@ declare class Meaning_packageTypeAccess {
|
|
|
66
66
|
get singleSuitableType(): types.Type | undefined;
|
|
67
67
|
constructor(candidates: readonly PackageTypeEntity[], suitableTypes: readonly types.Type[]);
|
|
68
68
|
}
|
|
69
|
-
declare class
|
|
69
|
+
declare class Meaning_typeAccessAtConstructorCall {
|
|
70
70
|
readonly typeCandidates: readonly PackageTypeEntity[];
|
|
71
71
|
readonly callExpressionMeaning: callExpressionMeaning.Meaning_constructorCall;
|
|
72
|
-
readonly kind = "constructor-
|
|
72
|
+
readonly kind = "type-access-at-constructor-call";
|
|
73
73
|
constructor(typeCandidates: readonly PackageTypeEntity[], callExpressionMeaning: callExpressionMeaning.Meaning_constructorCall);
|
|
74
74
|
}
|
|
75
75
|
declare class Meaning_packageNameSegmentAccess {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { DiagnosticAcceptor } from '../../diagnostic/Diagnostic.js';
|
|
2
|
-
import { MethodEntity } from '../../entities/index.js';
|
|
2
|
+
import { EntityHidingLevel, MethodEntity } from '../../entities/index.js';
|
|
3
3
|
import * as tree from '../../tree/a/index.js';
|
|
4
4
|
import { Analyzer } from './Analyzer.js';
|
|
5
5
|
import { ModifierFlags } from './ModifierFlags.js';
|
|
@@ -64,7 +64,7 @@ export declare class ModifierValidator {
|
|
|
64
64
|
constructor(analyzer: Analyzer, diagnostics: DiagnosticAcceptor);
|
|
65
65
|
static validateTypeMemberAccessorsHaveConsistentModifiers(analyzer: Analyzer, getterEntity: MethodEntity, setterEntity: MethodEntity, getterNode: tree.GetterDeclaration, setterNode: tree.SetterDeclaration, diagnostics: DiagnosticAcceptor): void;
|
|
66
66
|
validateTopLevelPackageMembers(list: tree.PackageMemberDeclarationList): void;
|
|
67
|
-
validateTopLevelTypeMembers(memberList: tree.TypeMemberDeclarationList, declarationWithMembersKind: DeclarationWithTypeMembersKind, isTypeMarkedAbstract: boolean, isTypeMarkedBasic: boolean): void;
|
|
67
|
+
validateTopLevelTypeMembers(memberList: tree.TypeMemberDeclarationList, declarationWithMembersKind: DeclarationWithTypeMembersKind, isTypeMarkedAbstract: boolean, isTypeMarkedBasic: boolean, typeHiding: EntityHidingLevel | undefined): void;
|
|
68
68
|
private static getAccessorDiagnosticLocation;
|
|
69
69
|
private validatePackageMembers;
|
|
70
70
|
private validatePackageMemberModifierList;
|
|
@@ -80,6 +80,7 @@ export declare class ModifierValidator {
|
|
|
80
80
|
private typeMemberAllowsBasicModifier;
|
|
81
81
|
private typeMemberAllowsOverrideModifier;
|
|
82
82
|
private typeMemberAllowsStaticModifier;
|
|
83
|
+
private checkTypeMemberHidingIsEquallyOrMoreRestrictiveThanTypeHiding;
|
|
83
84
|
private reportDuplicateModifier;
|
|
84
85
|
private reportDuplicateHiddenModifier;
|
|
85
86
|
private reportDeclarationCannotBePlacedInGroupWithModifier;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { PackageLocale } from '../../common/index.js';
|
|
2
2
|
import { DiagnosticAcceptor } from '../../diagnostic/Diagnostic.js';
|
|
3
3
|
import { EntityLocalizationContext, LocalizablePackageMemberEntity } from '../../entities/EntityLocalizationContext.js';
|
|
4
|
-
import { AnonymousTypeEntity, Entity, EntityContainingParameter, EntityContainingTypeParameter, PackageEntity, PackageEntityMembers, PackageMemberEntity, ParameterEntity, TypeEntityMembers, TypeMemberEntity, TypeParameterEntity, TypeWithMembersOrExtensionEntity } from '../../entities/index.js';
|
|
4
|
+
import { AnonymousTypeEntity, Entity, EntityContainingParameter, EntityContainingTypeParameter, PackageEntity, PackageEntityMembers, PackageMemberEntity, ParameterEntity, TypeEntityMembers, TypeMemberEntity, TypeParameterEntity, TypeWithMembersOrExtensionEntity, LocalTypeEntity } from '../../entities/index.js';
|
|
5
5
|
import { PackageName, SourceFile, TranslationPackageA } from '../../project/index.js';
|
|
6
6
|
import * as tree from '../../tree/a/index.js';
|
|
7
7
|
import { Analyzer } from './Analyzer.js';
|
|
@@ -32,6 +32,7 @@ export declare class ResolvedTranslationPackage {
|
|
|
32
32
|
getTranslatedPackageMember(entity: LocalizablePackageMemberEntity): LocalizablePackageMemberEntity;
|
|
33
33
|
getTranslatedTypeMember(entity: TypeMemberEntity): TypeMemberEntity;
|
|
34
34
|
getTranslatedAnonymousTypeEntity(entity: AnonymousTypeEntity): AnonymousTypeEntity;
|
|
35
|
+
getTranslatedLocalTypeEntity(entity: LocalTypeEntity): LocalTypeEntity;
|
|
35
36
|
getTranslatedTypeOrExtensionMembers(translatedTypeEntity: TypeWithMembersOrExtensionEntity): TypeEntityMembers;
|
|
36
37
|
createTranslatedTypeParameters(original: readonly TypeParameterEntity[], node: tree.TranslationTypeParameterList | undefined, containingEntity: EntityContainingTypeParameter): readonly TypeParameterEntity[];
|
|
37
38
|
createTranslatedParameters(original: readonly ParameterEntity[], node: tree.TranslationParameterList | undefined, containingEntity: EntityContainingParameter): readonly ParameterEntity[];
|
|
@@ -70,7 +70,7 @@ export declare class SourceFileAnalyzer {
|
|
|
70
70
|
private checkParameterDeclaration;
|
|
71
71
|
private checkOwnConstructorCallExpression;
|
|
72
72
|
private checkReferenceExpression;
|
|
73
|
-
private
|
|
73
|
+
private checkSwitchStatement;
|
|
74
74
|
private checkWhileStatement;
|
|
75
75
|
private checkLoopStatement;
|
|
76
76
|
private checkElseIfClause;
|
|
@@ -1,7 +1,6 @@
|
|
|
1
|
-
import { DiagnosticAcceptor } from '../../diagnostic/Diagnostic.js';
|
|
2
1
|
import { PackageVariableEntity } from '../../entities/index.js';
|
|
3
2
|
import * as tree from '../../tree/a/index.js';
|
|
4
3
|
import { Analyzer } from './Analyzer.js';
|
|
5
4
|
export declare class SourcePackageMembersCreator {
|
|
6
|
-
static
|
|
5
|
+
static createComputedPackageVariables(analyzer: Analyzer, memberList: tree.PackageMemberDeclarationList, resultingComputedVariables: Map<tree.Node, PackageVariableEntity>): void;
|
|
7
6
|
}
|
|
@@ -8,8 +8,7 @@ export declare class TreeQuery {
|
|
|
8
8
|
static getPackageEntity(node: tree.Node, analyzer: Analyzer): PackageEntity;
|
|
9
9
|
}
|
|
10
10
|
export declare class TypeMemberQuery {
|
|
11
|
-
static getContainingDeclaration(node: tree.TypeMemberDeclaration):
|
|
11
|
+
static getContainingDeclaration(node: tree.TypeMemberDeclaration): tree.TypeWithMembersOrExtensionDeclaration;
|
|
12
12
|
static getOutermostMemberBlock(node: tree.TypeMemberDeclaration): tree.TypeMemberDeclarationBlock;
|
|
13
13
|
static getContextualTypeEntity(node: tree.TypeMemberDeclaration, analyzer: Analyzer): TypeEntity | undefined;
|
|
14
14
|
}
|
|
15
|
-
export type TypeWithMembersOrTypeExtensionDeclaration = tree.TypeWithMembersDeclaration | tree.TypeExtensionDeclaration;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Name } from '../../common/index.js';
|
|
2
|
-
import { NamedTypeMemberEntity, TypeEntity, TypeExtensionEntity } from '../../entities/index.js';
|
|
2
|
+
import { NamedTypeMemberEntity, TypeEntity, TypeExtensionEntity, OperatorKind } from '../../entities/index.js';
|
|
3
3
|
import * as types from '../../types/index.js';
|
|
4
4
|
import { Analyzer } from '../Analyzer.js';
|
|
5
5
|
import { DialectSpecificBoundTypeMemberLookup } from '../DialectSpecificBoundTypeMemberLookup.js';
|
|
@@ -15,6 +15,8 @@ export declare class TypeMemberLookupA {
|
|
|
15
15
|
getMatchingNamedMembersByName(name: Name, memberToMatch: NamedTypeMemberEntity, context: TypeMemberLookupContext | undefined, options?: TypeMemberLookupOptions): readonly types.NamedTypeMember[];
|
|
16
16
|
getConstructors(context: TypeMemberLookupContext | undefined, options?: TypeMemberLookupOptions): readonly types.Method[];
|
|
17
17
|
getDestructors(context: TypeMemberLookupContext | undefined, options?: TypeMemberLookupOptions): readonly types.Method[];
|
|
18
|
+
getOperators(context: TypeMemberLookupContext | undefined, options?: TypeMemberLookupOptions): readonly types.Method[];
|
|
19
|
+
getOperatorsByKind(kind: OperatorKind, context: TypeMemberLookupContext | undefined, options?: TypeMemberLookupOptions): readonly types.Method[];
|
|
18
20
|
getIndexers(context: TypeMemberLookupContext | undefined, options?: TypeMemberLookupOptions): readonly types.Indexer[];
|
|
19
21
|
getDereferenceOperators(context: TypeMemberLookupContext | undefined, options?: TypeMemberLookupOptions): readonly types.DereferenceOperator[];
|
|
20
22
|
}
|
|
@@ -6,14 +6,14 @@ import { NamedDeclaration, TypeOrContainerWithTypes } from './Declarations.js';
|
|
|
6
6
|
import { SemanticContext } from './SemanticContext.js';
|
|
7
7
|
import { NamedDeclarationLookupResult, SemanticContextLookupState } from './SemanticContextBase.js';
|
|
8
8
|
import { SemanticContextWithParent } from './SemanticContextWithParent.js';
|
|
9
|
-
import {
|
|
9
|
+
import { TypeOrExtensionMembersSemanticContext } from './TypeSemanticContext.js';
|
|
10
10
|
export declare class FieldWithInitializerSemanticContext extends SemanticContextWithParent {
|
|
11
11
|
readonly kind = "field-initializer";
|
|
12
|
-
readonly outer:
|
|
12
|
+
readonly outer: TypeOrExtensionMembersSemanticContext;
|
|
13
13
|
protected readonly asContext: SemanticContext;
|
|
14
14
|
private readonly analyzer;
|
|
15
15
|
private readonly node;
|
|
16
|
-
constructor(analyzer: Analyzer, node: tree.FieldDeclaration, outer:
|
|
16
|
+
constructor(analyzer: Analyzer, node: tree.FieldDeclaration, outer: TypeOrExtensionMembersSemanticContext);
|
|
17
17
|
isStatic(): boolean;
|
|
18
18
|
getTypeMemberLookupContext(): TypeMemberLookupContext;
|
|
19
19
|
getOwnTypesOrContainersWithTypes(_initialContext: SemanticContext): readonly TypeOrContainerWithTypes[];
|
|
@@ -2,7 +2,7 @@ import { FieldWithInitializerSemanticContext } from './FieldWithInitializerSeman
|
|
|
2
2
|
import { SourceFileSemanticContext } from './SourceFileSemanticContext.js';
|
|
3
3
|
import { CatchClauseSemanticContext, ForStatementSemanticContext, SpecialLocalDeclarationSemanticContext, StatementBlockSemanticContext, SubprogramParameterListSemanticContext, SubprogramTypeParameterSemanticContext } from './SubprogramBodyAndParametersSemanticContext.js';
|
|
4
4
|
import { OutermostSemanticContextOfSubprogram } from './SubprogramSemanticContext.js';
|
|
5
|
-
import { OutermostSemanticContextOfType, ParametersOfFunctionTypeSemanticContext,
|
|
5
|
+
import { OutermostSemanticContextOfType, ParametersOfFunctionTypeSemanticContext, TypeMembersSemanticContext, TypeExtensionMembersSemanticContext, TypeParametersOfTypeSemanticContext } from './TypeSemanticContext.js';
|
|
6
6
|
/**
|
|
7
7
|
* Позволяет получить информацию, общую для определённой области
|
|
8
8
|
* исходного кода (блока инструкций, списка членов типа и др.) с учётом
|
|
@@ -10,4 +10,4 @@ import { OutermostSemanticContextOfType, ParametersOfFunctionTypeSemanticContext
|
|
|
10
10
|
* Чтобы получить семантический контекст, в котором находится определённый узел,
|
|
11
11
|
* используйте `analyzer.semanticContext.containing(node)`.
|
|
12
12
|
*/
|
|
13
|
-
export type SemanticContext = SourceFileSemanticContext | OutermostSemanticContextOfType | TypeParametersOfTypeSemanticContext |
|
|
13
|
+
export type SemanticContext = SourceFileSemanticContext | OutermostSemanticContextOfType | TypeParametersOfTypeSemanticContext | TypeMembersSemanticContext | TypeExtensionMembersSemanticContext | ParametersOfFunctionTypeSemanticContext | OutermostSemanticContextOfSubprogram | SubprogramTypeParameterSemanticContext | SubprogramParameterListSemanticContext | SpecialLocalDeclarationSemanticContext | StatementBlockSemanticContext | FieldWithInitializerSemanticContext | ForStatementSemanticContext | CatchClauseSemanticContext;
|
|
@@ -4,7 +4,7 @@ import { SemanticContext } from './SemanticContext.js';
|
|
|
4
4
|
import { SourceFileSemanticContext } from './SourceFileSemanticContext.js';
|
|
5
5
|
import { CatchClauseSemanticContext, ForStatementSemanticContext, SpecialLocalDeclarationSemanticContext, StatementBlockSemanticContext, SubprogramParameterListSemanticContext, SubprogramTypeParameterSemanticContext } from './SubprogramBodyAndParametersSemanticContext.js';
|
|
6
6
|
import { ConstructorSemanticContext, DestructorSemanticContext, FunctionLiteralSemanticContext, FunctionSemanticContext, IndexedElementAccessorSemanticContext, OutermostSemanticContextOfSubprogram, PackageConstructorSemanticContext, PackageEntryPointSemanticContext, TextTranslationFunctionDeclarationSemanticContext, VariableAccessorDeclaration, VariableAccessorSemanticContext } from './SubprogramSemanticContext.js';
|
|
7
|
-
import { OutermostSemanticContextOfType, ParametersOfFunctionTypeSemanticContext,
|
|
7
|
+
import { OutermostSemanticContextOfType, ParametersOfFunctionTypeSemanticContext, TypeOrExtensionMembersSemanticContext, TypeMembersSemanticContext, TypeDeclarationCreatingSemanticContext, TypeExtensionMembersSemanticContext, TypeParametersOfTypeSemanticContext, TypeDeclarationWithTypeParameters } from './TypeSemanticContext.js';
|
|
8
8
|
export declare class SemanticContextBuilder {
|
|
9
9
|
private readonly analyzer;
|
|
10
10
|
private readonly sourceFileContexts;
|
|
@@ -18,10 +18,9 @@ export declare class SemanticContextBuilder {
|
|
|
18
18
|
private readonly packageEntryPointContexts;
|
|
19
19
|
private readonly packageConstructorContexts;
|
|
20
20
|
private readonly variableAccessorContexts;
|
|
21
|
-
private readonly
|
|
22
|
-
private readonly
|
|
23
|
-
private readonly
|
|
24
|
-
private readonly parametersOfFunctionTypeContext;
|
|
21
|
+
private readonly typeParametersOfTypeContexts;
|
|
22
|
+
private readonly typeMembersContexts;
|
|
23
|
+
private readonly parametersOfFunctionTypeContexts;
|
|
25
24
|
private readonly statementBlockContexts;
|
|
26
25
|
private readonly specialLocalDeclarationContexts;
|
|
27
26
|
private readonly subprogramTypeParameterContexts;
|
|
@@ -29,7 +28,7 @@ export declare class SemanticContextBuilder {
|
|
|
29
28
|
private readonly outermostContextsOfFunctionDeclaration;
|
|
30
29
|
private readonly outermostContextsOfTextTranslationFunctionDeclaration;
|
|
31
30
|
private readonly outermostContextsOfTypeDeclaration;
|
|
32
|
-
private readonly
|
|
31
|
+
private readonly typeExtensionMembersContexts;
|
|
33
32
|
constructor(analyzer: Analyzer);
|
|
34
33
|
/**
|
|
35
34
|
* Возвращает контекст, содержащий узел. Если в качестве узла передан исходный файл,
|
|
@@ -41,11 +40,11 @@ export declare class SemanticContextBuilder {
|
|
|
41
40
|
ofFunctionDeclarationParameters(node: tree.FunctionDeclaration): SubprogramParameterListSemanticContext;
|
|
42
41
|
ofFunctionDeclarationTypeParameters(node: tree.FunctionDeclaration, typeParameterClause: tree.TypeParameterClause): SubprogramTypeParameterSemanticContext;
|
|
43
42
|
outermostSemanticContextOfFunctionDeclaration(node: tree.FunctionDeclaration): FunctionSemanticContext;
|
|
44
|
-
|
|
43
|
+
ofTypeWithMembersDeclaration(node: tree.TypeWithMembersDeclaration): TypeMembersSemanticContext;
|
|
45
44
|
ofFunctionTypeDeclarationParameters(node: tree.FunctionTypeDeclaration): ParametersOfFunctionTypeSemanticContext;
|
|
46
45
|
outermostSemanticContextOfTypeDeclaration(node: TypeDeclarationCreatingSemanticContext): OutermostSemanticContextOfType;
|
|
47
|
-
ofTypeDeclarationTypeParameters(node:
|
|
48
|
-
|
|
46
|
+
ofTypeDeclarationTypeParameters(node: TypeDeclarationWithTypeParameters, typeParameterClause: tree.TypeParameterClause): TypeParametersOfTypeSemanticContext;
|
|
47
|
+
ofTypeExtensionDeclaration(node: tree.TypeExtensionDeclaration): TypeExtensionMembersSemanticContext;
|
|
49
48
|
ofVariableAccessorDeclaration(node: VariableAccessorDeclaration): VariableAccessorSemanticContext;
|
|
50
49
|
ofPackageConstructorDeclaration(node: tree.PackageConstructorDeclaration): PackageConstructorSemanticContext;
|
|
51
50
|
ofPackageEntryPointDeclaration(node: tree.PackageEntryPointDeclaration): PackageEntryPointSemanticContext;
|
|
@@ -67,12 +66,11 @@ export declare class SemanticContextBuilder {
|
|
|
67
66
|
ofCatchClause(node: tree.CatchClause): CatchClauseSemanticContext;
|
|
68
67
|
ofFieldDeclarationWithInitializer(node: tree.FieldDeclaration): SemanticContext;
|
|
69
68
|
ofSubprogram(node: tree.SubprogramDeclarationOrLiteral): OutermostSemanticContextOfSubprogram;
|
|
70
|
-
containingTypeMember(node: tree.TypeMemberDeclaration):
|
|
69
|
+
containingTypeMember(node: tree.TypeMemberDeclaration): TypeOrExtensionMembersSemanticContext;
|
|
71
70
|
containingPackageMember(node: tree.PackageMemberDeclaration): SourceFileSemanticContext;
|
|
72
71
|
private containingInternal;
|
|
73
72
|
private ofChildOfFunctionDeclaration;
|
|
74
|
-
private
|
|
75
|
-
private ofChildOfTypeDeclarationWithMemberBlock2;
|
|
73
|
+
private ofChildOfTypeWithMembersDeclaration;
|
|
76
74
|
private ofChildOfAnonymousFunctionTypeDeclaration;
|
|
77
75
|
private ofChildOfFunctionLiteral;
|
|
78
76
|
private ofConstructorDeclarationChild;
|
|
@@ -16,7 +16,6 @@ export declare class SpecialLocalDeclarationsBuilder {
|
|
|
16
16
|
static buildForDereferencedVariableSetterDeclaration(analyzer: Analyzer, node: tree.DereferencedVariableSetterDeclaration): readonly SpecialLocalDeclarationEntity[];
|
|
17
17
|
static buildForNestedFunctionDeclaration(analyzer: Analyzer, node: tree.NestedFunctionDeclaration): readonly SpecialLocalDeclarationEntity[];
|
|
18
18
|
static buildForFunctionLiteral(analyzer: Analyzer, node: tree.FunctionLiteral): readonly SpecialLocalDeclarationEntity[];
|
|
19
|
-
static buildForConstructorDeclaration(analyzer: Analyzer, node: tree.ConstructorDeclaration): readonly SpecialLocalDeclarationEntity[];
|
|
20
19
|
static buildForMethodDeclaration(analyzer: Analyzer, node: tree.MethodDeclaration): readonly SpecialLocalDeclarationEntity[];
|
|
21
20
|
static buildForTextTranslationFunctionDeclaration(analyzer: Analyzer, node: tree.TextTranslationFunctionDeclaration): readonly SpecialLocalDeclarationEntity[];
|
|
22
21
|
}
|
package/build/types/analysis/a/semantic-context/SubprogramBodyAndParametersSemanticContext.d.ts
CHANGED
|
@@ -76,21 +76,22 @@ export declare class SpecialLocalDeclarationSemanticContext extends SemanticCont
|
|
|
76
76
|
protected createMemberEntities(): readonly MemberOfSemanticContextValidatingNameConflicts[];
|
|
77
77
|
protected createMemberEntitiesForTypeLookup(): readonly MemberOfSemanticContextValidatingNameConflictsForTypeLookup[];
|
|
78
78
|
}
|
|
79
|
+
export type StatementSemanticContextParent = StatementBlockSemanticContext;
|
|
79
80
|
export declare class ForStatementSemanticContext extends SemanticContextValidatingNameConflictsBase {
|
|
80
81
|
readonly kind = "for-statement";
|
|
81
|
-
readonly outer:
|
|
82
|
+
readonly outer: StatementSemanticContextParent;
|
|
82
83
|
readonly node: tree.ForStatement;
|
|
83
84
|
protected readonly asContext: SemanticContext;
|
|
84
|
-
constructor(analyzer: Analyzer, node: tree.ForStatement, outer:
|
|
85
|
+
constructor(analyzer: Analyzer, node: tree.ForStatement, outer: StatementSemanticContextParent);
|
|
85
86
|
protected createMemberEntities(): readonly MemberOfSemanticContextValidatingNameConflicts[];
|
|
86
87
|
protected createMemberEntitiesForTypeLookup(): readonly MemberOfSemanticContextValidatingNameConflictsForTypeLookup[];
|
|
87
88
|
}
|
|
88
89
|
export declare class CatchClauseSemanticContext extends SemanticContextValidatingNameConflictsBase {
|
|
89
90
|
readonly kind = "catch-clause";
|
|
90
|
-
readonly outer:
|
|
91
|
+
readonly outer: StatementSemanticContextParent;
|
|
91
92
|
readonly node: tree.CatchClause;
|
|
92
93
|
protected readonly asContext: SemanticContext;
|
|
93
|
-
constructor(analyzer: Analyzer, node: tree.CatchClause, outer:
|
|
94
|
+
constructor(analyzer: Analyzer, node: tree.CatchClause, outer: StatementSemanticContextParent);
|
|
94
95
|
protected createMemberEntities(): readonly MemberOfSemanticContextValidatingNameConflicts[];
|
|
95
96
|
protected createMemberEntitiesForTypeLookup(): readonly MemberOfSemanticContextValidatingNameConflictsForTypeLookup[];
|
|
96
97
|
}
|
|
@@ -7,7 +7,7 @@ import { SemanticContext } from './SemanticContext.js';
|
|
|
7
7
|
import { NamedDeclarationLookupResult, ObjectVariableInfo, SemanticContextLookupState, SubprogramInfo, TryStatementContextKind } from './SemanticContextBase.js';
|
|
8
8
|
import { SemanticContextWithParent } from './SemanticContextWithParent.js';
|
|
9
9
|
import { SourceFileSemanticContext } from './SourceFileSemanticContext.js';
|
|
10
|
-
import {
|
|
10
|
+
import { TypeOrExtensionMembersSemanticContext } from './TypeSemanticContext.js';
|
|
11
11
|
export type LastSemanticContextOfSubprogramParent = SemanticContext;
|
|
12
12
|
/**
|
|
13
13
|
* Завершающий семантический контекст подпрограммы.
|
|
@@ -65,45 +65,46 @@ export declare class PackageEntryPointSemanticContext extends OutermostSemanticC
|
|
|
65
65
|
protected findObjectParameter(): ParameterEntity | undefined;
|
|
66
66
|
}
|
|
67
67
|
export declare class ConstructorSemanticContext extends OutermostSemanticContextOfSubprogram {
|
|
68
|
-
readonly outer:
|
|
68
|
+
readonly outer: TypeOrExtensionMembersSemanticContext;
|
|
69
69
|
protected readonly asContext: SemanticContext;
|
|
70
70
|
protected readonly analyzer: Analyzer;
|
|
71
71
|
private readonly node;
|
|
72
72
|
private readonly subprogramInfo;
|
|
73
|
-
constructor(analyzer: Analyzer, node: tree.ConstructorDeclaration, outer:
|
|
73
|
+
constructor(analyzer: Analyzer, node: tree.ConstructorDeclaration, outer: TypeOrExtensionMembersSemanticContext);
|
|
74
74
|
getContainingSubprogram(): SubprogramInfo;
|
|
75
75
|
protected findObjectParameter(): ParameterEntity | undefined;
|
|
76
76
|
}
|
|
77
77
|
export declare class DestructorSemanticContext extends OutermostSemanticContextOfSubprogram {
|
|
78
|
-
readonly outer:
|
|
78
|
+
readonly outer: TypeOrExtensionMembersSemanticContext;
|
|
79
79
|
protected readonly asContext: SemanticContext;
|
|
80
80
|
protected readonly analyzer: Analyzer;
|
|
81
81
|
private readonly node;
|
|
82
82
|
private readonly subprogramInfo;
|
|
83
|
-
constructor(analyzer: Analyzer, node: tree.DestructorDeclaration, outer:
|
|
83
|
+
constructor(analyzer: Analyzer, node: tree.DestructorDeclaration, outer: TypeOrExtensionMembersSemanticContext);
|
|
84
84
|
getContainingSubprogram(): SubprogramInfo;
|
|
85
85
|
protected findObjectParameter(): ParameterEntity | undefined;
|
|
86
86
|
}
|
|
87
|
-
export type
|
|
87
|
+
export type VariableAccessorSemanticContextParent = TypeOrExtensionMembersSemanticContext | SourceFileSemanticContext;
|
|
88
88
|
export type VariableAccessorDeclaration = tree.PackageVariableAccessorDeclaration | tree.FieldAccessorDeclaration | tree.DereferencedVariableAccessorDeclaration;
|
|
89
89
|
export declare class VariableAccessorSemanticContext extends OutermostSemanticContextOfSubprogram {
|
|
90
|
-
readonly outer:
|
|
90
|
+
readonly outer: VariableAccessorSemanticContextParent;
|
|
91
91
|
protected readonly asContext: SemanticContext;
|
|
92
92
|
protected readonly analyzer: Analyzer;
|
|
93
93
|
private readonly node;
|
|
94
94
|
private readonly subprogramInfo;
|
|
95
|
-
constructor(analyzer: Analyzer, node: VariableAccessorDeclaration, outer:
|
|
95
|
+
constructor(analyzer: Analyzer, node: VariableAccessorDeclaration, outer: VariableAccessorSemanticContextParent);
|
|
96
96
|
getContainingSubprogram(): SubprogramInfo;
|
|
97
97
|
isStatic(): boolean;
|
|
98
98
|
protected findObjectParameter(): ParameterEntity | undefined;
|
|
99
99
|
}
|
|
100
|
+
export type IndexedElementAccessorSemanticContextParent = TypeOrExtensionMembersSemanticContext;
|
|
100
101
|
export declare class IndexedElementAccessorSemanticContext extends OutermostSemanticContextOfSubprogram {
|
|
101
|
-
readonly outer:
|
|
102
|
+
readonly outer: IndexedElementAccessorSemanticContextParent;
|
|
102
103
|
protected readonly asContext: SemanticContext;
|
|
103
104
|
protected readonly analyzer: Analyzer;
|
|
104
105
|
private readonly node;
|
|
105
106
|
private readonly subprogramInfo;
|
|
106
|
-
constructor(analyzer: Analyzer, node: tree.IndexedElementAccessorDeclaration, outer:
|
|
107
|
+
constructor(analyzer: Analyzer, node: tree.IndexedElementAccessorDeclaration, outer: IndexedElementAccessorSemanticContextParent);
|
|
107
108
|
getContainingSubprogram(): SubprogramInfo;
|
|
108
109
|
isStatic(): boolean;
|
|
109
110
|
protected findObjectParameter(): ParameterEntity | undefined;
|