typescript 5.0.0-dev.20230122 → 5.0.0-dev.20230125
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/lib/tsc.js +8 -8
- package/lib/tsserver.js +18 -18
- package/lib/tsserverlibrary.d.ts +1 -1
- package/lib/tsserverlibrary.js +18 -18
- package/lib/typescript.d.ts +1 -1
- package/lib/typescript.js +17 -17
- package/lib/typingsInstaller.js +5 -9
- package/package.json +1 -1
package/lib/tsc.js
CHANGED
|
@@ -23,7 +23,7 @@ var __export = (target, all) => {
|
|
|
23
23
|
|
|
24
24
|
// src/compiler/corePublic.ts
|
|
25
25
|
var versionMajorMinor = "5.0";
|
|
26
|
-
var version = `${versionMajorMinor}.0-dev.
|
|
26
|
+
var version = `${versionMajorMinor}.0-dev.20230125`;
|
|
27
27
|
|
|
28
28
|
// src/compiler/core.ts
|
|
29
29
|
var emptyArray = [];
|
|
@@ -2676,7 +2676,7 @@ var nativePerformance = nativePerformanceHooks == null ? void 0 : nativePerforma
|
|
|
2676
2676
|
function tryGetNativePerformanceHooks() {
|
|
2677
2677
|
return nativePerformanceHooks;
|
|
2678
2678
|
}
|
|
2679
|
-
var timestamp = nativePerformance ? () => nativePerformance.now() : Date.now ? Date.now : () =>
|
|
2679
|
+
var timestamp = nativePerformance ? () => nativePerformance.now() : Date.now ? Date.now : () => +/* @__PURE__ */ new Date();
|
|
2680
2680
|
|
|
2681
2681
|
// src/compiler/perfLogger.ts
|
|
2682
2682
|
var nullLogger = {
|
|
@@ -4028,7 +4028,7 @@ var PollingInterval = /* @__PURE__ */ ((PollingInterval3) => {
|
|
|
4028
4028
|
PollingInterval3[PollingInterval3["Low"] = 250] = "Low";
|
|
4029
4029
|
return PollingInterval3;
|
|
4030
4030
|
})(PollingInterval || {});
|
|
4031
|
-
var missingFileModifiedTime = new Date(0);
|
|
4031
|
+
var missingFileModifiedTime = /* @__PURE__ */ new Date(0);
|
|
4032
4032
|
function getModifiedTime(host, fileName) {
|
|
4033
4033
|
return host.getModifiedTime(fileName) || missingFileModifiedTime;
|
|
4034
4034
|
}
|
|
@@ -5123,7 +5123,7 @@ var sys = (() => {
|
|
|
5123
5123
|
if (!err) {
|
|
5124
5124
|
try {
|
|
5125
5125
|
if ((_a2 = statSync(profilePath)) == null ? void 0 : _a2.isDirectory()) {
|
|
5126
|
-
profilePath = _path.join(profilePath, `${new Date().toISOString().replace(/:/g, "-")}+P${process.pid}.cpuprofile`);
|
|
5126
|
+
profilePath = _path.join(profilePath, `${(/* @__PURE__ */ new Date()).toISOString().replace(/:/g, "-")}+P${process.pid}.cpuprofile`);
|
|
5127
5127
|
}
|
|
5128
5128
|
} catch (e) {
|
|
5129
5129
|
}
|
|
@@ -117806,7 +117806,7 @@ function getPlainDiagnosticFollowingNewLines(diagnostic, newLine) {
|
|
|
117806
117806
|
return contains(screenStartingMessageCodes, diagnostic.code) ? newLine + newLine : newLine;
|
|
117807
117807
|
}
|
|
117808
117808
|
function getLocaleTimeString(system) {
|
|
117809
|
-
return !system.now ? new Date().toLocaleTimeString() : (
|
|
117809
|
+
return !system.now ? (/* @__PURE__ */ new Date()).toLocaleTimeString() : (
|
|
117810
117810
|
// On some systems / builds of Node, there's a non-breaking space between the time and AM/PM.
|
|
117811
117811
|
// This branch is solely for testing, so just switch it to a normal space for baseline stability.
|
|
117812
117812
|
// See:
|
|
@@ -119133,8 +119133,8 @@ function resolveConfigFileProjectName(project) {
|
|
|
119133
119133
|
}
|
|
119134
119134
|
|
|
119135
119135
|
// src/compiler/tsbuildPublic.ts
|
|
119136
|
-
var minimumDate = new Date(-864e13);
|
|
119137
|
-
var maximumDate = new Date(864e13);
|
|
119136
|
+
var minimumDate = /* @__PURE__ */ new Date(-864e13);
|
|
119137
|
+
var maximumDate = /* @__PURE__ */ new Date(864e13);
|
|
119138
119138
|
function getOrCreateValueFromConfigFileMap(configFileMap, resolved, createT) {
|
|
119139
119139
|
const existingValue = configFileMap.get(resolved);
|
|
119140
119140
|
let newValue;
|
|
@@ -119148,7 +119148,7 @@ function getOrCreateValueMapFromConfigFileMap(configFileMap, resolved) {
|
|
|
119148
119148
|
return getOrCreateValueFromConfigFileMap(configFileMap, resolved, () => /* @__PURE__ */ new Map());
|
|
119149
119149
|
}
|
|
119150
119150
|
function getCurrentTime(host) {
|
|
119151
|
-
return host.now ? host.now() : new Date();
|
|
119151
|
+
return host.now ? host.now() : /* @__PURE__ */ new Date();
|
|
119152
119152
|
}
|
|
119153
119153
|
function isCircularBuildOrder(buildOrder) {
|
|
119154
119154
|
return !!buildOrder && !!buildOrder.buildOrder;
|
package/lib/tsserver.js
CHANGED
|
@@ -2373,7 +2373,7 @@ __export(ts_server_exports3, {
|
|
|
2373
2373
|
|
|
2374
2374
|
// src/compiler/corePublic.ts
|
|
2375
2375
|
var versionMajorMinor = "5.0";
|
|
2376
|
-
var version = `${versionMajorMinor}.0-dev.
|
|
2376
|
+
var version = `${versionMajorMinor}.0-dev.20230125`;
|
|
2377
2377
|
var Comparison = /* @__PURE__ */ ((Comparison3) => {
|
|
2378
2378
|
Comparison3[Comparison3["LessThan"] = -1] = "LessThan";
|
|
2379
2379
|
Comparison3[Comparison3["EqualTo"] = 0] = "EqualTo";
|
|
@@ -5428,7 +5428,7 @@ var nativePerformance = nativePerformanceHooks == null ? void 0 : nativePerforma
|
|
|
5428
5428
|
function tryGetNativePerformanceHooks() {
|
|
5429
5429
|
return nativePerformanceHooks;
|
|
5430
5430
|
}
|
|
5431
|
-
var timestamp = nativePerformance ? () => nativePerformance.now() : Date.now ? Date.now : () =>
|
|
5431
|
+
var timestamp = nativePerformance ? () => nativePerformance.now() : Date.now ? Date.now : () => +/* @__PURE__ */ new Date();
|
|
5432
5432
|
|
|
5433
5433
|
// src/compiler/perfLogger.ts
|
|
5434
5434
|
var nullLogger = {
|
|
@@ -7562,7 +7562,7 @@ var PollingInterval = /* @__PURE__ */ ((PollingInterval3) => {
|
|
|
7562
7562
|
PollingInterval3[PollingInterval3["Low"] = 250] = "Low";
|
|
7563
7563
|
return PollingInterval3;
|
|
7564
7564
|
})(PollingInterval || {});
|
|
7565
|
-
var missingFileModifiedTime = new Date(0);
|
|
7565
|
+
var missingFileModifiedTime = /* @__PURE__ */ new Date(0);
|
|
7566
7566
|
function getModifiedTime(host, fileName) {
|
|
7567
7567
|
return host.getModifiedTime(fileName) || missingFileModifiedTime;
|
|
7568
7568
|
}
|
|
@@ -8657,7 +8657,7 @@ var sys = (() => {
|
|
|
8657
8657
|
if (!err) {
|
|
8658
8658
|
try {
|
|
8659
8659
|
if ((_a2 = statSync(profilePath)) == null ? void 0 : _a2.isDirectory()) {
|
|
8660
|
-
profilePath = _path.join(profilePath, `${new Date().toISOString().replace(/:/g, "-")}+P${process.pid}.cpuprofile`);
|
|
8660
|
+
profilePath = _path.join(profilePath, `${(/* @__PURE__ */ new Date()).toISOString().replace(/:/g, "-")}+P${process.pid}.cpuprofile`);
|
|
8661
8661
|
}
|
|
8662
8662
|
} catch (e) {
|
|
8663
8663
|
}
|
|
@@ -122743,7 +122743,7 @@ function getPlainDiagnosticFollowingNewLines(diagnostic, newLine) {
|
|
|
122743
122743
|
return contains(screenStartingMessageCodes, diagnostic.code) ? newLine + newLine : newLine;
|
|
122744
122744
|
}
|
|
122745
122745
|
function getLocaleTimeString(system) {
|
|
122746
|
-
return !system.now ? new Date().toLocaleTimeString() : (
|
|
122746
|
+
return !system.now ? (/* @__PURE__ */ new Date()).toLocaleTimeString() : (
|
|
122747
122747
|
// On some systems / builds of Node, there's a non-breaking space between the time and AM/PM.
|
|
122748
122748
|
// This branch is solely for testing, so just switch it to a normal space for baseline stability.
|
|
122749
122749
|
// See:
|
|
@@ -124115,8 +124115,8 @@ function resolveConfigFileProjectName(project) {
|
|
|
124115
124115
|
}
|
|
124116
124116
|
|
|
124117
124117
|
// src/compiler/tsbuildPublic.ts
|
|
124118
|
-
var minimumDate = new Date(-864e13);
|
|
124119
|
-
var maximumDate = new Date(864e13);
|
|
124118
|
+
var minimumDate = /* @__PURE__ */ new Date(-864e13);
|
|
124119
|
+
var maximumDate = /* @__PURE__ */ new Date(864e13);
|
|
124120
124120
|
function getOrCreateValueFromConfigFileMap(configFileMap, resolved, createT) {
|
|
124121
124121
|
const existingValue = configFileMap.get(resolved);
|
|
124122
124122
|
let newValue;
|
|
@@ -124130,7 +124130,7 @@ function getOrCreateValueMapFromConfigFileMap(configFileMap, resolved) {
|
|
|
124130
124130
|
return getOrCreateValueFromConfigFileMap(configFileMap, resolved, () => /* @__PURE__ */ new Map());
|
|
124131
124131
|
}
|
|
124132
124132
|
function getCurrentTime(host) {
|
|
124133
|
-
return host.now ? host.now() : new Date();
|
|
124133
|
+
return host.now ? host.now() : /* @__PURE__ */ new Date();
|
|
124134
124134
|
}
|
|
124135
124135
|
function isCircularBuildOrder(buildOrder) {
|
|
124136
124136
|
return !!buildOrder && !!buildOrder.buildOrder;
|
|
@@ -126421,7 +126421,7 @@ function findArgument(argumentName) {
|
|
|
126421
126421
|
return index >= 0 && index < sys.args.length - 1 ? sys.args[index + 1] : void 0;
|
|
126422
126422
|
}
|
|
126423
126423
|
function nowString() {
|
|
126424
|
-
const d = new Date();
|
|
126424
|
+
const d = /* @__PURE__ */ new Date();
|
|
126425
126425
|
return `${padLeft(d.getHours().toString(), 2, "0")}:${padLeft(d.getMinutes().toString(), 2, "0")}:${padLeft(d.getSeconds().toString(), 2, "0")}.${padLeft(d.getMilliseconds().toString(), 3, "0")}`;
|
|
126426
126426
|
}
|
|
126427
126427
|
|
|
@@ -137389,12 +137389,9 @@ function createLanguageService(host, documentRegistry = createDocumentRegistry(h
|
|
|
137389
137389
|
Debug.assertEqual(action.type, "install package");
|
|
137390
137390
|
return host.installPackage ? host.installPackage({ fileName: getPath(action.file), packageName: action.packageName }) : Promise.reject("Host does not implement `installPackage`");
|
|
137391
137391
|
}
|
|
137392
|
-
function getDocCommentTemplateAtPosition2(fileName, position, options) {
|
|
137393
|
-
|
|
137394
|
-
|
|
137395
|
-
/*formatSettings*/
|
|
137396
|
-
void 0
|
|
137397
|
-
), syntaxTreeCache.getCurrentSourceFile(fileName), position, options);
|
|
137392
|
+
function getDocCommentTemplateAtPosition2(fileName, position, options, formatOptions) {
|
|
137393
|
+
const formatSettings = formatOptions ? ts_formatting_exports.getFormatContext(formatOptions, host).options : void 0;
|
|
137394
|
+
return ts_JsDoc_exports.getDocCommentTemplateAtPosition(getNewLineOrDefaultFromHost(host, formatSettings), syntaxTreeCache.getCurrentSourceFile(fileName), position, options);
|
|
137398
137395
|
}
|
|
137399
137396
|
function isValidBraceCompletionAtPosition(fileName, position, openingBrace) {
|
|
137400
137397
|
if (openingBrace === 60 /* lessThan */) {
|
|
@@ -138575,10 +138572,10 @@ var LanguageServiceShimObject = class extends ShimBase {
|
|
|
138575
138572
|
}
|
|
138576
138573
|
);
|
|
138577
138574
|
}
|
|
138578
|
-
getDocCommentTemplateAtPosition(fileName, position, options) {
|
|
138575
|
+
getDocCommentTemplateAtPosition(fileName, position, options, formatOptions) {
|
|
138579
138576
|
return this.forwardJSONCall(
|
|
138580
138577
|
`getDocCommentTemplateAtPosition('${fileName}', ${position})`,
|
|
138581
|
-
() => this.languageService.getDocCommentTemplateAtPosition(fileName, position, options)
|
|
138578
|
+
() => this.languageService.getDocCommentTemplateAtPosition(fileName, position, options, formatOptions)
|
|
138582
138579
|
);
|
|
138583
138580
|
}
|
|
138584
138581
|
/// NAVIGATE TO
|
|
@@ -157331,6 +157328,8 @@ var jsDocTagNames = [
|
|
|
157331
157328
|
"lends",
|
|
157332
157329
|
"license",
|
|
157333
157330
|
"link",
|
|
157331
|
+
"linkcode",
|
|
157332
|
+
"linkplain",
|
|
157334
157333
|
"listens",
|
|
157335
157334
|
"member",
|
|
157336
157335
|
"memberof",
|
|
@@ -157343,6 +157342,7 @@ var jsDocTagNames = [
|
|
|
157343
157342
|
"package",
|
|
157344
157343
|
"param",
|
|
157345
157344
|
"private",
|
|
157345
|
+
"prop",
|
|
157346
157346
|
"property",
|
|
157347
157347
|
"protected",
|
|
157348
157348
|
"public",
|
|
@@ -178153,7 +178153,7 @@ Project '${project.projectName}' (${ProjectKind[project.projectKind]}) ${counter
|
|
|
178153
178153
|
getDocCommentTemplate(args) {
|
|
178154
178154
|
const { file, languageService } = this.getFileAndLanguageServiceForSyntacticOperation(args);
|
|
178155
178155
|
const position = this.getPositionInFile(args, file);
|
|
178156
|
-
return languageService.getDocCommentTemplateAtPosition(file, position, this.getPreferences(file));
|
|
178156
|
+
return languageService.getDocCommentTemplateAtPosition(file, position, this.getPreferences(file), this.getFormatOptions(file));
|
|
178157
178157
|
}
|
|
178158
178158
|
getSpanOfEnclosingComment(args) {
|
|
178159
178159
|
const { file, languageService } = this.getFileAndLanguageServiceForSyntacticOperation(args);
|
package/lib/tsserverlibrary.d.ts
CHANGED
|
@@ -9990,7 +9990,7 @@ declare namespace ts {
|
|
|
9990
9990
|
getFormattingEditsForRange(fileName: string, start: number, end: number, options: FormatCodeOptions | FormatCodeSettings): TextChange[];
|
|
9991
9991
|
getFormattingEditsForDocument(fileName: string, options: FormatCodeOptions | FormatCodeSettings): TextChange[];
|
|
9992
9992
|
getFormattingEditsAfterKeystroke(fileName: string, position: number, key: string, options: FormatCodeOptions | FormatCodeSettings): TextChange[];
|
|
9993
|
-
getDocCommentTemplateAtPosition(fileName: string, position: number, options?: DocCommentTemplateOptions): TextInsertion | undefined;
|
|
9993
|
+
getDocCommentTemplateAtPosition(fileName: string, position: number, options?: DocCommentTemplateOptions, formatOptions?: FormatCodeSettings): TextInsertion | undefined;
|
|
9994
9994
|
isValidBraceCompletionAtPosition(fileName: string, position: number, openingBrace: number): boolean;
|
|
9995
9995
|
/**
|
|
9996
9996
|
* This will return a defined result if the position is after the `>` of the opening tag, or somewhere in the text, of a JSXElement with no closing tag.
|
package/lib/tsserverlibrary.js
CHANGED
|
@@ -42,7 +42,7 @@ var ts = (() => {
|
|
|
42
42
|
"src/compiler/corePublic.ts"() {
|
|
43
43
|
"use strict";
|
|
44
44
|
versionMajorMinor = "5.0";
|
|
45
|
-
version = `${versionMajorMinor}.0-dev.
|
|
45
|
+
version = `${versionMajorMinor}.0-dev.20230125`;
|
|
46
46
|
Comparison = /* @__PURE__ */ ((Comparison3) => {
|
|
47
47
|
Comparison3[Comparison3["LessThan"] = -1] = "LessThan";
|
|
48
48
|
Comparison3[Comparison3["EqualTo"] = 0] = "EqualTo";
|
|
@@ -3123,7 +3123,7 @@ ${lanes.join("\n")}
|
|
|
3123
3123
|
init_ts2();
|
|
3124
3124
|
nativePerformanceHooks = tryGetWebPerformanceHooks() || tryGetNodePerformanceHooks();
|
|
3125
3125
|
nativePerformance = nativePerformanceHooks == null ? void 0 : nativePerformanceHooks.performance;
|
|
3126
|
-
timestamp = nativePerformance ? () => nativePerformance.now() : Date.now ? Date.now : () =>
|
|
3126
|
+
timestamp = nativePerformance ? () => nativePerformance.now() : Date.now ? Date.now : () => +/* @__PURE__ */ new Date();
|
|
3127
3127
|
}
|
|
3128
3128
|
});
|
|
3129
3129
|
|
|
@@ -6179,7 +6179,7 @@ ${lanes.join("\n")}
|
|
|
6179
6179
|
PollingInterval3[PollingInterval3["Low"] = 250] = "Low";
|
|
6180
6180
|
return PollingInterval3;
|
|
6181
6181
|
})(PollingInterval || {});
|
|
6182
|
-
missingFileModifiedTime = new Date(0);
|
|
6182
|
+
missingFileModifiedTime = /* @__PURE__ */ new Date(0);
|
|
6183
6183
|
defaultChunkLevels = { Low: 32, Medium: 64, High: 256 };
|
|
6184
6184
|
pollingChunkSize = createPollingIntervalBasedLevels(defaultChunkLevels);
|
|
6185
6185
|
unchangedPollThresholds = createPollingIntervalBasedLevels(defaultChunkLevels);
|
|
@@ -6390,7 +6390,7 @@ ${lanes.join("\n")}
|
|
|
6390
6390
|
if (!err) {
|
|
6391
6391
|
try {
|
|
6392
6392
|
if ((_a2 = statSync(profilePath)) == null ? void 0 : _a2.isDirectory()) {
|
|
6393
|
-
profilePath = _path.join(profilePath, `${new Date().toISOString().replace(/:/g, "-")}+P${process.pid}.cpuprofile`);
|
|
6393
|
+
profilePath = _path.join(profilePath, `${(/* @__PURE__ */ new Date()).toISOString().replace(/:/g, "-")}+P${process.pid}.cpuprofile`);
|
|
6394
6394
|
}
|
|
6395
6395
|
} catch (e) {
|
|
6396
6396
|
}
|
|
@@ -120838,7 +120838,7 @@ ${lanes.join("\n")}
|
|
|
120838
120838
|
return contains(screenStartingMessageCodes, diagnostic.code) ? newLine + newLine : newLine;
|
|
120839
120839
|
}
|
|
120840
120840
|
function getLocaleTimeString(system) {
|
|
120841
|
-
return !system.now ? new Date().toLocaleTimeString() : (
|
|
120841
|
+
return !system.now ? (/* @__PURE__ */ new Date()).toLocaleTimeString() : (
|
|
120842
120842
|
// On some systems / builds of Node, there's a non-breaking space between the time and AM/PM.
|
|
120843
120843
|
// This branch is solely for testing, so just switch it to a normal space for baseline stability.
|
|
120844
120844
|
// See:
|
|
@@ -122253,7 +122253,7 @@ ${lanes.join("\n")}
|
|
|
122253
122253
|
return getOrCreateValueFromConfigFileMap(configFileMap, resolved, () => /* @__PURE__ */ new Map());
|
|
122254
122254
|
}
|
|
122255
122255
|
function getCurrentTime(host) {
|
|
122256
|
-
return host.now ? host.now() : new Date();
|
|
122256
|
+
return host.now ? host.now() : /* @__PURE__ */ new Date();
|
|
122257
122257
|
}
|
|
122258
122258
|
function isCircularBuildOrder(buildOrder) {
|
|
122259
122259
|
return !!buildOrder && !!buildOrder.buildOrder;
|
|
@@ -124197,8 +124197,8 @@ ${lanes.join("\n")}
|
|
|
124197
124197
|
init_ts2();
|
|
124198
124198
|
init_ts2();
|
|
124199
124199
|
init_ts_performance();
|
|
124200
|
-
minimumDate = new Date(-864e13);
|
|
124201
|
-
maximumDate = new Date(864e13);
|
|
124200
|
+
minimumDate = /* @__PURE__ */ new Date(-864e13);
|
|
124201
|
+
maximumDate = /* @__PURE__ */ new Date(864e13);
|
|
124202
124202
|
InvalidatedProjectKind = /* @__PURE__ */ ((InvalidatedProjectKind2) => {
|
|
124203
124203
|
InvalidatedProjectKind2[InvalidatedProjectKind2["Build"] = 0] = "Build";
|
|
124204
124204
|
InvalidatedProjectKind2[InvalidatedProjectKind2["UpdateBundle"] = 1] = "UpdateBundle";
|
|
@@ -124629,7 +124629,7 @@ ${lanes.join("\n")}
|
|
|
124629
124629
|
return index >= 0 && index < sys.args.length - 1 ? sys.args[index + 1] : void 0;
|
|
124630
124630
|
}
|
|
124631
124631
|
function nowString() {
|
|
124632
|
-
const d = new Date();
|
|
124632
|
+
const d = /* @__PURE__ */ new Date();
|
|
124633
124633
|
return `${padLeft(d.getHours().toString(), 2, "0")}:${padLeft(d.getMinutes().toString(), 2, "0")}:${padLeft(d.getSeconds().toString(), 2, "0")}.${padLeft(d.getMilliseconds().toString(), 3, "0")}`;
|
|
124634
124634
|
}
|
|
124635
124635
|
var ActionSet, ActionInvalidate, ActionPackageInstalled, EventTypesRegistry, EventBeginInstallTypes, EventEndInstallTypes, EventInitializationFailed, Arguments;
|
|
@@ -132743,12 +132743,9 @@ ${lanes.join("\n")}
|
|
|
132743
132743
|
Debug.assertEqual(action.type, "install package");
|
|
132744
132744
|
return host.installPackage ? host.installPackage({ fileName: getPath(action.file), packageName: action.packageName }) : Promise.reject("Host does not implement `installPackage`");
|
|
132745
132745
|
}
|
|
132746
|
-
function getDocCommentTemplateAtPosition2(fileName, position, options) {
|
|
132747
|
-
|
|
132748
|
-
|
|
132749
|
-
/*formatSettings*/
|
|
132750
|
-
void 0
|
|
132751
|
-
), syntaxTreeCache.getCurrentSourceFile(fileName), position, options);
|
|
132746
|
+
function getDocCommentTemplateAtPosition2(fileName, position, options, formatOptions) {
|
|
132747
|
+
const formatSettings = formatOptions ? ts_formatting_exports.getFormatContext(formatOptions, host).options : void 0;
|
|
132748
|
+
return ts_JsDoc_exports.getDocCommentTemplateAtPosition(getNewLineOrDefaultFromHost(host, formatSettings), syntaxTreeCache.getCurrentSourceFile(fileName), position, options);
|
|
132752
132749
|
}
|
|
132753
132750
|
function isValidBraceCompletionAtPosition(fileName, position, openingBrace) {
|
|
132754
132751
|
if (openingBrace === 60 /* lessThan */) {
|
|
@@ -134620,10 +134617,10 @@ ${lanes.join("\n")}
|
|
|
134620
134617
|
}
|
|
134621
134618
|
);
|
|
134622
134619
|
}
|
|
134623
|
-
getDocCommentTemplateAtPosition(fileName, position, options) {
|
|
134620
|
+
getDocCommentTemplateAtPosition(fileName, position, options, formatOptions) {
|
|
134624
134621
|
return this.forwardJSONCall(
|
|
134625
134622
|
`getDocCommentTemplateAtPosition('${fileName}', ${position})`,
|
|
134626
|
-
() => this.languageService.getDocCommentTemplateAtPosition(fileName, position, options)
|
|
134623
|
+
() => this.languageService.getDocCommentTemplateAtPosition(fileName, position, options, formatOptions)
|
|
134627
134624
|
);
|
|
134628
134625
|
}
|
|
134629
134626
|
/// NAVIGATE TO
|
|
@@ -154415,6 +154412,8 @@ ${lanes.join("\n")}
|
|
|
154415
154412
|
"lends",
|
|
154416
154413
|
"license",
|
|
154417
154414
|
"link",
|
|
154415
|
+
"linkcode",
|
|
154416
|
+
"linkplain",
|
|
154418
154417
|
"listens",
|
|
154419
154418
|
"member",
|
|
154420
154419
|
"memberof",
|
|
@@ -154427,6 +154426,7 @@ ${lanes.join("\n")}
|
|
|
154427
154426
|
"package",
|
|
154428
154427
|
"param",
|
|
154429
154428
|
"private",
|
|
154429
|
+
"prop",
|
|
154430
154430
|
"property",
|
|
154431
154431
|
"protected",
|
|
154432
154432
|
"public",
|
|
@@ -175499,7 +175499,7 @@ Project '${project.projectName}' (${ProjectKind[project.projectKind]}) ${counter
|
|
|
175499
175499
|
getDocCommentTemplate(args) {
|
|
175500
175500
|
const { file, languageService } = this.getFileAndLanguageServiceForSyntacticOperation(args);
|
|
175501
175501
|
const position = this.getPositionInFile(args, file);
|
|
175502
|
-
return languageService.getDocCommentTemplateAtPosition(file, position, this.getPreferences(file));
|
|
175502
|
+
return languageService.getDocCommentTemplateAtPosition(file, position, this.getPreferences(file), this.getFormatOptions(file));
|
|
175503
175503
|
}
|
|
175504
175504
|
getSpanOfEnclosingComment(args) {
|
|
175505
175505
|
const { file, languageService } = this.getFileAndLanguageServiceForSyntacticOperation(args);
|
package/lib/typescript.d.ts
CHANGED
|
@@ -6088,7 +6088,7 @@ declare namespace ts {
|
|
|
6088
6088
|
getFormattingEditsForRange(fileName: string, start: number, end: number, options: FormatCodeOptions | FormatCodeSettings): TextChange[];
|
|
6089
6089
|
getFormattingEditsForDocument(fileName: string, options: FormatCodeOptions | FormatCodeSettings): TextChange[];
|
|
6090
6090
|
getFormattingEditsAfterKeystroke(fileName: string, position: number, key: string, options: FormatCodeOptions | FormatCodeSettings): TextChange[];
|
|
6091
|
-
getDocCommentTemplateAtPosition(fileName: string, position: number, options?: DocCommentTemplateOptions): TextInsertion | undefined;
|
|
6091
|
+
getDocCommentTemplateAtPosition(fileName: string, position: number, options?: DocCommentTemplateOptions, formatOptions?: FormatCodeSettings): TextInsertion | undefined;
|
|
6092
6092
|
isValidBraceCompletionAtPosition(fileName: string, position: number, openingBrace: number): boolean;
|
|
6093
6093
|
/**
|
|
6094
6094
|
* This will return a defined result if the position is after the `>` of the opening tag, or somewhere in the text, of a JSXElement with no closing tag.
|
package/lib/typescript.js
CHANGED
|
@@ -42,7 +42,7 @@ var ts = (() => {
|
|
|
42
42
|
"src/compiler/corePublic.ts"() {
|
|
43
43
|
"use strict";
|
|
44
44
|
versionMajorMinor = "5.0";
|
|
45
|
-
version = `${versionMajorMinor}.0-dev.
|
|
45
|
+
version = `${versionMajorMinor}.0-dev.20230125`;
|
|
46
46
|
Comparison = /* @__PURE__ */ ((Comparison3) => {
|
|
47
47
|
Comparison3[Comparison3["LessThan"] = -1] = "LessThan";
|
|
48
48
|
Comparison3[Comparison3["EqualTo"] = 0] = "EqualTo";
|
|
@@ -3123,7 +3123,7 @@ ${lanes.join("\n")}
|
|
|
3123
3123
|
init_ts2();
|
|
3124
3124
|
nativePerformanceHooks = tryGetWebPerformanceHooks() || tryGetNodePerformanceHooks();
|
|
3125
3125
|
nativePerformance = nativePerformanceHooks == null ? void 0 : nativePerformanceHooks.performance;
|
|
3126
|
-
timestamp = nativePerformance ? () => nativePerformance.now() : Date.now ? Date.now : () =>
|
|
3126
|
+
timestamp = nativePerformance ? () => nativePerformance.now() : Date.now ? Date.now : () => +/* @__PURE__ */ new Date();
|
|
3127
3127
|
}
|
|
3128
3128
|
});
|
|
3129
3129
|
|
|
@@ -6179,7 +6179,7 @@ ${lanes.join("\n")}
|
|
|
6179
6179
|
PollingInterval3[PollingInterval3["Low"] = 250] = "Low";
|
|
6180
6180
|
return PollingInterval3;
|
|
6181
6181
|
})(PollingInterval || {});
|
|
6182
|
-
missingFileModifiedTime = new Date(0);
|
|
6182
|
+
missingFileModifiedTime = /* @__PURE__ */ new Date(0);
|
|
6183
6183
|
defaultChunkLevels = { Low: 32, Medium: 64, High: 256 };
|
|
6184
6184
|
pollingChunkSize = createPollingIntervalBasedLevels(defaultChunkLevels);
|
|
6185
6185
|
unchangedPollThresholds = createPollingIntervalBasedLevels(defaultChunkLevels);
|
|
@@ -6390,7 +6390,7 @@ ${lanes.join("\n")}
|
|
|
6390
6390
|
if (!err) {
|
|
6391
6391
|
try {
|
|
6392
6392
|
if ((_a2 = statSync(profilePath)) == null ? void 0 : _a2.isDirectory()) {
|
|
6393
|
-
profilePath = _path.join(profilePath, `${new Date().toISOString().replace(/:/g, "-")}+P${process.pid}.cpuprofile`);
|
|
6393
|
+
profilePath = _path.join(profilePath, `${(/* @__PURE__ */ new Date()).toISOString().replace(/:/g, "-")}+P${process.pid}.cpuprofile`);
|
|
6394
6394
|
}
|
|
6395
6395
|
} catch (e) {
|
|
6396
6396
|
}
|
|
@@ -120838,7 +120838,7 @@ ${lanes.join("\n")}
|
|
|
120838
120838
|
return contains(screenStartingMessageCodes, diagnostic.code) ? newLine + newLine : newLine;
|
|
120839
120839
|
}
|
|
120840
120840
|
function getLocaleTimeString(system) {
|
|
120841
|
-
return !system.now ? new Date().toLocaleTimeString() : (
|
|
120841
|
+
return !system.now ? (/* @__PURE__ */ new Date()).toLocaleTimeString() : (
|
|
120842
120842
|
// On some systems / builds of Node, there's a non-breaking space between the time and AM/PM.
|
|
120843
120843
|
// This branch is solely for testing, so just switch it to a normal space for baseline stability.
|
|
120844
120844
|
// See:
|
|
@@ -122253,7 +122253,7 @@ ${lanes.join("\n")}
|
|
|
122253
122253
|
return getOrCreateValueFromConfigFileMap(configFileMap, resolved, () => /* @__PURE__ */ new Map());
|
|
122254
122254
|
}
|
|
122255
122255
|
function getCurrentTime(host) {
|
|
122256
|
-
return host.now ? host.now() : new Date();
|
|
122256
|
+
return host.now ? host.now() : /* @__PURE__ */ new Date();
|
|
122257
122257
|
}
|
|
122258
122258
|
function isCircularBuildOrder(buildOrder) {
|
|
122259
122259
|
return !!buildOrder && !!buildOrder.buildOrder;
|
|
@@ -124197,8 +124197,8 @@ ${lanes.join("\n")}
|
|
|
124197
124197
|
init_ts2();
|
|
124198
124198
|
init_ts2();
|
|
124199
124199
|
init_ts_performance();
|
|
124200
|
-
minimumDate = new Date(-864e13);
|
|
124201
|
-
maximumDate = new Date(864e13);
|
|
124200
|
+
minimumDate = /* @__PURE__ */ new Date(-864e13);
|
|
124201
|
+
maximumDate = /* @__PURE__ */ new Date(864e13);
|
|
124202
124202
|
InvalidatedProjectKind = /* @__PURE__ */ ((InvalidatedProjectKind2) => {
|
|
124203
124203
|
InvalidatedProjectKind2[InvalidatedProjectKind2["Build"] = 0] = "Build";
|
|
124204
124204
|
InvalidatedProjectKind2[InvalidatedProjectKind2["UpdateBundle"] = 1] = "UpdateBundle";
|
|
@@ -124629,7 +124629,7 @@ ${lanes.join("\n")}
|
|
|
124629
124629
|
return index >= 0 && index < sys.args.length - 1 ? sys.args[index + 1] : void 0;
|
|
124630
124630
|
}
|
|
124631
124631
|
function nowString() {
|
|
124632
|
-
const d = new Date();
|
|
124632
|
+
const d = /* @__PURE__ */ new Date();
|
|
124633
124633
|
return `${padLeft(d.getHours().toString(), 2, "0")}:${padLeft(d.getMinutes().toString(), 2, "0")}:${padLeft(d.getSeconds().toString(), 2, "0")}.${padLeft(d.getMilliseconds().toString(), 3, "0")}`;
|
|
124634
124634
|
}
|
|
124635
124635
|
var ActionSet, ActionInvalidate, ActionPackageInstalled, EventTypesRegistry, EventBeginInstallTypes, EventEndInstallTypes, EventInitializationFailed, Arguments;
|
|
@@ -132757,12 +132757,9 @@ ${lanes.join("\n")}
|
|
|
132757
132757
|
Debug.assertEqual(action.type, "install package");
|
|
132758
132758
|
return host.installPackage ? host.installPackage({ fileName: getPath(action.file), packageName: action.packageName }) : Promise.reject("Host does not implement `installPackage`");
|
|
132759
132759
|
}
|
|
132760
|
-
function getDocCommentTemplateAtPosition2(fileName, position, options) {
|
|
132761
|
-
|
|
132762
|
-
|
|
132763
|
-
/*formatSettings*/
|
|
132764
|
-
void 0
|
|
132765
|
-
), syntaxTreeCache.getCurrentSourceFile(fileName), position, options);
|
|
132760
|
+
function getDocCommentTemplateAtPosition2(fileName, position, options, formatOptions) {
|
|
132761
|
+
const formatSettings = formatOptions ? ts_formatting_exports.getFormatContext(formatOptions, host).options : void 0;
|
|
132762
|
+
return ts_JsDoc_exports.getDocCommentTemplateAtPosition(getNewLineOrDefaultFromHost(host, formatSettings), syntaxTreeCache.getCurrentSourceFile(fileName), position, options);
|
|
132766
132763
|
}
|
|
132767
132764
|
function isValidBraceCompletionAtPosition(fileName, position, openingBrace) {
|
|
132768
132765
|
if (openingBrace === 60 /* lessThan */) {
|
|
@@ -134634,10 +134631,10 @@ ${lanes.join("\n")}
|
|
|
134634
134631
|
}
|
|
134635
134632
|
);
|
|
134636
134633
|
}
|
|
134637
|
-
getDocCommentTemplateAtPosition(fileName, position, options) {
|
|
134634
|
+
getDocCommentTemplateAtPosition(fileName, position, options, formatOptions) {
|
|
134638
134635
|
return this.forwardJSONCall(
|
|
134639
134636
|
`getDocCommentTemplateAtPosition('${fileName}', ${position})`,
|
|
134640
|
-
() => this.languageService.getDocCommentTemplateAtPosition(fileName, position, options)
|
|
134637
|
+
() => this.languageService.getDocCommentTemplateAtPosition(fileName, position, options, formatOptions)
|
|
134641
134638
|
);
|
|
134642
134639
|
}
|
|
134643
134640
|
/// NAVIGATE TO
|
|
@@ -154429,6 +154426,8 @@ ${lanes.join("\n")}
|
|
|
154429
154426
|
"lends",
|
|
154430
154427
|
"license",
|
|
154431
154428
|
"link",
|
|
154429
|
+
"linkcode",
|
|
154430
|
+
"linkplain",
|
|
154432
154431
|
"listens",
|
|
154433
154432
|
"member",
|
|
154434
154433
|
"memberof",
|
|
@@ -154441,6 +154440,7 @@ ${lanes.join("\n")}
|
|
|
154441
154440
|
"package",
|
|
154442
154441
|
"param",
|
|
154443
154442
|
"private",
|
|
154443
|
+
"prop",
|
|
154444
154444
|
"property",
|
|
154445
154445
|
"protected",
|
|
154446
154446
|
"public",
|
package/lib/typingsInstaller.js
CHANGED
|
@@ -54,7 +54,7 @@ var path = __toESM(require("path"));
|
|
|
54
54
|
|
|
55
55
|
// src/compiler/corePublic.ts
|
|
56
56
|
var versionMajorMinor = "5.0";
|
|
57
|
-
var version = `${versionMajorMinor}.0-dev.
|
|
57
|
+
var version = `${versionMajorMinor}.0-dev.20230125`;
|
|
58
58
|
|
|
59
59
|
// src/compiler/core.ts
|
|
60
60
|
var emptyArray = [];
|
|
@@ -2260,7 +2260,7 @@ function tryGetNodePerformanceHooks() {
|
|
|
2260
2260
|
}
|
|
2261
2261
|
var nativePerformanceHooks = tryGetWebPerformanceHooks() || tryGetNodePerformanceHooks();
|
|
2262
2262
|
var nativePerformance = nativePerformanceHooks == null ? void 0 : nativePerformanceHooks.performance;
|
|
2263
|
-
var timestamp = nativePerformance ? () => nativePerformance.now() : Date.now ? Date.now : () =>
|
|
2263
|
+
var timestamp = nativePerformance ? () => nativePerformance.now() : Date.now ? Date.now : () => +/* @__PURE__ */ new Date();
|
|
2264
2264
|
|
|
2265
2265
|
// src/compiler/perfLogger.ts
|
|
2266
2266
|
var nullLogger = {
|
|
@@ -3468,7 +3468,7 @@ var PollingInterval = /* @__PURE__ */ ((PollingInterval3) => {
|
|
|
3468
3468
|
PollingInterval3[PollingInterval3["Low"] = 250] = "Low";
|
|
3469
3469
|
return PollingInterval3;
|
|
3470
3470
|
})(PollingInterval || {});
|
|
3471
|
-
var missingFileModifiedTime = new Date(0);
|
|
3471
|
+
var missingFileModifiedTime = /* @__PURE__ */ new Date(0);
|
|
3472
3472
|
function getModifiedTime(host, fileName) {
|
|
3473
3473
|
return host.getModifiedTime(fileName) || missingFileModifiedTime;
|
|
3474
3474
|
}
|
|
@@ -4563,7 +4563,7 @@ var sys = (() => {
|
|
|
4563
4563
|
if (!err) {
|
|
4564
4564
|
try {
|
|
4565
4565
|
if ((_a2 = statSync(profilePath)) == null ? void 0 : _a2.isDirectory()) {
|
|
4566
|
-
profilePath = _path.join(profilePath, `${new Date().toISOString().replace(/:/g, "-")}+P${process.pid}.cpuprofile`);
|
|
4566
|
+
profilePath = _path.join(profilePath, `${(/* @__PURE__ */ new Date()).toISOString().replace(/:/g, "-")}+P${process.pid}.cpuprofile`);
|
|
4567
4567
|
}
|
|
4568
4568
|
} catch (e) {
|
|
4569
4569
|
}
|
|
@@ -34808,10 +34808,6 @@ var screenStartingMessageCodes = [
|
|
|
34808
34808
|
var noopFileWatcher = { close: noop };
|
|
34809
34809
|
var returnNoopFileWatcher = () => noopFileWatcher;
|
|
34810
34810
|
|
|
34811
|
-
// src/compiler/tsbuildPublic.ts
|
|
34812
|
-
var minimumDate = new Date(-864e13);
|
|
34813
|
-
var maximumDate = new Date(864e13);
|
|
34814
|
-
|
|
34815
34811
|
// src/jsTyping/_namespaces/ts.JsTyping.ts
|
|
34816
34812
|
var ts_JsTyping_exports = {};
|
|
34817
34813
|
__export(ts_JsTyping_exports, {
|
|
@@ -35158,7 +35154,7 @@ function findArgument(argumentName) {
|
|
|
35158
35154
|
return index >= 0 && index < sys.args.length - 1 ? sys.args[index + 1] : void 0;
|
|
35159
35155
|
}
|
|
35160
35156
|
function nowString() {
|
|
35161
|
-
const d = new Date();
|
|
35157
|
+
const d = /* @__PURE__ */ new Date();
|
|
35162
35158
|
return `${padLeft(d.getHours().toString(), 2, "0")}:${padLeft(d.getMinutes().toString(), 2, "0")}:${padLeft(d.getSeconds().toString(), 2, "0")}.${padLeft(d.getMilliseconds().toString(), 3, "0")}`;
|
|
35163
35159
|
}
|
|
35164
35160
|
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "typescript",
|
|
3
3
|
"author": "Microsoft Corp.",
|
|
4
4
|
"homepage": "https://www.typescriptlang.org/",
|
|
5
|
-
"version": "5.0.0-dev.
|
|
5
|
+
"version": "5.0.0-dev.20230125",
|
|
6
6
|
"license": "Apache-2.0",
|
|
7
7
|
"description": "TypeScript is a language for application scale JavaScript development",
|
|
8
8
|
"keywords": [
|