@artel/artc 0.6.25285 → 0.6.25286
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 +2 -2
- package/build/api/ApiNodeJS.js +3 -3
- package/build/api/ApiServices.js +3 -2
- package/build/{chunk-IQ4WP3GU.js → chunk-FCVCEIPF.js} +18 -7
- package/build/{chunk-YQATIDSS.js → chunk-GEHKHJWI.js} +11 -4
- package/build/{chunk-NYUW7OAM.js → chunk-OLLM5TTI.js} +1 -1
- package/build/types/emitter/Emitter.d.ts +2 -0
- package/build/types/emitter/GeneralLowering.d.ts +4 -1
- package/package.json +1 -1
package/build/Cli.js
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import {
|
|
3
3
|
CommandLineCompiler
|
|
4
|
-
} from "./chunk-
|
|
5
|
-
import "./chunk-
|
|
4
|
+
} from "./chunk-GEHKHJWI.js";
|
|
5
|
+
import "./chunk-OLLM5TTI.js";
|
|
6
6
|
import {
|
|
7
7
|
__async
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-FCVCEIPF.js";
|
|
9
9
|
|
|
10
10
|
// source/Cli.ts
|
|
11
11
|
function main() {
|
package/build/api/Api.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
Compiler
|
|
3
|
-
} from "../chunk-
|
|
3
|
+
} from "../chunk-OLLM5TTI.js";
|
|
4
4
|
import {
|
|
5
5
|
AccessKind,
|
|
6
6
|
AccessedFunctionParameter,
|
|
@@ -346,7 +346,7 @@ import {
|
|
|
346
346
|
withoutQuotes,
|
|
347
347
|
withoutTemplateQuotes,
|
|
348
348
|
yieldTask
|
|
349
|
-
} from "../chunk-
|
|
349
|
+
} from "../chunk-FCVCEIPF.js";
|
|
350
350
|
export {
|
|
351
351
|
AccessKind,
|
|
352
352
|
AccessedFunctionParameter,
|
package/build/api/ApiNodeJS.js
CHANGED
|
@@ -6,9 +6,9 @@ import {
|
|
|
6
6
|
PhysicalFileSystem,
|
|
7
7
|
PhysicalTypeScriptLibrariesProvider,
|
|
8
8
|
PrintingDiagnosticAcceptor
|
|
9
|
-
} from "../chunk-
|
|
10
|
-
import "../chunk-
|
|
11
|
-
import "../chunk-
|
|
9
|
+
} from "../chunk-GEHKHJWI.js";
|
|
10
|
+
import "../chunk-OLLM5TTI.js";
|
|
11
|
+
import "../chunk-FCVCEIPF.js";
|
|
12
12
|
export {
|
|
13
13
|
CommandLineCompiler,
|
|
14
14
|
FileSystemUri,
|
package/build/api/ApiServices.js
CHANGED
|
@@ -183,7 +183,7 @@ import {
|
|
|
183
183
|
unwrapParenthesizedExpressions,
|
|
184
184
|
visitChildren,
|
|
185
185
|
yieldTask
|
|
186
|
-
} from "../chunk-
|
|
186
|
+
} from "../chunk-FCVCEIPF.js";
|
|
187
187
|
|
|
188
188
|
// source/services/CustomRequests.ts
|
|
189
189
|
import * as ls from "vscode-languageserver";
|
|
@@ -13981,7 +13981,8 @@ var _LanguageServer = class _LanguageServer {
|
|
|
13981
13981
|
}
|
|
13982
13982
|
const options7 = {
|
|
13983
13983
|
importEmitKind: 2 /* Custom */,
|
|
13984
|
-
isCustomImportSynchronous: true
|
|
13984
|
+
isCustomImportSynchronous: true,
|
|
13985
|
+
attachSyntaxNodeUri: true
|
|
13985
13986
|
};
|
|
13986
13987
|
let result;
|
|
13987
13988
|
try {
|
|
@@ -764,7 +764,7 @@ var UniqueWithComparatorQuery = class extends Query {
|
|
|
764
764
|
};
|
|
765
765
|
|
|
766
766
|
// source/common/Constants.ts
|
|
767
|
-
var ArtelVersion = true ? "0.6.
|
|
767
|
+
var ArtelVersion = true ? "0.6.25286" : "";
|
|
768
768
|
var ArtelSourceFileExtensions = [".\u0430\u0440\u0442", ".\u0430\u0440\u0442\u0435\u043B\u044C", ".art", ".artel", ".\u0430\u0440\u0442\u043C", ".\u0430\u0440\u0442\u0435\u043B\u044C\u043C", ".artm", ".artelm"];
|
|
769
769
|
var ArtelSourceFileExtensionSet = new Set(ArtelSourceFileExtensions);
|
|
770
770
|
var ArtelSourceAndConfigurationFileExtensionSet = new Set(ArtelSourceFileExtensionSet).add(".json");
|
|
@@ -65172,8 +65172,8 @@ function replaceNode(node) {
|
|
|
65172
65172
|
|
|
65173
65173
|
// source/emitter/GeneralLowering.ts
|
|
65174
65174
|
var GeneralLowering = class {
|
|
65175
|
-
constructor(ectx, packages) {
|
|
65176
|
-
this.ctx = new GeneralLoweringContext(ectx, packages);
|
|
65175
|
+
constructor(ectx, packages, options) {
|
|
65176
|
+
this.ctx = new GeneralLoweringContext(ectx, packages, options);
|
|
65177
65177
|
}
|
|
65178
65178
|
lower() {
|
|
65179
65179
|
const compoundDeclarationsLowering = new CompoundDeclarationsAndOperatorsLowering(this.ctx);
|
|
@@ -65209,7 +65209,7 @@ var GeneralLowering = class {
|
|
|
65209
65209
|
}
|
|
65210
65210
|
};
|
|
65211
65211
|
var GeneralLoweringContext = class {
|
|
65212
|
-
constructor(ectx, packages) {
|
|
65212
|
+
constructor(ectx, packages, options) {
|
|
65213
65213
|
this.proxyVariableByOriginal = /* @__PURE__ */ new Map();
|
|
65214
65214
|
this.overloadedConstructorGroupByOriginalConstructor = /* @__PURE__ */ new Map();
|
|
65215
65215
|
this.id = 0;
|
|
@@ -65234,6 +65234,7 @@ var GeneralLoweringContext = class {
|
|
|
65234
65234
|
this.translatorLanguageField_ = new Cached();
|
|
65235
65235
|
this.ectx = ectx;
|
|
65236
65236
|
this.packages = packages;
|
|
65237
|
+
this.options = options;
|
|
65237
65238
|
this.helperFunctions = new HelperFunctions(this);
|
|
65238
65239
|
}
|
|
65239
65240
|
static {
|
|
@@ -67724,7 +67725,10 @@ var UsagesLowering = class _UsagesLowering extends ExecutableCodeLowering {
|
|
|
67724
67725
|
return preserveStatement();
|
|
67725
67726
|
},
|
|
67726
67727
|
transformFunctionLiteral: (node) => {
|
|
67727
|
-
|
|
67728
|
+
let result;
|
|
67729
|
+
if (this.ctx.options.attachSyntaxNodeUri) {
|
|
67730
|
+
result = this.tryAttachSyntaxNodePathToFunctionLiteral(node);
|
|
67731
|
+
}
|
|
67728
67732
|
if (result !== void 0) {
|
|
67729
67733
|
return result;
|
|
67730
67734
|
}
|
|
@@ -72362,7 +72366,8 @@ var Emitter = class _Emitter {
|
|
|
72362
72366
|
taskController
|
|
72363
72367
|
);
|
|
72364
72368
|
const emitterPackages = Query.from(this.enumerateEmittingSourcePackages()).map((p) => this.createEmitterPackageFromSource(p, declarationsUsageInfo)).toArray();
|
|
72365
|
-
const
|
|
72369
|
+
const options = this.getGeneralLoweringOptions();
|
|
72370
|
+
const generalLowering = new GeneralLowering(this.ectx, emitterPackages, options);
|
|
72366
72371
|
generalLowering.lower();
|
|
72367
72372
|
const packageWithMainFunction = this.createPackageWithMainFunction(emitterPackages, emitterPackages[0].ir.entity);
|
|
72368
72373
|
emitterPackages.push(packageWithMainFunction);
|
|
@@ -72402,7 +72407,8 @@ var Emitter = class _Emitter {
|
|
|
72402
72407
|
taskController
|
|
72403
72408
|
);
|
|
72404
72409
|
const emitterPackages = Query.from(this.enumerateEmittingSourcePackages()).map((p) => this.createEmitterPackageFromSource(p, declarationsUsageInfo)).toArray();
|
|
72405
|
-
const
|
|
72410
|
+
const options = this.getGeneralLoweringOptions();
|
|
72411
|
+
const generalLowering = new GeneralLowering(this.ectx, emitterPackages, options);
|
|
72406
72412
|
generalLowering.lower();
|
|
72407
72413
|
const packageWithMainFunction = this.createPackageWithMainFunction(emitterPackages, emitterPackages[0].ir.entity);
|
|
72408
72414
|
emitterPackages.push(packageWithMainFunction);
|
|
@@ -72424,6 +72430,11 @@ var Emitter = class _Emitter {
|
|
|
72424
72430
|
return code;
|
|
72425
72431
|
});
|
|
72426
72432
|
}
|
|
72433
|
+
getGeneralLoweringOptions() {
|
|
72434
|
+
return {
|
|
72435
|
+
attachSyntaxNodeUri: this.options?.attachSyntaxNodeUri ?? false
|
|
72436
|
+
};
|
|
72437
|
+
}
|
|
72427
72438
|
createEmitterPackageFromSource(pkg2, declarationsUsageInfo) {
|
|
72428
72439
|
const irBuilder = new IrBuilder(this.ectx, this.entityMap, declarationsUsageInfo);
|
|
72429
72440
|
const irPackage = irBuilder.build(pkg2);
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
Compiler
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-OLLM5TTI.js";
|
|
4
4
|
import {
|
|
5
5
|
ArtelVersion,
|
|
6
6
|
Cached,
|
|
@@ -15,7 +15,7 @@ import {
|
|
|
15
15
|
__async,
|
|
16
16
|
performanceMeasurementStageNames,
|
|
17
17
|
performanceMeasurementStages
|
|
18
|
-
} from "./chunk-
|
|
18
|
+
} from "./chunk-FCVCEIPF.js";
|
|
19
19
|
|
|
20
20
|
// source/executor/FileSystemUri.ts
|
|
21
21
|
import { platform } from "os";
|
|
@@ -397,7 +397,8 @@ var CommandLineCompiler = class {
|
|
|
397
397
|
sourceMap: {
|
|
398
398
|
mode: "linked" /* Linked */,
|
|
399
399
|
includeSourcesContent: false
|
|
400
|
-
}
|
|
400
|
+
},
|
|
401
|
+
attachSyntaxNodeUri: parsedArguments.attachSyntaxNodeUrisInCompiledCode
|
|
401
402
|
},
|
|
402
403
|
controller: new TaskController(-1)
|
|
403
404
|
};
|
|
@@ -469,7 +470,8 @@ var ArgumentsParser = class {
|
|
|
469
470
|
defaultTsLibraryPath: void 0,
|
|
470
471
|
workspacePath: void 0,
|
|
471
472
|
standardPackagesPath: void 0,
|
|
472
|
-
builtInStandardPackagesPath: void 0
|
|
473
|
+
builtInStandardPackagesPath: void 0,
|
|
474
|
+
attachSyntaxNodeUrisInCompiledCode: false
|
|
473
475
|
};
|
|
474
476
|
const index = this.parseMainCommand(0, args, result);
|
|
475
477
|
this.parseNamedArguments(index, args, result);
|
|
@@ -591,6 +593,11 @@ var ArgumentsParser = class {
|
|
|
591
593
|
result.measurePerformance = true;
|
|
592
594
|
break;
|
|
593
595
|
}
|
|
596
|
+
case "--\u0434\u043E\u0431\u0430\u0432\u043B\u044F\u0442\u044C-uri-\u0441\u0438\u043D\u0442\u0430\u043A\u0441\u0438\u0447\u0435\u0441\u043A\u0438\u0445-\u0443\u0437\u043B\u043E\u0432-\u0432-\u0441\u043A\u043E\u043C\u043F\u0438\u043B\u0438\u0440\u043E\u0432\u0430\u043D\u043D\u044B\u0439-\u043A\u043E\u0434":
|
|
597
|
+
case "--attach-syntax-node-uris-in-compiled-code": {
|
|
598
|
+
result.attachSyntaxNodeUrisInCompiledCode = true;
|
|
599
|
+
break;
|
|
600
|
+
}
|
|
594
601
|
}
|
|
595
602
|
}
|
|
596
603
|
}
|
|
@@ -14,6 +14,7 @@ export declare class Emitter {
|
|
|
14
14
|
constructor(analyzer: Analyzer, options: EmitOptions | undefined);
|
|
15
15
|
emitToFileSystem(outputUri: Uri, outputAcceptor: OutputAcceptor, taskController: TaskController): Promise<void>;
|
|
16
16
|
emitToString(taskController: TaskController): Promise<string>;
|
|
17
|
+
private getGeneralLoweringOptions;
|
|
17
18
|
private createEmitterPackageFromSource;
|
|
18
19
|
private enumerateEmittingSourcePackages;
|
|
19
20
|
private createPackageWithMainFunction;
|
|
@@ -46,6 +47,7 @@ export interface EmitOptions {
|
|
|
46
47
|
* Является ли функция `_artelImport` синхронной?
|
|
47
48
|
*/
|
|
48
49
|
isCustomImportSynchronous?: boolean;
|
|
50
|
+
attachSyntaxNodeUri?: boolean;
|
|
49
51
|
}
|
|
50
52
|
export interface SourceMapOptions {
|
|
51
53
|
mode?: SourceMapMode;
|
|
@@ -1,7 +1,10 @@
|
|
|
1
1
|
import { EmitterPackage } from './Emitter.js';
|
|
2
2
|
import { EmitterContext } from './EmitterContext.js';
|
|
3
|
+
export interface GeneralLoweringOptions {
|
|
4
|
+
readonly attachSyntaxNodeUri: boolean;
|
|
5
|
+
}
|
|
3
6
|
export declare class GeneralLowering {
|
|
4
7
|
private readonly ctx;
|
|
5
|
-
constructor(ectx: EmitterContext, packages: readonly EmitterPackage[]);
|
|
8
|
+
constructor(ectx: EmitterContext, packages: readonly EmitterPackage[], options: GeneralLoweringOptions);
|
|
6
9
|
lower(): void;
|
|
7
10
|
}
|