@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
|
@@ -51,7 +51,7 @@ export declare class PackageMemberDeclarationList extends BaseNode {
|
|
|
51
51
|
get declarations(): Query<PackageMemberDeclaration>;
|
|
52
52
|
protected get thisAsNode(): Node;
|
|
53
53
|
constructor(elements: readonly PackageMemberDeclarationListElement[], rangeWithTrivia: Range | undefined);
|
|
54
|
-
flatten(): Iterable<
|
|
54
|
+
flatten(): Iterable<PackageSingleMemberDeclaration>;
|
|
55
55
|
}
|
|
56
56
|
export type PackageImportDirectiveListElement = PackageImportDirective | Semicolon;
|
|
57
57
|
export declare class PackageImportDirectiveList extends BaseNode {
|
|
@@ -237,7 +237,8 @@ export declare class AnonymousClassDeclaration extends BaseNode {
|
|
|
237
237
|
protected get thisAsNode(): Node;
|
|
238
238
|
constructor(classKeyword: Keyword<KeywordKind.Class>, extendsClause: ExtendsClause | undefined, memberBlock: TypeMemberDeclarationBlock, rangeWithTrivia: Range | undefined);
|
|
239
239
|
}
|
|
240
|
-
export type
|
|
240
|
+
export type PackageSingleMemberDeclaration = PackageClassDeclaration | PackageStructureDeclaration | PackageAspectDeclaration | PackageReducedTypeDeclaration | PackageVariantDeclaration | PackageAliasTypeDeclaration | TypeExtensionDeclaration | PackageConstructorDeclaration | PackageEntryPointDeclaration | PackageFunctionDeclaration | PackageVariableDeclaration | PackageVariableGetterDeclaration | PackageVariableSetterDeclaration | MissingPackageMemberDeclaration | TranslationsDeclaration;
|
|
241
|
+
export type PackageMemberDeclaration = PackageSingleMemberDeclaration | PackageMemberGroupDeclaration;
|
|
241
242
|
export declare class PackageAliasTypeDeclaration extends BaseNode {
|
|
242
243
|
readonly kind = NodeKind.PackageAliasTypeDeclaration;
|
|
243
244
|
readonly children: readonly [
|
|
@@ -356,7 +357,7 @@ export declare class TypeMemberDeclarationList extends BaseNode {
|
|
|
356
357
|
get members(): Query<TypeMemberDeclaration>;
|
|
357
358
|
protected get thisAsNode(): Node;
|
|
358
359
|
constructor(elements: readonly TypeMemberDeclarationListElement[], rangeWithTrivia: Range | undefined);
|
|
359
|
-
flatten(): Iterable<
|
|
360
|
+
flatten(): Iterable<TypeSingleMemberDeclaration>;
|
|
360
361
|
}
|
|
361
362
|
export type TypeMemberDeclarationBlockParent = PackageClassDeclaration | PackageStructureDeclaration | PackageAspectDeclaration | PackageReducedTypeDeclaration | PackageVariantDeclaration | AnonymousClassDeclaration | PackageAliasTypeDeclaration | TypeExtensionDeclaration | TypeMemberGroupDeclaration;
|
|
362
363
|
export declare class TypeMemberDeclarationBlock extends BaseNode {
|
|
@@ -623,7 +624,8 @@ export declare class MissingPackageMemberDeclaration extends BaseNode {
|
|
|
623
624
|
protected get thisAsNode(): Node;
|
|
624
625
|
constructor(tagList: TagList, modifierList: ModifierList, rangeWithTrivia: Range | undefined);
|
|
625
626
|
}
|
|
626
|
-
export type
|
|
627
|
+
export type TypeSingleMemberDeclaration = FieldDeclaration | FieldGetterDeclaration | FieldSetterDeclaration | VariantValueDeclaration | MethodDeclaration | ConstructorDeclaration | DestructorDeclaration | IndexedElementGetterDeclaration | IndexedElementSetterDeclaration | DereferencedVariableGetterDeclaration | DereferencedVariableSetterDeclaration | MissingTypeMemberDeclaration;
|
|
628
|
+
export type TypeMemberDeclaration = TypeSingleMemberDeclaration | TypeMemberGroupDeclaration;
|
|
627
629
|
export declare class TypeMemberGroupDeclaration extends BaseNode {
|
|
628
630
|
readonly kind = NodeKind.TypeMemberGroupDeclaration;
|
|
629
631
|
readonly children: readonly [
|
|
@@ -1405,7 +1407,6 @@ export declare class StatementBlock extends BaseNode {
|
|
|
1405
1407
|
constructor(openBraceToken: Token<TokenKind.OpenBrace>, statementList: StatementList, closeBraceToken: Token<TokenKind.CloseBrace>, rangeWithTrivia: Range | undefined);
|
|
1406
1408
|
}
|
|
1407
1409
|
export type FunctionBlockParent = PackageVariableGetterDeclaration | PackageVariableSetterDeclaration | PackageFunctionDeclaration | FieldGetterDeclaration | FieldSetterDeclaration | IndexedElementGetterDeclaration | IndexedElementSetterDeclaration | DereferencedVariableGetterDeclaration | DereferencedVariableSetterDeclaration | MethodDeclaration | NestedFunctionDeclaration | FunctionLiteral | FunctionBlockLiteral | PackageConstructorDeclaration | PackageEntryPointDeclaration | ConstructorDeclaration | DestructorDeclaration | TextTranslationFunctionDeclaration;
|
|
1408
|
-
export type ExpressionOrStatementList = Expression | StatementList;
|
|
1409
1410
|
export declare class FunctionBlock extends BaseNode {
|
|
1410
1411
|
readonly kind = NodeKind.FunctionBlock;
|
|
1411
1412
|
readonly children: readonly [
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { KeywordKind } from './KeywordKind.js';
|
|
2
|
+
import { TokenKind } from './TokenKind.js';
|
|
2
3
|
export declare enum OperatorKind {
|
|
3
4
|
Plus = 0,// Одноместный или двухместный.
|
|
4
5
|
Minus = 1,// Одноместный или двухместный.
|
|
@@ -39,3 +40,7 @@ export declare const keywordKindByOperatorKind: {
|
|
|
39
40
|
[T in KindOfOperatorDefinedByKeyword]: KeywordKind;
|
|
40
41
|
};
|
|
41
42
|
export declare const operatorKindByKeywordKind: Record<number, KindOfOperatorDefinedByKeyword | undefined>;
|
|
43
|
+
export declare const tokenKindByOperatorKind: {
|
|
44
|
+
[T in KindOfOperatorDefinedByToken]: TokenKind;
|
|
45
|
+
};
|
|
46
|
+
export declare const operatorKindByTokenKind: Record<number, KindOfOperatorDefinedByToken | undefined>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { KeywordKind } from './KeywordKind.js';
|
|
2
|
-
import { AnonymousClassDeclaration, AnonymousFunctionTypeDeclaration, DereferencedVariableGetterDeclaration, DereferencedVariableSetterDeclaration, Expression, FieldDeclaration, FieldGetterDeclaration, FieldSetterDeclaration, ForStatementVariableDeclaration, FunctionBlockLiteral, FunctionBlockParent, FunctionLiteral, Identifier, IdentifierParent, IndexedElementGetterDeclaration, IndexedElementSetterDeclaration, Keyword, LocalVariableDeclaration, MethodDeclaration, NestedFunctionDeclaration, Node, PackageAliasTypeDeclaration, PackageAspectDeclaration, PackageClassDeclaration, PackageFunctionDeclaration, PackageMemberDeclaration, PackageReducedTypeDeclaration, PackageStructureDeclaration, PackageVariableDeclaration, PackageVariableGetterDeclaration, PackageVariableSetterDeclaration, PackageVariantDeclaration, ParameterDeclaration, Statement, TypeMemberDeclaration, TypeParameterDeclaration, TypeSpecifier, VariantValueDeclaration } from './Nodes.js';
|
|
2
|
+
import { AnonymousClassDeclaration, AnonymousFunctionTypeDeclaration, DereferencedVariableGetterDeclaration, DereferencedVariableSetterDeclaration, Expression, FieldDeclaration, FieldGetterDeclaration, FieldSetterDeclaration, ForStatementVariableDeclaration, FunctionBlockLiteral, FunctionBlockParent, FunctionLiteral, Identifier, IdentifierParent, IndexedElementGetterDeclaration, IndexedElementSetterDeclaration, Keyword, LocalVariableDeclaration, MethodDeclaration, ModifierListParent, NestedFunctionDeclaration, Node, PackageAliasTypeDeclaration, PackageAspectDeclaration, PackageClassDeclaration, PackageFunctionDeclaration, PackageMemberDeclaration, PackageReducedTypeDeclaration, PackageStructureDeclaration, PackageVariableDeclaration, PackageVariableGetterDeclaration, PackageVariableSetterDeclaration, PackageVariantDeclaration, ParameterDeclaration, Statement, TagListParent, TypeExtensionDeclaration, TypeMemberDeclaration, TypeParameterDeclaration, TypeSpecifier, VariantValueDeclaration } from './Nodes.js';
|
|
3
3
|
import { Token } from './Token.js';
|
|
4
4
|
import { TokenKind } from './TokenKind.js';
|
|
5
5
|
export declare function isIdentifier(node: Node): node is Identifier;
|
|
@@ -13,6 +13,12 @@ export declare function isStatement(node: Node): node is Statement;
|
|
|
13
13
|
export declare function isTypeSpecifier(node: Node): node is TypeSpecifier;
|
|
14
14
|
export type TypeDeclaration = StructuredTypeDeclaration | VariantTypeDeclaration | FunctionTypeDeclaration | PackageReducedTypeDeclaration | PackageAliasTypeDeclaration | TypeParameterDeclaration;
|
|
15
15
|
export declare function isTypeDeclaration(node: Node): node is TypeDeclaration;
|
|
16
|
+
export type TypeOrExtensionDeclaration = TypeDeclaration | TypeExtensionDeclaration;
|
|
17
|
+
export declare function isTypeOrExtensionDeclaration(node: Node): node is TypeOrExtensionDeclaration;
|
|
18
|
+
export type TypeWithMembersDeclaration = StructuredTypeDeclaration | VariantTypeDeclaration | PackageAliasTypeDeclaration | PackageReducedTypeDeclaration;
|
|
19
|
+
export declare function isTypeWithMembersDeclaration(node: Node): node is TypeWithMembersDeclaration;
|
|
20
|
+
export type TypeWithMembersOrExtensionDeclaration = TypeWithMembersDeclaration | TypeExtensionDeclaration;
|
|
21
|
+
export declare function isTypeWithMembersOrExtensionDeclaration(node: Node): node is TypeWithMembersOrExtensionDeclaration;
|
|
16
22
|
export type NamedTypeDeclaration = TypeDeclaration & IdentifierParent;
|
|
17
23
|
export declare function isNamedTypeDeclaration(node: Node): node is NamedTypeDeclaration;
|
|
18
24
|
export type PackageTypeDeclaration = TypeDeclaration & PackageMemberDeclaration;
|
|
@@ -34,12 +40,11 @@ export declare function isPackageStructuredTypeDeclaration(node: Node): node is
|
|
|
34
40
|
export type AnonymousStructuredTypeDeclaration = AnonymousClassDeclaration;
|
|
35
41
|
export declare function isAnonymousStructuredTypeDeclaration(node: Node): node is AnonymousStructuredTypeDeclaration;
|
|
36
42
|
export type FunctionTypeDeclaration = AnonymousFunctionTypeDeclaration;
|
|
37
|
-
export type TypeWithMembersDeclaration = StructuredTypeDeclaration | VariantTypeDeclaration | PackageAliasTypeDeclaration | PackageReducedTypeDeclaration;
|
|
38
43
|
export type GetterDeclaration = PackageVariableGetterDeclaration | FieldGetterDeclaration | IndexedElementGetterDeclaration | DereferencedVariableGetterDeclaration;
|
|
39
44
|
export type SetterDeclaration = PackageVariableSetterDeclaration | FieldSetterDeclaration | IndexedElementSetterDeclaration | DereferencedVariableSetterDeclaration;
|
|
40
45
|
export type PackageVariableAccessorDeclaration = PackageVariableGetterDeclaration | PackageVariableSetterDeclaration;
|
|
41
46
|
export type FieldAccessorDeclaration = FieldGetterDeclaration | FieldSetterDeclaration;
|
|
42
47
|
export type IndexedElementAccessorDeclaration = IndexedElementGetterDeclaration | IndexedElementSetterDeclaration;
|
|
43
48
|
export type DereferencedVariableAccessorDeclaration = DereferencedVariableGetterDeclaration | DereferencedVariableSetterDeclaration;
|
|
44
|
-
export type NodeWithModifiers =
|
|
45
|
-
export type NodeWithTags =
|
|
49
|
+
export type NodeWithModifiers = ModifierListParent;
|
|
50
|
+
export type NodeWithTags = TagListParent;
|
|
@@ -1,8 +1,6 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { NodeKind } from './NodeKind.js';
|
|
1
|
+
import { PackageLocale, Range } from '../../common/index.js';
|
|
3
2
|
import { Node, SourceFile } from './Nodes.js';
|
|
4
|
-
import {
|
|
5
|
-
import { TriviaKind } from './TriviaKind.js';
|
|
3
|
+
import { Token } from './Token.js';
|
|
6
4
|
export declare abstract class BaseNode {
|
|
7
5
|
protected static readonly emptyChildren_: [];
|
|
8
6
|
abstract readonly children: readonly (Node | undefined)[];
|
|
@@ -15,9 +13,9 @@ export declare abstract class BaseNode {
|
|
|
15
13
|
get parent(): Node | undefined;
|
|
16
14
|
get sourceFile(): SourceFile;
|
|
17
15
|
get locale(): PackageLocale;
|
|
18
|
-
get dialect(): PackageDialect;
|
|
19
16
|
get rangeWithTrivia(): Range;
|
|
20
17
|
get rangeWithoutTrivia(): Range;
|
|
18
|
+
get debuggerDisplay(): string;
|
|
21
19
|
/**
|
|
22
20
|
* Информация для оценки размера дерева при отладке.
|
|
23
21
|
*/
|
|
@@ -26,6 +24,10 @@ export declare abstract class BaseNode {
|
|
|
26
24
|
* Информация для оценки размера дерева при отладке.
|
|
27
25
|
*/
|
|
28
26
|
get tokenCount(): number;
|
|
27
|
+
/**
|
|
28
|
+
* Позволяет получить путь к синтаксическому узлу при отладке.
|
|
29
|
+
*/
|
|
30
|
+
get nodePath(): string;
|
|
29
31
|
findLeftmostToken(): Token | undefined;
|
|
30
32
|
findRightmostToken(): Token | undefined;
|
|
31
33
|
getSourceCode(lengthLimit?: number, excludeTrivia?: boolean): string;
|
|
@@ -36,38 +38,4 @@ export declare abstract class BaseNode {
|
|
|
36
38
|
private countDescendants;
|
|
37
39
|
private countTokens;
|
|
38
40
|
}
|
|
39
|
-
export declare
|
|
40
|
-
readonly kind = NodeKind.Token;
|
|
41
|
-
readonly tokenKind: TKind;
|
|
42
|
-
readonly value: string;
|
|
43
|
-
readonly leadingTrivia: readonly Trivia[];
|
|
44
|
-
readonly trailingTrivia: readonly Trivia[];
|
|
45
|
-
get children(): readonly [];
|
|
46
|
-
get parent(): Node;
|
|
47
|
-
protected get thisAsNode(): Node;
|
|
48
|
-
constructor(tokenKind: TKind, value: string, leadingTrivia: readonly Trivia[], trailingTrivia: readonly Trivia[], rangeWithTrivia: Range | undefined);
|
|
49
|
-
get rangeWithoutTrivia(): Range;
|
|
50
|
-
getTextWithTrivia(): string;
|
|
51
|
-
hasLeadingLineBreak(): boolean;
|
|
52
|
-
hasTrailingLineBreak(): boolean;
|
|
53
|
-
getTriviaAt(position: number): TokenTrivia | undefined;
|
|
54
|
-
selectLeadingTrivia(condition: (trivia: Trivia, rangeStart: number, rangeEnd: number) => boolean): TokenTrivia[];
|
|
55
|
-
selectTrailingTrivia(condition: (trivia: Trivia, rangeStart: number, rangeEnd: number) => boolean): TokenTrivia[];
|
|
56
|
-
protected getLengthWithTrivia(): number;
|
|
57
|
-
}
|
|
58
|
-
export declare class Trivia {
|
|
59
|
-
readonly kind: TriviaKind;
|
|
60
|
-
readonly value: string;
|
|
61
|
-
get rangeLength(): number;
|
|
62
|
-
constructor(kind: TriviaKind, value: string);
|
|
63
|
-
}
|
|
64
|
-
export declare class TokenTrivia {
|
|
65
|
-
readonly trivia: Trivia;
|
|
66
|
-
readonly token: Token<TokenKind>;
|
|
67
|
-
readonly isTrailing: boolean;
|
|
68
|
-
readonly index: number;
|
|
69
|
-
readonly range: Range;
|
|
70
|
-
get kind(): TriviaKind;
|
|
71
|
-
get value(): string;
|
|
72
|
-
constructor(token: Token<TokenKind>, trivia: Trivia, isTrailing: boolean, index: number, range: Range);
|
|
73
|
-
}
|
|
41
|
+
export declare function toSourceCode(node: Node, lengthLimit?: number, excludeTrivia?: boolean): string;
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
export declare enum KeywordKind {
|
|
2
|
+
Unknown = 1000,
|
|
3
|
+
And = 1001,
|
|
4
|
+
Base = 1002,
|
|
5
|
+
BreakLoop = 1003,
|
|
6
|
+
Case = 1004,
|
|
7
|
+
Catch = 1005,
|
|
8
|
+
Cond = 1006,
|
|
9
|
+
ContinueLoop = 1007,
|
|
10
|
+
Dispose = 1008,
|
|
11
|
+
Else = 1009,
|
|
12
|
+
ElseIf = 1010,
|
|
13
|
+
End = 1011,
|
|
14
|
+
Error = 1012,
|
|
15
|
+
Extends = 1013,
|
|
16
|
+
Finally = 1014,
|
|
17
|
+
For = 1015,
|
|
18
|
+
From = 1016,
|
|
19
|
+
Function = 1017,
|
|
20
|
+
If = 1018,
|
|
21
|
+
Import = 1019,
|
|
22
|
+
Important = 1020,
|
|
23
|
+
Loop = 1021,
|
|
24
|
+
No = 1022,
|
|
25
|
+
Not = 1023,
|
|
26
|
+
Null = 1024,
|
|
27
|
+
Object = 1025,
|
|
28
|
+
Or = 1026,
|
|
29
|
+
Reference = 1027,
|
|
30
|
+
Return = 1028,
|
|
31
|
+
Run = 1029,
|
|
32
|
+
Switch = 1030,
|
|
33
|
+
Translations = 1031,
|
|
34
|
+
Try = 1032,
|
|
35
|
+
Type = 1033,
|
|
36
|
+
Var = 1034,
|
|
37
|
+
While = 1035,
|
|
38
|
+
Yes = 1036,
|
|
39
|
+
Yield = 1037
|
|
40
|
+
}
|
|
@@ -1,4 +1,149 @@
|
|
|
1
1
|
export declare enum NodeKind {
|
|
2
|
-
|
|
3
|
-
|
|
2
|
+
SourceFile = 1000,
|
|
3
|
+
Token = 1001,
|
|
4
|
+
Keyword = 1002,
|
|
5
|
+
Argument = 1003,
|
|
6
|
+
ArgumentList = 1004,
|
|
7
|
+
ArrayLiteral = 1005,
|
|
8
|
+
ArrayLiteralElementList = 1006,
|
|
9
|
+
AssignmentStatement = 1007,
|
|
10
|
+
AssumptionExpression = 1008,
|
|
11
|
+
BaseExpression = 1009,
|
|
12
|
+
BaseTypeList = 1010,
|
|
13
|
+
BinaryExpression = 1011,
|
|
14
|
+
BreakLoopStatement = 1012,
|
|
15
|
+
CallExpression = 1013,
|
|
16
|
+
CaseClause = 1014,
|
|
17
|
+
CaseClauseList = 1015,
|
|
18
|
+
CatchClause = 1016,
|
|
19
|
+
ConditionalExpression = 1017,
|
|
20
|
+
ContinueLoopStatement = 1018,
|
|
21
|
+
DefaultMatchExpression = 1019,
|
|
22
|
+
DereferenceExpression = 1020,
|
|
23
|
+
DisposeStatement = 1021,
|
|
24
|
+
ElseClause = 1022,
|
|
25
|
+
ElseIfClause = 1023,
|
|
26
|
+
ElseIfClauseList = 1024,
|
|
27
|
+
ErrorStatement = 1025,
|
|
28
|
+
ErrorVariableDeclaration = 1026,
|
|
29
|
+
ExpressionStatement = 1027,
|
|
30
|
+
ExtendsClause = 1028,
|
|
31
|
+
FieldDeclaration = 1029,
|
|
32
|
+
FieldGetterDeclaration = 1030,
|
|
33
|
+
FieldOrVariantTranslation = 1031,
|
|
34
|
+
FieldSetterDeclaration = 1032,
|
|
35
|
+
FinallyClause = 1033,
|
|
36
|
+
ForStatement = 1034,
|
|
37
|
+
ForStatementVariableDeclaration = 1035,
|
|
38
|
+
FunctionBlock = 1036,
|
|
39
|
+
FunctionBlockLiteral = 1037,
|
|
40
|
+
FunctionLiteral = 1038,
|
|
41
|
+
FunctionTypeTranslationDeclaration = 1039,
|
|
42
|
+
GenericSpecializationExpression = 1040,
|
|
43
|
+
IdentifierExpression = 1041,
|
|
44
|
+
IfStatement = 1042,
|
|
45
|
+
ImportantStatement = 1043,
|
|
46
|
+
IndexParameterTranslationClause = 1044,
|
|
47
|
+
IndexedAccessExpression = 1045,
|
|
48
|
+
IndexedElementGetterDeclaration = 1046,
|
|
49
|
+
IndexedElementSetterDeclaration = 1047,
|
|
50
|
+
IndexerTranslation = 1048,
|
|
51
|
+
KeywordExpression = 1049,
|
|
52
|
+
LocalFunctionTypeDeclaration = 1050,
|
|
53
|
+
LocalStructuredTypeDeclaration = 1051,
|
|
54
|
+
LocalStructuredTypeDeclarationStatement = 1052,
|
|
55
|
+
LocalTypeSpecifier = 1053,
|
|
56
|
+
LocalVariableDeclaration = 1054,
|
|
57
|
+
LocalVariableDeclarationStatement = 1055,
|
|
58
|
+
LocalizableTextLiteral = 1056,
|
|
59
|
+
LocalizableTextTemplateLiteral = 1057,
|
|
60
|
+
LoopStatement = 1058,
|
|
61
|
+
MatchExpressionGroup = 1059,
|
|
62
|
+
MatchExpressionList = 1060,
|
|
63
|
+
MemberAccessExpression = 1061,
|
|
64
|
+
MethodDeclaration = 1062,
|
|
65
|
+
MethodTranslation = 1063,
|
|
66
|
+
MissingExpression = 1064,
|
|
67
|
+
MissingPackageMemberDeclaration = 1065,
|
|
68
|
+
MissingStatement = 1066,
|
|
69
|
+
MissingTypeMemberDeclaration = 1067,
|
|
70
|
+
MissingTypeSpecifier = 1068,
|
|
71
|
+
NamedTypeSpecifier = 1069,
|
|
72
|
+
NestedFunctionDeclaration = 1070,
|
|
73
|
+
NestedFunctionDeclarationStatement = 1071,
|
|
74
|
+
NullableTypeSpecifier = 1072,
|
|
75
|
+
ObjectExpression = 1073,
|
|
76
|
+
PackageAliasTypeDeclaration = 1074,
|
|
77
|
+
PackageFunctionDeclaration = 1075,
|
|
78
|
+
PackageFunctionTranslationDeclaration = 1076,
|
|
79
|
+
PackageImport = 1077,
|
|
80
|
+
PackageImportDirective = 1078,
|
|
81
|
+
PackageImportDirectiveList = 1079,
|
|
82
|
+
PackageImportList = 1080,
|
|
83
|
+
PackageMemberDeclarationList = 1081,
|
|
84
|
+
PackageMemberGroupDeclaration = 1082,
|
|
85
|
+
PackageName = 1083,
|
|
86
|
+
PackageStatement = 1084,
|
|
87
|
+
PackageTypeDeclaration = 1085,
|
|
88
|
+
PackageVariableDeclaration = 1086,
|
|
89
|
+
PackageVariableGetterDeclaration = 1087,
|
|
90
|
+
PackageVariableSetterDeclaration = 1088,
|
|
91
|
+
PackageVariableTranslationDeclaration = 1089,
|
|
92
|
+
ParameterClause = 1090,
|
|
93
|
+
ParameterDeclaration = 1091,
|
|
94
|
+
ParameterList = 1092,
|
|
95
|
+
ParenthesizedExpression = 1093,
|
|
96
|
+
ParenthesizedTypeSpecifier = 1094,
|
|
97
|
+
PrefixUnaryExpression = 1095,
|
|
98
|
+
QualifiedName = 1096,
|
|
99
|
+
ReferenceExpression = 1097,
|
|
100
|
+
ReturnStatement = 1098,
|
|
101
|
+
RunStatement = 1099,
|
|
102
|
+
StatementBlock = 1100,
|
|
103
|
+
StatementList = 1101,
|
|
104
|
+
StaticFieldDeclaration = 1102,
|
|
105
|
+
StaticFieldGetterDeclaration = 1103,
|
|
106
|
+
StaticFieldSetterDeclaration = 1104,
|
|
107
|
+
StaticMethodDeclaration = 1105,
|
|
108
|
+
StaticNameClause = 1106,
|
|
109
|
+
SwitchStatement = 1107,
|
|
110
|
+
Tag = 1108,
|
|
111
|
+
TagList = 1109,
|
|
112
|
+
TextLiteral = 1110,
|
|
113
|
+
TextTemplateLiteral = 1111,
|
|
114
|
+
TextTemplateSpan = 1112,
|
|
115
|
+
TextTemplateSpanList = 1113,
|
|
116
|
+
TextTranslationDeclaration = 1114,
|
|
117
|
+
TextTranslationFunctionDeclaration = 1115,
|
|
118
|
+
TokenExpression = 1116,
|
|
119
|
+
TopLevelTranslationList = 1117,
|
|
120
|
+
TranslationParameterClause = 1118,
|
|
121
|
+
TranslationParameterList = 1119,
|
|
122
|
+
TranslationTextLiteral = 1120,
|
|
123
|
+
TranslationTextTemplate = 1121,
|
|
124
|
+
TranslationTextTemplateParameter = 1122,
|
|
125
|
+
TranslationTextTemplateSpan = 1123,
|
|
126
|
+
TranslationTextTemplateSpanList = 1124,
|
|
127
|
+
TranslationTypeParameterClause = 1125,
|
|
128
|
+
TranslationTypeParameterList = 1126,
|
|
129
|
+
TranslationsDeclaration = 1127,
|
|
130
|
+
TryStatement = 1128,
|
|
131
|
+
TypeAnnotation = 1129,
|
|
132
|
+
TypeArgumentClause = 1130,
|
|
133
|
+
TypeArgumentList = 1131,
|
|
134
|
+
TypeMemberDeclarationBlock = 1132,
|
|
135
|
+
TypeMemberDeclarationList = 1133,
|
|
136
|
+
TypeMemberGroupDeclaration = 1134,
|
|
137
|
+
TypeMemberTranslationList = 1135,
|
|
138
|
+
TypeParameterClause = 1136,
|
|
139
|
+
TypeParameterDeclaration = 1137,
|
|
140
|
+
TypeParameterDeclarationList = 1138,
|
|
141
|
+
TypeParameterReference = 1139,
|
|
142
|
+
TypeParameterReferenceList = 1140,
|
|
143
|
+
TypeTranslationDeclaration = 1141,
|
|
144
|
+
UnionTypeSpecifier = 1142,
|
|
145
|
+
VariableInitializer = 1143,
|
|
146
|
+
VariantValueDeclaration = 1144,
|
|
147
|
+
WhileStatement = 1145,
|
|
148
|
+
YieldStatement = 1146
|
|
4
149
|
}
|