@artel/artc 0.6.25266 → 0.6.25268

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.
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  Compiler
3
- } from "./chunk-2Y343AG7.js";
3
+ } from "./chunk-65DE73QR.js";
4
4
  import {
5
5
  ArtelVersion,
6
6
  Cached,
@@ -14,7 +14,7 @@ import {
14
14
  __async,
15
15
  performanceMeasurementStageNames,
16
16
  performanceMeasurementStages
17
- } from "./chunk-4YMBG4SM.js";
17
+ } from "./chunk-SXWZFJ3Z.js";
18
18
 
19
19
  // source/executor/FileSystemUri.ts
20
20
  import { platform } from "os";
@@ -28,13 +28,14 @@ export declare class ResolutionResult {
28
28
  export type Meaning = Meaning_tagType | Meaning_tagFunction | Meaning_unresolved;
29
29
  declare class Meaning_tagType {
30
30
  readonly type: types.Type;
31
+ readonly typeEntity: NamedTypeEntity | undefined;
31
32
  readonly candidates: readonly types.Constructor[];
32
33
  readonly suitableConstructors: readonly types.Constructor[];
33
34
  readonly singleNotSuitableSubstitutedCandidate: types.Constructor | undefined;
34
35
  readonly kind = "tag-type";
35
36
  get singleSuitableConstructor(): types.Constructor | undefined;
36
37
  get singleConstructor(): types.Constructor | undefined;
37
- constructor(type: types.Type, candidates: readonly types.Constructor[], suitableConstructors: readonly types.Constructor[], singleNotSuitableSubstitutedCandidate: types.Constructor | undefined);
38
+ constructor(type: types.Type, typeEntity: NamedTypeEntity | undefined, candidates: readonly types.Constructor[], suitableConstructors: readonly types.Constructor[], singleNotSuitableSubstitutedCandidate: types.Constructor | undefined);
38
39
  }
39
40
  declare class Meaning_tagFunction {
40
41
  readonly candidates: readonly NotSubstitutedAccessedFunction[];
@@ -1,4 +1,4 @@
1
- import { ParameterEntity } from '../entities/index.js';
1
+ import { FunctionEntity, ParameterEntity, TypeEntity } from '../entities/index.js';
2
2
  import * as types from '../types/index.js';
3
3
  import { AccessedFunction } from './AccessedFunction.js';
4
4
  export type Tag = TagType | TagFunction;
@@ -6,17 +6,21 @@ declare abstract class TagBase {
6
6
  readonly argumentByParameter: ReadonlyMap<ParameterEntity, TagArgument>;
7
7
  private readonly argumentByNameKey_;
8
8
  get argumentByNameKey(): ReadonlyMap<string, TagArgument>;
9
+ abstract get typeOrFunctionEntity(): TypeEntity | FunctionEntity;
9
10
  constructor(argumentByParameter: ReadonlyMap<ParameterEntity, TagArgument>);
10
11
  }
11
12
  export declare class TagType extends TagBase {
12
13
  readonly kind = "type";
13
14
  readonly type: types.Type;
15
+ readonly typeEntity: TypeEntity;
14
16
  readonly constructor_: types.Constructor;
15
- constructor(type: types.Type, constructor_: types.Constructor, argumentByParameter: ReadonlyMap<ParameterEntity, TagArgument>);
17
+ get typeOrFunctionEntity(): TypeEntity | FunctionEntity;
18
+ constructor(type: types.Type, typeEntity: TypeEntity, constructor_: types.Constructor, argumentByParameter: ReadonlyMap<ParameterEntity, TagArgument>);
16
19
  }
17
20
  export declare class TagFunction extends TagBase {
18
21
  readonly kind = "function";
19
22
  readonly func: AccessedFunction;
23
+ get typeOrFunctionEntity(): TypeEntity | FunctionEntity;
20
24
  constructor(func: AccessedFunction, argumentByParameter: ReadonlyMap<ParameterEntity, TagArgument>);
21
25
  }
22
26
  export type TagArgument = TagArgument_string | TagArgument_numeric | TagArgument_boolean | TagArgument_invalid;
@@ -1,4 +1,4 @@
1
- import { Entity, FunctionEntity, StructuredTypeEntity, TypeParameterEntity, VariableEntity } from '../entities/index.js';
1
+ import { Entity, FunctionEntity, TypeEntity, TypeParameterEntity, VariableEntity } from '../entities/index.js';
2
2
  import * as tree from '../tree/index.js';
3
3
  import * as types from '../types/index.js';
4
4
  import { PackageNameTreeNode } from './ImportedPackageNameTree.js';
@@ -11,8 +11,9 @@ export declare function getParentGenericSpecializationExpression(expression: tre
11
11
  export declare function getGenericSpecializationExpressionOfCallee(callee: tree.Expression): tree.GenericSpecializationExpression | undefined;
12
12
  export declare function unaliasType(type: types.Type): types.Type;
13
13
  export declare function unaliasType(type: types.Type | undefined): types.Type | undefined;
14
- export declare function findTag(tagTypeEntity: StructuredTypeEntity, tags: readonly Tag[]): TagType | undefined;
14
+ export declare function findTag(tagTypeEntity: TypeEntity, tags: readonly Tag[]): TagType | undefined;
15
15
  export declare function findTag(tagFunctionEntity: FunctionEntity, tags: readonly Tag[]): TagFunction | undefined;
16
+ export declare function findTag(tagEntity: TypeEntity | FunctionEntity, tags: readonly Tag[]): TagType | TagFunction | undefined;
16
17
  export declare function getRequiredTypeParameterCount(typeParameters: readonly TypeParameterEntity[]): number;
17
18
  export declare function flattenPackageMemberDeclarationList(list: tree.PackageMemberDeclarationList): Iterable<Exclude<tree.PackageMemberDeclaration, tree.PackageMemberGroupDeclaration>>;
18
19
  export declare function flattenTypeMemberDeclarationList(list: tree.TypeMemberDeclarationList): Iterable<Exclude<tree.TypeMemberDeclaration, tree.TypeMemberGroupDeclaration>>;
@@ -18,7 +18,6 @@ export declare class Emitter {
18
18
  private enumerateEmittingSourcePackages;
19
19
  private createPackageWithMainFunction;
20
20
  private createMainFunction;
21
- private createMainFunctionCall;
22
21
  private createUniqueNamesForPackageMembers;
23
22
  private setOutputUris;
24
23
  private addImports;
@@ -37,18 +37,17 @@ export declare function continueLoopStatement(label: string, sourceLocation?: ir
37
37
  export declare function dereferenceExpression(expression: ir.Expression, isOptionalAccess: boolean, access: ir.ComputedAccess, sourceLocation?: ir.SourceLocation): ir.DereferenceExpression;
38
38
  export declare function disposeStatement(expression: ir.Expression, destructorEntity: FunctionEntity, sourceLocation?: ir.SourceLocation): ir.DisposeStatement;
39
39
  export declare function emptyStatement(sourceLocation?: ir.SourceLocation): ir.EmptyStatement;
40
- export declare function errorStatement(expression: ir.Expression, sourceLocation?: ir.SourceLocation, options?: ir.ErrorStatementEmitOptions): ir.ErrorStatement;
40
+ export declare function errorStatement(expression: ir.Expression, sourceLocation?: ir.SourceLocation): ir.ErrorStatement;
41
41
  export declare function importantStatement(expression: ir.Expression, sourceLocation?: ir.SourceLocation): ir.ImportantStatement;
42
42
  export declare function expressionStatement(expression: ir.Expression, sourceLocation?: ir.SourceLocation): ir.ExpressionStatement;
43
43
  export declare function finallyClause(body: ir.BlockStatement, sourceLocation?: ir.SourceLocation): ir.FinallyClause;
44
- export declare function forStatement(label: string | undefined, elementVariableEntity: VariableEntity, indexVariableEntity: VariableEntity | undefined, enumeratedExpression: ir.Expression, body: ir.BlockStatement, ifExpressionIsNotEnumerableThenEnumeratorMethod: ir.AccessedFunction | undefined, sourceLocation?: ir.SourceLocation, options?: ir.ForStatementEmitOptions): ir.ForStatement;
44
+ export declare function forStatement(label: string | undefined, elementVariableEntity: VariableEntity, indexVariableEntity: VariableEntity | undefined, enumeratedExpression: ir.Expression, body: ir.BlockStatement, sourceLocation?: ir.SourceLocation): ir.ForStatement;
45
45
  export declare function ifStatement(condition: ir.Expression, thenStatement: ir.BlockStatement, elseStatement: ir.BlockStatement | undefined, sourceLocation?: ir.SourceLocation): ir.IfStatement;
46
46
  export declare function indexedGetAccessExpression(expression: ir.Expression, getter: FunctionEntity | ir.AccessedFunction, args: readonly ir.Expression[] | ir.Arguments, isOptionalAccess: boolean, sourceLocation?: ir.SourceLocation): ir.IndexedAccessExpression;
47
47
  export declare function indexedSetAccessExpression(expression: ir.Expression, setter: FunctionEntity | ir.AccessedFunction, args: readonly ir.Expression[] | ir.Arguments, isOptionalAccess: boolean, sourceLocation?: ir.SourceLocation): ir.IndexedAccessExpression;
48
48
  export declare function inlineJsExpression(code: string, type: Type, sourceLocation?: ir.SourceLocation): ir.InlineJsExpression;
49
49
  export declare function integerLiteral(value: number, sourceLocation?: ir.SourceLocation): ir.IntegerLiteral;
50
50
  export declare function isExpression(expression: ir.Expression, type: Type, sourceLocation?: ir.SourceLocation): ir.IsExpression;
51
- export declare function jsFunctionLiteral(parameters: readonly ir.ParameterDeclaration[], body: ir.BlockStatement, isAsync: boolean, isGenerator: boolean, sourceLocation?: ir.SourceLocation): ir.JsFunctionLiteral;
52
51
  export declare function jsIdentifierExpression(identifier: string, sourceLocation?: ir.SourceLocation): ir.JsIdentifierExpression;
53
52
  export declare function esModuleImportDirectiveStatement(defaultImport: string | undefined, importSpecifiers: readonly ir.JsImportSpecifier[], path: string, sourceLocation?: ir.SourceLocation): ir.EsModuleImportDirectiveStatement;
54
53
  export declare function cjsModuleImportDirectiveStatement(defaultImport: string, importSpecifiers: readonly ir.JsImportSpecifier[], path: string, sourceLocation?: ir.SourceLocation): ir.CjsModuleImportDirectiveStatement;
@@ -62,25 +61,27 @@ export declare function functionJsObjectLiteralProperty(key: ir.JsObjectLiteralP
62
61
  export declare function spreadJsObjectLiteralProperty(expression: ir.Expression, sourceLocation?: ir.SourceLocation): ir.SpreadJsObjectLiteralProperty;
63
62
  export declare function jsPropertyAccessExpression(expression: ir.Expression, isOptionalAccess: boolean, name: string, type: Type, sourceLocation?: ir.SourceLocation): ir.JsPropertyAccessExpression;
64
63
  export declare function jsTypeOfExpression(expression: ir.Expression, sourceLocation?: ir.SourceLocation): ir.JsTypeOfExpression;
65
- export declare function localVariableDeclaration(entity: VariableEntity, initializer: ir.Expression | undefined, sourceLocation?: ir.SourceLocation, options?: ir.DeclarationWithInitializerEmitOptions): ir.LocalVariableDeclaration;
66
- export declare function localVariableDeclarationStatement(declaration: ir.LocalVariableDeclaration, sourceLocation?: ir.SourceLocation): ir.LocalVariableDeclarationStatement;
64
+ export declare function localVariableDeclaration(entity: VariableEntity, initializer: ir.Expression | undefined, sourceLocation?: ir.SourceLocation): ir.LocalVariableDeclaration;
65
+ export declare function localVariableDeclarationStatement(entity: VariableEntity, initializer: ir.Expression | undefined, sourceLocation?: ir.SourceLocation): ir.LocalVariableDeclarationStatement;
66
+ export declare function localVariableDeclarationStatementFromDeclaration(declaration: ir.LocalVariableDeclaration, sourceLocation?: ir.SourceLocation): ir.LocalVariableDeclarationStatement;
67
67
  export declare function loopStatement(label: string | undefined, body: ir.BlockStatement, condition: ir.Expression | undefined, sourceLocation?: ir.SourceLocation): ir.LoopStatement;
68
68
  export declare function measureLiteral(sourceLocation?: ir.SourceLocation): ir.MeasureLiteral;
69
- export declare function functionAccessExpression(func: ir.AccessedFunction, isCallee: boolean, sourceLocation?: ir.SourceLocation, options?: ir.FunctionAccessExpressionEmitOptions): ir.FunctionAccessExpression;
70
- export declare function functionLiteral(parameters: readonly ir.ParameterDeclaration[], body: ir.BlockStatement, isAsync: boolean, returnType: Type, sourceLocation?: ir.SourceLocation, options?: ir.FunctionLiteralEmitOptions): ir.FunctionLiteral;
71
- export declare function nestedFunctionDeclaration(parameters: readonly ir.ParameterDeclaration[], body: ir.BlockStatement, entity: FunctionEntity, isAsync: boolean, isGenerator: boolean, sourceLocation?: ir.SourceLocation): ir.NestedFunctionDeclaration;
72
- export declare function nestedFunctionDeclarationStatement(declaration: ir.NestedFunctionDeclaration, sourceLocation?: ir.SourceLocation): ir.NestedFunctionDeclarationStatement;
69
+ export declare function functionAccessExpression(func: ir.AccessedFunction, isCallee: boolean, sourceLocation?: ir.SourceLocation): ir.FunctionAccessExpression;
70
+ export declare function functionLiteral(parameters: readonly ir.ParameterDeclaration[], body: ir.BlockStatement, isAsync: boolean, returnType: Type, sourceLocation?: ir.SourceLocation): ir.FunctionLiteral;
71
+ export declare function nestedFunctionDeclaration(entity: FunctionEntity, parameters: readonly ir.ParameterDeclaration[], body: ir.BlockStatement, isAsync: boolean, isGenerator: boolean, sourceLocation?: ir.SourceLocation): ir.NestedFunctionDeclaration;
72
+ export declare function nestedFunctionDeclarationStatement(entity: FunctionEntity, parameters: readonly ir.ParameterDeclaration[], body: ir.BlockStatement, isAsync: boolean, isGenerator: boolean, sourceLocation?: ir.SourceLocation): ir.NestedFunctionDeclarationStatement;
73
+ export declare function nestedFunctionDeclarationStatementWithDeclaration(declaration: ir.NestedFunctionDeclaration, sourceLocation?: ir.SourceLocation): ir.NestedFunctionDeclarationStatement;
73
74
  export declare function nullLiteral(sourceLocation?: ir.SourceLocation): ir.NullLiteral;
74
75
  export declare function numericLiteral(value: number, sourceLocation?: ir.SourceLocation): ir.NumericLiteral;
75
76
  export declare function catchClause(errorVariableEntity: VariableEntity | undefined, body: ir.BlockStatement, sourceLocation?: ir.SourceLocation): ir.CatchClause;
76
- export declare function ownConstructorCallExpression(entity: FunctionEntity, containingTypeOfConstructor: TypeOrExtensionEntity, args: ir.Arguments, sourceLocation?: ir.SourceLocation): ir.OwnConstructorCallExpression;
77
- export declare function prefixUnaryExpression(operatorKind: ir.PrefixUnaryExpressionOperatorKind, expression: ir.Expression, operator: ir.AccessedFunction | undefined, sourceLocation?: ir.SourceLocation): ir.PrefixUnaryExpression;
77
+ export declare function ownConstructorCallExpression(entity: FunctionEntity, args: ir.Arguments, sourceLocation?: ir.SourceLocation): ir.OwnConstructorCallExpression;
78
+ export declare function prefixUnaryExpression(operatorKind: ir.PrefixUnaryExpressionOperatorKind, expression: ir.Expression, sourceLocation?: ir.SourceLocation): ir.PrefixUnaryExpression;
78
79
  export declare function referenceExpression(expression: ir.Expression, sourceLocation?: ir.SourceLocation): ir.ReferenceExpression;
79
80
  export declare function returnStatement(expression: ir.Expression | undefined, sourceLocation?: ir.SourceLocation): ir.ReturnStatement;
80
81
  export declare function runStatement(body: ir.BlockStatement, sourceLocation?: ir.SourceLocation): ir.RunStatement;
81
82
  export declare function tryStatement(body: ir.BlockStatement, catchClause: ir.CatchClause | undefined, finallyClause: ir.FinallyClause | undefined, sourceLocation?: ir.SourceLocation): ir.TryStatement;
82
83
  export declare function switchStatement(matchExpression: ir.Expression, caseClauses: readonly ir.CaseClause[], defaultClauseBody: ir.BlockStatement | undefined, sourceLocation?: ir.SourceLocation): ir.SwitchStatement;
83
- export declare function caseClause(expressions: readonly ir.Expression[], body: ir.BlockStatement): ir.CaseClause;
84
+ export declare function caseClause(expressions: readonly ir.Expression[], body: ir.BlockStatement, sourceLocation?: ir.SourceLocation): ir.CaseClause;
84
85
  export declare function ternaryExpression(condition: ir.Expression, firstExpression: ir.Expression, secondExpression: ir.Expression, type: Type, sourceLocation?: ir.SourceLocation): ir.TernaryExpression;
85
86
  export declare function textLiteral(value: string, sourceLocation?: ir.SourceLocation): ir.TextLiteral;
86
87
  export declare function localizableTextLiteral(value: string, code: number | undefined, sourceLocation?: ir.SourceLocation): ir.LocalizableTextLiteral;
@@ -110,6 +111,7 @@ export declare function translationTextTemplate(fragments: readonly string[], pa
110
111
  export declare function instanceMethodCallExpression(expression: ir.Expression, method: FunctionEntity | ir.AccessedFunction, args: readonly ir.Expression[] | ir.Arguments, isOptionalAccess: boolean, sourceLocation?: ir.SourceLocation): ir.CallExpression;
111
112
  export declare function staticMethodCallExpression(method: FunctionEntity | ir.AccessedFunction, args: readonly ir.Expression[] | ir.Arguments, sourceLocation?: ir.SourceLocation): ir.CallExpression;
112
113
  export declare function constructorCallExpression(ectx: EmitterContext, constructor: FunctionEntity, args: readonly ir.Expression[] | ir.Arguments, sourceLocation?: ir.SourceLocation): ir.ConstructorCallExpression;
114
+ export declare function functionCallExpression(func: FunctionEntity | ir.AccessedFunction, args: readonly ir.Expression[] | ir.Arguments, sourceLocation?: ir.SourceLocation): ir.CallExpression;
113
115
  export declare function variableGetAccess(variable: VariableEntity | ir.AccessedVariable, sourceLocation?: ir.SourceLocation): ir.VariableAccessExpression;
114
116
  export declare function instanceFieldGetAccess(expression: ir.Expression, variable: VariableEntity | ir.AccessedVariable, isOptionalAccess: boolean, sourceLocation?: ir.SourceLocation): ir.FieldAccessExpression;
115
117
  export declare function staticFieldGetAccess(variable: VariableEntity | ir.AccessedVariable, sourceLocation?: ir.SourceLocation): ir.FieldAccessExpression;
@@ -59,7 +59,6 @@ export declare class IrToJs {
59
59
  private convertIntegerLiteral;
60
60
  private convertNumericLiteral;
61
61
  private convertFunctionLiteral;
62
- private convertJsFunctionLiteral;
63
62
  private convertJsTypeOfExpression;
64
63
  private convertJsInstanceOfExpression;
65
64
  private convertJsIdentifierExpression;
@@ -107,7 +107,6 @@ export declare class Transformer {
107
107
  transformJsIndexedAccessExpressionChildren(expression: ir.JsIndexedAccessExpression): void;
108
108
  transformJsObjectLiteralChildren(expression: ir.JsObjectLiteral): void;
109
109
  transformJsPropertyAccessExpressionChildren(expression: ir.JsPropertyAccessExpression): void;
110
- transformJsFunctionLiteralChildren(expression: ir.JsFunctionLiteral): void;
111
110
  transformJsTypeOfExpressionChildren(expression: ir.JsTypeOfExpression): void;
112
111
  transformJsInstanceOfExpressionChildren(expression: ir.JsInstanceOfExpression): void;
113
112
  transformJsIdentifierExpressionChildren(_expression: ir.JsIdentifierExpression): void;
@@ -159,7 +158,6 @@ export interface TransformationConfig {
159
158
  transformJsIndexedAccessExpression?(expression: ir.JsIndexedAccessExpression): ExpressionTransformationResult;
160
159
  transformJsObjectLiteral?(expression: ir.JsObjectLiteral): ExpressionTransformationResult;
161
160
  transformJsPropertyAccessExpression?(expression: ir.JsPropertyAccessExpression): ExpressionTransformationResult;
162
- transformJsFunctionLiteral?(expression: ir.JsFunctionLiteral): ExpressionTransformationResult;
163
161
  transformJsTypeOfExpression?(expression: ir.JsTypeOfExpression): ExpressionTransformationResult;
164
162
  transformJsInstanceOfExpression?(expression: ir.JsInstanceOfExpression): ExpressionTransformationResult;
165
163
  transformJsIdentifierExpression?(expression: ir.JsIdentifierExpression): ExpressionTransformationResult;
@@ -298,9 +298,10 @@ export declare class EmptyStatement {
298
298
  export declare class ErrorStatement {
299
299
  expression: Expression;
300
300
  sourceLocation?: SourceLocation | undefined;
301
- options: ErrorStatementEmitOptions;
302
301
  readonly kind = NodeKind.ErrorStatement;
303
- constructor(expression: Expression, sourceLocation?: SourceLocation | undefined, options?: ErrorStatementEmitOptions);
302
+ options: ErrorStatementEmitOptions;
303
+ constructor(expression: Expression, sourceLocation?: SourceLocation | undefined);
304
+ withOptions(options: ErrorStatementEmitOptions): this;
304
305
  clone(): ErrorStatement;
305
306
  }
306
307
  export declare class ImportantStatement {
@@ -330,11 +331,13 @@ export declare class ForStatement {
330
331
  indexVariableEntity: VariableEntity | undefined;
331
332
  enumeratedExpression: Expression;
332
333
  body: BlockStatement;
333
- ifExpressionIsNotEnumerableThenEnumeratorMethod: AccessedFunction | undefined;
334
334
  sourceLocation?: SourceLocation | undefined;
335
- options: ForStatementEmitOptions;
336
335
  readonly kind = NodeKind.ForStatement;
337
- constructor(label: string | undefined, elementVariableEntity: VariableEntity, indexVariableEntity: VariableEntity | undefined, enumeratedExpression: Expression, body: BlockStatement, ifExpressionIsNotEnumerableThenEnumeratorMethod: AccessedFunction | undefined, sourceLocation?: SourceLocation | undefined, options?: ForStatementEmitOptions);
336
+ ifExpressionIsNotEnumerableThenEnumeratorMethod: AccessedFunction | undefined;
337
+ options: ForStatementEmitOptions;
338
+ constructor(label: string | undefined, elementVariableEntity: VariableEntity, indexVariableEntity: VariableEntity | undefined, enumeratedExpression: Expression, body: BlockStatement, sourceLocation?: SourceLocation | undefined);
339
+ withIfExpressionIsNotEnumerableThenEnumeratorMethod(value: AccessedFunction | undefined): this;
340
+ withOptions(options: ForStatementEmitOptions): this;
338
341
  clone(): ForStatement;
339
342
  }
340
343
  export declare class IfStatement {
@@ -379,16 +382,6 @@ export declare class IsExpression {
379
382
  constructor(expression: Expression, type: Type, sourceLocation?: SourceLocation | undefined);
380
383
  clone(): IsExpression;
381
384
  }
382
- export declare class JsFunctionLiteral {
383
- parameters: readonly ParameterDeclaration[];
384
- body: BlockStatement;
385
- isAsync: boolean;
386
- isGenerator: boolean;
387
- sourceLocation?: SourceLocation | undefined;
388
- readonly kind = NodeKind.JsFunctionLiteral;
389
- constructor(parameters: readonly ParameterDeclaration[], body: BlockStatement, isAsync: boolean, isGenerator: boolean, sourceLocation?: SourceLocation | undefined);
390
- clone(): JsFunctionLiteral;
391
- }
392
385
  export declare class JsIdentifierExpression {
393
386
  identifier: string;
394
387
  sourceLocation?: SourceLocation | undefined;
@@ -510,9 +503,10 @@ export declare class LocalVariableDeclaration {
510
503
  entity: VariableEntity;
511
504
  initializer: Expression | undefined;
512
505
  sourceLocation?: SourceLocation | undefined;
513
- options: DeclarationWithInitializerEmitOptions;
514
506
  readonly kind = NodeKind.LocalVariableDeclaration;
515
- constructor(entity: VariableEntity, initializer: Expression | undefined, sourceLocation?: SourceLocation | undefined, options?: DeclarationWithInitializerEmitOptions);
507
+ options: DeclarationWithInitializerEmitOptions;
508
+ constructor(entity: VariableEntity, initializer: Expression | undefined, sourceLocation?: SourceLocation | undefined);
509
+ withOptions(options: DeclarationWithInitializerEmitOptions): this;
516
510
  clone(): LocalVariableDeclaration;
517
511
  }
518
512
  export declare class LocalVariableDeclarationStatement {
@@ -520,6 +514,7 @@ export declare class LocalVariableDeclarationStatement {
520
514
  sourceLocation?: SourceLocation | undefined;
521
515
  readonly kind = NodeKind.LocalVariableDeclarationStatement;
522
516
  constructor(declaration: LocalVariableDeclaration, sourceLocation?: SourceLocation | undefined);
517
+ withOptions(options: DeclarationWithInitializerEmitOptions): this;
523
518
  clone(): LocalVariableDeclarationStatement;
524
519
  }
525
520
  export declare class LoopStatement {
@@ -541,9 +536,10 @@ export declare class FunctionAccessExpression {
541
536
  func: AccessedFunction;
542
537
  isCallee: boolean;
543
538
  sourceLocation?: SourceLocation | undefined;
544
- options: FunctionAccessExpressionEmitOptions;
545
539
  readonly kind = NodeKind.FunctionAccessExpression;
546
- constructor(func: AccessedFunction, isCallee: boolean, sourceLocation?: SourceLocation | undefined, options?: FunctionAccessExpressionEmitOptions);
540
+ options: FunctionAccessExpressionEmitOptions;
541
+ constructor(func: AccessedFunction, isCallee: boolean, sourceLocation?: SourceLocation | undefined);
542
+ withOptions(options: FunctionAccessExpressionEmitOptions): this;
547
543
  clone(): FunctionAccessExpression;
548
544
  }
549
545
  export declare class FunctionLiteral {
@@ -552,9 +548,10 @@ export declare class FunctionLiteral {
552
548
  isAsync: boolean;
553
549
  returnType: Type;
554
550
  sourceLocation?: SourceLocation | undefined;
555
- options: FunctionLiteralEmitOptions;
556
551
  readonly kind = NodeKind.FunctionLiteral;
557
- constructor(parameters: readonly ParameterDeclaration[], body: BlockStatement, isAsync: boolean, returnType: Type, sourceLocation?: SourceLocation | undefined, options?: FunctionLiteralEmitOptions);
552
+ options: FunctionLiteralEmitOptions;
553
+ constructor(parameters: readonly ParameterDeclaration[], body: BlockStatement, isAsync: boolean, returnType: Type, sourceLocation?: SourceLocation | undefined);
554
+ withOptions(options: FunctionLiteralEmitOptions): this;
558
555
  clone(): FunctionLiteral;
559
556
  }
560
557
  export declare class Modifiers {
@@ -578,14 +575,14 @@ export declare const enum ModifierFlag {
578
575
  Async = 4
579
576
  }
580
577
  export declare class NestedFunctionDeclaration {
578
+ entity: FunctionEntity;
581
579
  parameters: readonly ParameterDeclaration[];
582
580
  body: BlockStatement;
583
- entity: FunctionEntity;
584
581
  isAsync: boolean;
585
582
  isGenerator: boolean;
586
583
  sourceLocation?: SourceLocation | undefined;
587
584
  readonly kind = NodeKind.NestedFunctionDeclaration;
588
- constructor(parameters: readonly ParameterDeclaration[], body: BlockStatement, entity: FunctionEntity, isAsync: boolean, isGenerator: boolean, sourceLocation?: SourceLocation | undefined);
585
+ constructor(entity: FunctionEntity, parameters: readonly ParameterDeclaration[], body: BlockStatement, isAsync: boolean, isGenerator: boolean, sourceLocation?: SourceLocation | undefined);
589
586
  clone(): NestedFunctionDeclaration;
590
587
  }
591
588
  export declare class NestedFunctionDeclarationStatement {
@@ -618,20 +615,20 @@ export declare class CatchClause {
618
615
  }
619
616
  export declare class OwnConstructorCallExpression {
620
617
  entity: FunctionEntity;
621
- containingTypeOfConstructor: TypeOrExtensionEntity;
622
618
  args: Arguments;
623
619
  sourceLocation?: SourceLocation | undefined;
624
620
  readonly kind = NodeKind.OwnConstructorCallExpression;
625
- constructor(entity: FunctionEntity, containingTypeOfConstructor: TypeOrExtensionEntity, args: Arguments, sourceLocation?: SourceLocation | undefined);
621
+ constructor(entity: FunctionEntity, args: Arguments, sourceLocation?: SourceLocation | undefined);
626
622
  clone(): OwnConstructorCallExpression;
627
623
  }
628
624
  export declare class PrefixUnaryExpression {
629
625
  operatorKind: PrefixUnaryExpressionOperatorKind;
630
626
  expression: Expression;
631
- operator: AccessedFunction | undefined;
632
627
  sourceLocation?: SourceLocation | undefined;
633
628
  readonly kind = NodeKind.PrefixUnaryExpression;
634
- constructor(operatorKind: PrefixUnaryExpressionOperatorKind, expression: Expression, operator: AccessedFunction | undefined, sourceLocation?: SourceLocation | undefined);
629
+ operator: AccessedFunction | undefined;
630
+ constructor(operatorKind: PrefixUnaryExpressionOperatorKind, expression: Expression, sourceLocation?: SourceLocation | undefined);
631
+ withOperator(operator: AccessedFunction | undefined): this;
635
632
  clone(): PrefixUnaryExpression;
636
633
  }
637
634
  export declare class ReferenceExpression {
@@ -676,8 +673,9 @@ export declare class SwitchStatement {
676
673
  export declare class CaseClause {
677
674
  expressions: readonly Expression[];
678
675
  body: BlockStatement;
676
+ sourceLocation?: SourceLocation | undefined;
679
677
  readonly kind = NodeKind.CaseClause;
680
- constructor(expressions: readonly Expression[], body: BlockStatement);
678
+ constructor(expressions: readonly Expression[], body: BlockStatement, sourceLocation?: SourceLocation | undefined);
681
679
  clone(): CaseClause;
682
680
  }
683
681
  export declare class TernaryExpression {
@@ -1043,23 +1041,22 @@ export declare const enum NodeKind {
1043
1041
  FunctionJsObjectLiteralProperty = 83,
1044
1042
  SpreadJsObjectLiteralProperty = 84,
1045
1043
  JsPropertyAccessExpression = 85,
1046
- JsFunctionLiteral = 86,
1047
- JsTypeOfExpression = 87,
1048
- JsInstanceOfExpression = 88,
1049
- JsIdentifierExpression = 89,
1050
- DereferenceExpression = 90,
1051
- BaseExpression = 91,
1052
- OwnConstructorCallExpression = 92,
1053
- DereferencedVariableGetterDeclaration = 93,
1054
- DereferencedVariableSetterDeclaration = 94,
1055
- JsNamespaceDestructuringStatement = 95,
1056
- ComputedFieldDeclaration = 96,
1057
- TextWithEntityName = 97,
1058
- Arguments = 98,
1059
- Decorator = 99,
1060
- TextTranslationDeclaration = 100,
1061
- TranslationTextTemplate = 101,
1062
- TranslationTextTemplateParameter = 102
1044
+ JsTypeOfExpression = 86,
1045
+ JsInstanceOfExpression = 87,
1046
+ JsIdentifierExpression = 88,
1047
+ DereferenceExpression = 89,
1048
+ BaseExpression = 90,
1049
+ OwnConstructorCallExpression = 91,
1050
+ DereferencedVariableGetterDeclaration = 92,
1051
+ DereferencedVariableSetterDeclaration = 93,
1052
+ JsNamespaceDestructuringStatement = 94,
1053
+ ComputedFieldDeclaration = 95,
1054
+ TextWithEntityName = 96,
1055
+ Arguments = 97,
1056
+ Decorator = 98,
1057
+ TextTranslationDeclaration = 99,
1058
+ TranslationTextTemplate = 100,
1059
+ TranslationTextTemplateParameter = 101
1063
1060
  }
1064
1061
  export declare const enum AssignmentOperatorKind {
1065
1062
  Equals = 0,
@@ -1,8 +1,8 @@
1
1
  import * as ir from './Nodes.js';
2
- export type Node = ir.ArrayLiteral | ir.AsExpression | ir.AssertionExpression | ir.AssignmentExpression | ir.AssignmentStatement | ir.BaseConstructorCallExpression | ir.BinaryExpression | ir.BlockStatement | ir.BooleanLiteral | ir.BreakLoopStatement | ir.CallExpression | ir.CharLiteral | ir.CommaExpression | ir.ConstructorCallExpression | ir.ContinueLoopStatement | ir.DisposeStatement | ir.RunStatement | ir.TryStatement | ir.NullLiteral | ir.EmptyStatement | ir.ErrorStatement | ir.ImportantStatement | ir.ExpressionStatement | ir.FinallyClause | ir.ForStatement | ir.PackageFunctionDeclaration | ir.PackageTypeDeclaration | ir.PackageVariableDeclaration | ir.PackageVariableGetterDeclaration | ir.PackageVariableSetterDeclaration | ir.PackageVariantTypeDeclaration | ir.IfStatement | ir.IndexedAccessExpression | ir.InlineJsExpression | ir.MethodAccessExpression | ir.FieldAccessExpression | ir.IntegerLiteral | ir.IsExpression | ir.JsIndexedAccessExpression | ir.NestedFunctionDeclaration | ir.NestedFunctionDeclarationStatement | ir.LocalVariableDeclaration | ir.LocalVariableDeclarationStatement | ir.NumericLiteral | ir.CatchClause | ir.FunctionAccessExpression | ir.FunctionLiteral | ir.PrefixUnaryExpression | ir.MeasureLiteral | ir.ReferenceExpression | ir.LoopStatement | ir.Package | ir.ReturnStatement | ir.TextLiteral | ir.LocalizableTextLiteral | ir.TextTemplateLiteral | ir.LocalizableTextTemplateLiteral | ir.ConstructorDeclaration | ir.DestructorDeclaration | ir.IndexedElementGetterDeclaration | ir.IndexedElementSetterDeclaration | ir.MethodDeclaration | ir.FieldDeclaration | ir.ComputedFieldDeclaration | ir.FieldGetterDeclaration | ir.FieldSetterDeclaration | ir.SwitchStatement | ir.TernaryExpression | ir.ThisExpression | ir.TypeAccessExpression | ir.ParameterDeclaration | ir.VariableAccessExpression | ir.VariantDeclaration | ir.WhileStatement | ir.YieldStatement | ir.JsObjectLiteral | ir.ValueJsObjectLiteralProperty | ir.FunctionJsObjectLiteralProperty | ir.SpreadJsObjectLiteralProperty | ir.JsPropertyAccessExpression | ir.JsFunctionLiteral | ir.JsTypeOfExpression | ir.JsInstanceOfExpression | ir.JsIdentifierExpression | ir.DereferenceExpression | ir.BaseExpression | ir.OwnConstructorCallExpression | ir.EsModuleImportDirectiveStatement | ir.CjsModuleImportDirectiveStatement | ir.JsNamespaceDestructuringStatement | ir.DereferencedVariableGetterDeclaration | ir.DereferencedVariableSetterDeclaration | ir.TextWithEntityName | ir.Argument | ir.Arguments | ir.Decorator | ir.TextTranslationDeclaration | ir.TranslationTextTemplate;
2
+ export type Node = ir.ArrayLiteral | ir.AsExpression | ir.AssertionExpression | ir.AssignmentExpression | ir.AssignmentStatement | ir.BaseConstructorCallExpression | ir.BinaryExpression | ir.BlockStatement | ir.BooleanLiteral | ir.BreakLoopStatement | ir.CallExpression | ir.CharLiteral | ir.CommaExpression | ir.ConstructorCallExpression | ir.ContinueLoopStatement | ir.DisposeStatement | ir.RunStatement | ir.TryStatement | ir.NullLiteral | ir.EmptyStatement | ir.ErrorStatement | ir.ImportantStatement | ir.ExpressionStatement | ir.FinallyClause | ir.ForStatement | ir.PackageFunctionDeclaration | ir.PackageTypeDeclaration | ir.PackageVariableDeclaration | ir.PackageVariableGetterDeclaration | ir.PackageVariableSetterDeclaration | ir.PackageVariantTypeDeclaration | ir.IfStatement | ir.IndexedAccessExpression | ir.InlineJsExpression | ir.MethodAccessExpression | ir.FieldAccessExpression | ir.IntegerLiteral | ir.IsExpression | ir.JsIndexedAccessExpression | ir.NestedFunctionDeclaration | ir.NestedFunctionDeclarationStatement | ir.LocalVariableDeclaration | ir.LocalVariableDeclarationStatement | ir.NumericLiteral | ir.CatchClause | ir.FunctionAccessExpression | ir.FunctionLiteral | ir.PrefixUnaryExpression | ir.MeasureLiteral | ir.ReferenceExpression | ir.LoopStatement | ir.Package | ir.ReturnStatement | ir.TextLiteral | ir.LocalizableTextLiteral | ir.TextTemplateLiteral | ir.LocalizableTextTemplateLiteral | ir.ConstructorDeclaration | ir.DestructorDeclaration | ir.IndexedElementGetterDeclaration | ir.IndexedElementSetterDeclaration | ir.MethodDeclaration | ir.FieldDeclaration | ir.ComputedFieldDeclaration | ir.FieldGetterDeclaration | ir.FieldSetterDeclaration | ir.SwitchStatement | ir.CaseClause | ir.TernaryExpression | ir.ThisExpression | ir.TypeAccessExpression | ir.ParameterDeclaration | ir.VariableAccessExpression | ir.VariantDeclaration | ir.WhileStatement | ir.YieldStatement | ir.JsObjectLiteral | ir.ValueJsObjectLiteralProperty | ir.FunctionJsObjectLiteralProperty | ir.SpreadJsObjectLiteralProperty | ir.JsPropertyAccessExpression | ir.JsTypeOfExpression | ir.JsInstanceOfExpression | ir.JsIdentifierExpression | ir.DereferenceExpression | ir.BaseExpression | ir.OwnConstructorCallExpression | ir.EsModuleImportDirectiveStatement | ir.CjsModuleImportDirectiveStatement | ir.JsNamespaceDestructuringStatement | ir.DereferencedVariableGetterDeclaration | ir.DereferencedVariableSetterDeclaration | ir.TextWithEntityName | ir.Argument | ir.Arguments | ir.Decorator | ir.TextTranslationDeclaration | ir.TranslationTextTemplate;
3
3
  export type Declaration = ir.PackageFunctionDeclaration | ir.PackageTypeDeclaration | ir.PackageVariableDeclaration | ir.PackageVariableGetterDeclaration | ir.PackageVariableSetterDeclaration | ir.PackageVariantTypeDeclaration | ir.NestedFunctionDeclaration | ir.LocalVariableDeclaration | ir.ConstructorDeclaration | ir.DestructorDeclaration | ir.IndexedElementGetterDeclaration | ir.IndexedElementSetterDeclaration | ir.MethodDeclaration | ir.FieldDeclaration | ir.FieldGetterDeclaration | ir.FieldSetterDeclaration | ir.ParameterDeclaration | ir.VariantDeclaration | ir.DereferencedVariableGetterDeclaration | ir.DereferencedVariableSetterDeclaration | ir.TextTranslationDeclaration | ir.TranslationTextTemplate;
4
4
  export type Statement = ir.AssignmentStatement | ir.BlockStatement | ir.BreakLoopStatement | ir.ContinueLoopStatement | ir.DisposeStatement | ir.RunStatement | ir.TryStatement | ir.EmptyStatement | ir.ErrorStatement | ir.ImportantStatement | ir.ExpressionStatement | ir.ForStatement | ir.IfStatement | ir.NestedFunctionDeclarationStatement | ir.LocalVariableDeclarationStatement | ir.LoopStatement | ir.ReturnStatement | ir.SwitchStatement | ir.WhileStatement | ir.YieldStatement | ir.EsModuleImportDirectiveStatement | ir.CjsModuleImportDirectiveStatement | ir.JsNamespaceDestructuringStatement;
5
- export type Expression = ir.ArrayLiteral | ir.AsExpression | ir.AssertionExpression | ir.AssignmentExpression | ir.BinaryExpression | ir.BooleanLiteral | ir.CallExpression | ir.CharLiteral | ir.CommaExpression | ir.ConstructorCallExpression | ir.NullLiteral | ir.IndexedAccessExpression | ir.InlineJsExpression | ir.MethodAccessExpression | ir.FieldAccessExpression | ir.IntegerLiteral | ir.IsExpression | ir.NumericLiteral | ir.FunctionAccessExpression | ir.FunctionLiteral | ir.PrefixUnaryExpression | ir.MeasureLiteral | ir.ReferenceExpression | ir.DereferenceExpression | ir.TextLiteral | ir.LocalizableTextLiteral | ir.TextWithEntityName | ir.TextTemplateLiteral | ir.LocalizableTextTemplateLiteral | ir.TernaryExpression | ir.ThisExpression | ir.TypeAccessExpression | ir.VariableAccessExpression | ir.BaseConstructorCallExpression | ir.JsIndexedAccessExpression | ir.JsObjectLiteral | ir.JsPropertyAccessExpression | ir.JsFunctionLiteral | ir.JsTypeOfExpression | ir.JsInstanceOfExpression | ir.JsIdentifierExpression | ir.BaseExpression | ir.OwnConstructorCallExpression;
5
+ export type Expression = ir.ArrayLiteral | ir.AsExpression | ir.AssertionExpression | ir.AssignmentExpression | ir.BinaryExpression | ir.BooleanLiteral | ir.CallExpression | ir.CharLiteral | ir.CommaExpression | ir.ConstructorCallExpression | ir.NullLiteral | ir.IndexedAccessExpression | ir.InlineJsExpression | ir.MethodAccessExpression | ir.FieldAccessExpression | ir.IntegerLiteral | ir.IsExpression | ir.NumericLiteral | ir.FunctionAccessExpression | ir.FunctionLiteral | ir.PrefixUnaryExpression | ir.MeasureLiteral | ir.ReferenceExpression | ir.DereferenceExpression | ir.TextLiteral | ir.LocalizableTextLiteral | ir.TextWithEntityName | ir.TextTemplateLiteral | ir.LocalizableTextTemplateLiteral | ir.TernaryExpression | ir.ThisExpression | ir.TypeAccessExpression | ir.VariableAccessExpression | ir.BaseConstructorCallExpression | ir.JsIndexedAccessExpression | ir.JsObjectLiteral | ir.JsPropertyAccessExpression | ir.JsTypeOfExpression | ir.JsInstanceOfExpression | ir.JsIdentifierExpression | ir.BaseExpression | ir.OwnConstructorCallExpression;
6
6
  export type TypeMemberDeclaration = ir.FieldDeclaration | ir.ComputedFieldDeclaration | ir.MethodDeclaration | ir.ConstructorDeclaration | ir.DestructorDeclaration | ir.IndexedElementGetterDeclaration | ir.IndexedElementSetterDeclaration | ir.DereferencedVariableGetterDeclaration | ir.DereferencedVariableSetterDeclaration;
7
7
  export type PackageMemberDeclaration = ir.PackageFunctionDeclaration | ir.PackageTypeDeclaration | ir.PackageVariableDeclaration | ir.PackageVariableGetterDeclaration | ir.PackageVariableSetterDeclaration | ir.PackageVariantTypeDeclaration;
8
8
  export type LocalDeclaration = ir.LocalVariableDeclaration | ir.NestedFunctionDeclaration;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@artel/artc",
3
- "version": "0.6.25266",
3
+ "version": "0.6.25268",
4
4
  "description": "Артель Компилятор | Artel Compiler",
5
5
  "author": "Nezaboodka Team <contact@nezaboodka.com>",
6
6
  "license": "LGPL-3.0-or-later",