@typescript-deploys/pr-build 5.0.0-pr-52899-2 → 5.0.0-pr-52947-7
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 +12 -4
- package/lib/tsserver.js +13 -34
- package/lib/tsserverlibrary.js +13 -34
- package/lib/typescript.js +13 -34
- package/lib/typingsInstaller.js +3 -3
- 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-insiders.
|
|
26
|
+
var version = `${versionMajorMinor}.0-insiders.20230224`;
|
|
27
27
|
|
|
28
28
|
// src/compiler/core.ts
|
|
29
29
|
var emptyArray = [];
|
|
@@ -3783,6 +3783,7 @@ var TypeFlags = /* @__PURE__ */ ((TypeFlags2) => {
|
|
|
3783
3783
|
TypeFlags2[TypeFlags2["IncludesEmptyObject"] = 16777216 /* Conditional */] = "IncludesEmptyObject";
|
|
3784
3784
|
TypeFlags2[TypeFlags2["IncludesInstantiable"] = 33554432 /* Substitution */] = "IncludesInstantiable";
|
|
3785
3785
|
TypeFlags2[TypeFlags2["NotPrimitiveUnion"] = 36323363] = "NotPrimitiveUnion";
|
|
3786
|
+
TypeFlags2[TypeFlags2["HasWrapper"] = 402668540] = "HasWrapper";
|
|
3786
3787
|
return TypeFlags2;
|
|
3787
3788
|
})(TypeFlags || {});
|
|
3788
3789
|
var ObjectFlags = /* @__PURE__ */ ((ObjectFlags3) => {
|
|
@@ -7825,8 +7826,7 @@ var Diagnostics = {
|
|
|
7825
7826
|
_0_is_possibly_undefined: diag(18048, 1 /* Error */, "_0_is_possibly_undefined_18048", "'{0}' is possibly 'undefined'."),
|
|
7826
7827
|
_0_is_possibly_null_or_undefined: diag(18049, 1 /* Error */, "_0_is_possibly_null_or_undefined_18049", "'{0}' is possibly 'null' or 'undefined'."),
|
|
7827
7828
|
The_value_0_cannot_be_used_here: diag(18050, 1 /* Error */, "The_value_0_cannot_be_used_here_18050", "The value '{0}' cannot be used here."),
|
|
7828
|
-
Compiler_option_0_cannot_be_given_an_empty_string: diag(18051, 1 /* Error */, "Compiler_option_0_cannot_be_given_an_empty_string_18051", "Compiler option '{0}' cannot be given an empty string.")
|
|
7829
|
-
Add_missing_comma_for_an_object_member_completion_0: diag(18052, 3 /* Message */, "Add_missing_comma_for_an_object_member_completion_0_18052", "Add missing comma for an object member completion '{0}'.")
|
|
7829
|
+
Compiler_option_0_cannot_be_given_an_empty_string: diag(18051, 1 /* Error */, "Compiler_option_0_cannot_be_given_an_empty_string_18051", "Compiler option '{0}' cannot be given an empty string.")
|
|
7830
7830
|
};
|
|
7831
7831
|
|
|
7832
7832
|
// src/compiler/scanner.ts
|
|
@@ -59307,7 +59307,7 @@ function createTypeChecker(host) {
|
|
|
59307
59307
|
function tryElaborateErrorsForPrimitivesAndObjects(source2, target2) {
|
|
59308
59308
|
const sourceType = symbolValueDeclarationIsContextSensitive(source2.symbol) ? typeToString(source2, source2.symbol.valueDeclaration) : typeToString(source2);
|
|
59309
59309
|
const targetType = symbolValueDeclarationIsContextSensitive(target2.symbol) ? typeToString(target2, target2.symbol.valueDeclaration) : typeToString(target2);
|
|
59310
|
-
if (globalStringType === source2 && stringType === target2 || globalNumberType === source2 && numberType === target2 || globalBooleanType === source2 && booleanType === target2 || getGlobalESSymbolType() === source2 && esSymbolType === target2) {
|
|
59310
|
+
if (globalStringType === source2 && stringType === target2 || globalNumberType === source2 && numberType === target2 || globalBooleanType === source2 && booleanType === target2 || getGlobalESSymbolType() === source2 && esSymbolType === target2 || getGlobalBigIntType() === source2 && bigintType === target2) {
|
|
59311
59311
|
reportError(Diagnostics._0_is_a_primitive_but_1_is_a_wrapper_object_Prefer_using_0_when_possible, targetType, sourceType);
|
|
59312
59312
|
}
|
|
59313
59313
|
}
|
|
@@ -59464,6 +59464,9 @@ function createTypeChecker(host) {
|
|
|
59464
59464
|
}
|
|
59465
59465
|
if (source2.flags & 524288 /* Object */ && target2.flags & 134348796 /* Primitive */) {
|
|
59466
59466
|
tryElaborateErrorsForPrimitivesAndObjects(source2, target2);
|
|
59467
|
+
}
|
|
59468
|
+
if (target2.flags & 524288 /* Object */ && source2.flags & 134348796 /* Primitive */) {
|
|
59469
|
+
tryElaborateErrorsForPrimitivesAndObjects(target2, source2);
|
|
59467
59470
|
} else if (source2.symbol && source2.flags & 524288 /* Object */ && globalObjectType === source2) {
|
|
59468
59471
|
reportError(Diagnostics.The_Object_type_is_assignable_to_very_few_other_types_Did_you_mean_to_use_the_any_type_instead);
|
|
59469
59472
|
} else if (getObjectFlags(source2) & 2048 /* JsxAttributes */ && target2.flags & 2097152 /* Intersection */) {
|
|
@@ -60511,8 +60514,13 @@ function createTypeChecker(host) {
|
|
|
60511
60514
|
}
|
|
60512
60515
|
const sourceIsPrimitive = !!(sourceFlags & 134348796 /* Primitive */);
|
|
60513
60516
|
if (relation !== identityRelation) {
|
|
60517
|
+
const originalSource = source2;
|
|
60518
|
+
const originalFlags = sourceFlags;
|
|
60514
60519
|
source2 = getApparentType(source2);
|
|
60515
60520
|
sourceFlags = source2.flags;
|
|
60521
|
+
if (source2 !== originalSource && originalFlags & 402668540 /* HasWrapper */ && !(sourceFlags & 402668540 /* HasWrapper */) && source2 === target2) {
|
|
60522
|
+
return 0 /* False */;
|
|
60523
|
+
}
|
|
60516
60524
|
} else if (isGenericMappedType(source2)) {
|
|
60517
60525
|
return 0 /* False */;
|
|
60518
60526
|
}
|
package/lib/tsserver.js
CHANGED
|
@@ -2288,7 +2288,7 @@ module.exports = __toCommonJS(server_exports);
|
|
|
2288
2288
|
|
|
2289
2289
|
// src/compiler/corePublic.ts
|
|
2290
2290
|
var versionMajorMinor = "5.0";
|
|
2291
|
-
var version = `${versionMajorMinor}.0-insiders.
|
|
2291
|
+
var version = `${versionMajorMinor}.0-insiders.20230224`;
|
|
2292
2292
|
var Comparison = /* @__PURE__ */ ((Comparison3) => {
|
|
2293
2293
|
Comparison3[Comparison3["LessThan"] = -1] = "LessThan";
|
|
2294
2294
|
Comparison3[Comparison3["EqualTo"] = 0] = "EqualTo";
|
|
@@ -6707,6 +6707,7 @@ var TypeFlags = /* @__PURE__ */ ((TypeFlags2) => {
|
|
|
6707
6707
|
TypeFlags2[TypeFlags2["IncludesEmptyObject"] = 16777216 /* Conditional */] = "IncludesEmptyObject";
|
|
6708
6708
|
TypeFlags2[TypeFlags2["IncludesInstantiable"] = 33554432 /* Substitution */] = "IncludesInstantiable";
|
|
6709
6709
|
TypeFlags2[TypeFlags2["NotPrimitiveUnion"] = 36323363] = "NotPrimitiveUnion";
|
|
6710
|
+
TypeFlags2[TypeFlags2["HasWrapper"] = 402668540] = "HasWrapper";
|
|
6710
6711
|
return TypeFlags2;
|
|
6711
6712
|
})(TypeFlags || {});
|
|
6712
6713
|
var ObjectFlags = /* @__PURE__ */ ((ObjectFlags3) => {
|
|
@@ -11289,8 +11290,7 @@ var Diagnostics = {
|
|
|
11289
11290
|
_0_is_possibly_undefined: diag(18048, 1 /* Error */, "_0_is_possibly_undefined_18048", "'{0}' is possibly 'undefined'."),
|
|
11290
11291
|
_0_is_possibly_null_or_undefined: diag(18049, 1 /* Error */, "_0_is_possibly_null_or_undefined_18049", "'{0}' is possibly 'null' or 'undefined'."),
|
|
11291
11292
|
The_value_0_cannot_be_used_here: diag(18050, 1 /* Error */, "The_value_0_cannot_be_used_here_18050", "The value '{0}' cannot be used here."),
|
|
11292
|
-
Compiler_option_0_cannot_be_given_an_empty_string: diag(18051, 1 /* Error */, "Compiler_option_0_cannot_be_given_an_empty_string_18051", "Compiler option '{0}' cannot be given an empty string.")
|
|
11293
|
-
Add_missing_comma_for_an_object_member_completion_0: diag(18052, 3 /* Message */, "Add_missing_comma_for_an_object_member_completion_0_18052", "Add missing comma for an object member completion '{0}'.")
|
|
11293
|
+
Compiler_option_0_cannot_be_given_an_empty_string: diag(18051, 1 /* Error */, "Compiler_option_0_cannot_be_given_an_empty_string_18051", "Compiler option '{0}' cannot be given an empty string.")
|
|
11294
11294
|
};
|
|
11295
11295
|
|
|
11296
11296
|
// src/compiler/scanner.ts
|
|
@@ -63914,7 +63914,7 @@ function createTypeChecker(host) {
|
|
|
63914
63914
|
function tryElaborateErrorsForPrimitivesAndObjects(source2, target2) {
|
|
63915
63915
|
const sourceType = symbolValueDeclarationIsContextSensitive(source2.symbol) ? typeToString(source2, source2.symbol.valueDeclaration) : typeToString(source2);
|
|
63916
63916
|
const targetType = symbolValueDeclarationIsContextSensitive(target2.symbol) ? typeToString(target2, target2.symbol.valueDeclaration) : typeToString(target2);
|
|
63917
|
-
if (globalStringType === source2 && stringType === target2 || globalNumberType === source2 && numberType === target2 || globalBooleanType === source2 && booleanType === target2 || getGlobalESSymbolType() === source2 && esSymbolType === target2) {
|
|
63917
|
+
if (globalStringType === source2 && stringType === target2 || globalNumberType === source2 && numberType === target2 || globalBooleanType === source2 && booleanType === target2 || getGlobalESSymbolType() === source2 && esSymbolType === target2 || getGlobalBigIntType() === source2 && bigintType === target2) {
|
|
63918
63918
|
reportError(Diagnostics._0_is_a_primitive_but_1_is_a_wrapper_object_Prefer_using_0_when_possible, targetType, sourceType);
|
|
63919
63919
|
}
|
|
63920
63920
|
}
|
|
@@ -64071,6 +64071,9 @@ function createTypeChecker(host) {
|
|
|
64071
64071
|
}
|
|
64072
64072
|
if (source2.flags & 524288 /* Object */ && target2.flags & 134348796 /* Primitive */) {
|
|
64073
64073
|
tryElaborateErrorsForPrimitivesAndObjects(source2, target2);
|
|
64074
|
+
}
|
|
64075
|
+
if (target2.flags & 524288 /* Object */ && source2.flags & 134348796 /* Primitive */) {
|
|
64076
|
+
tryElaborateErrorsForPrimitivesAndObjects(target2, source2);
|
|
64074
64077
|
} else if (source2.symbol && source2.flags & 524288 /* Object */ && globalObjectType === source2) {
|
|
64075
64078
|
reportError(Diagnostics.The_Object_type_is_assignable_to_very_few_other_types_Did_you_mean_to_use_the_any_type_instead);
|
|
64076
64079
|
} else if (getObjectFlags(source2) & 2048 /* JsxAttributes */ && target2.flags & 2097152 /* Intersection */) {
|
|
@@ -65118,8 +65121,13 @@ function createTypeChecker(host) {
|
|
|
65118
65121
|
}
|
|
65119
65122
|
const sourceIsPrimitive = !!(sourceFlags & 134348796 /* Primitive */);
|
|
65120
65123
|
if (relation !== identityRelation) {
|
|
65124
|
+
const originalSource = source2;
|
|
65125
|
+
const originalFlags = sourceFlags;
|
|
65121
65126
|
source2 = getApparentType(source2);
|
|
65122
65127
|
sourceFlags = source2.flags;
|
|
65128
|
+
if (source2 !== originalSource && originalFlags & 402668540 /* HasWrapper */ && !(sourceFlags & 402668540 /* HasWrapper */) && source2 === target2) {
|
|
65129
|
+
return 0 /* False */;
|
|
65130
|
+
}
|
|
65123
65131
|
} else if (isGenericMappedType(source2)) {
|
|
65124
65132
|
return 0 /* False */;
|
|
65125
65133
|
}
|
|
@@ -148295,7 +148303,6 @@ var CompletionSource = /* @__PURE__ */ ((CompletionSource2) => {
|
|
|
148295
148303
|
CompletionSource2["TypeOnlyAlias"] = "TypeOnlyAlias/";
|
|
148296
148304
|
CompletionSource2["ObjectLiteralMethodSnippet"] = "ObjectLiteralMethodSnippet/";
|
|
148297
148305
|
CompletionSource2["SwitchCases"] = "SwitchCases/";
|
|
148298
|
-
CompletionSource2["ObjectLiteralExpression"] = "ObjectLiteralExpression/";
|
|
148299
148306
|
return CompletionSource2;
|
|
148300
148307
|
})(CompletionSource || {});
|
|
148301
148308
|
var SymbolOriginInfoKind = /* @__PURE__ */ ((SymbolOriginInfoKind2) => {
|
|
@@ -148893,7 +148900,6 @@ function createCompletionEntryForLiteral(sourceFile, preferences, literal) {
|
|
|
148893
148900
|
return { name: completionNameForLiteral(sourceFile, preferences, literal), kind: "string" /* string */, kindModifiers: "" /* none */, sortText: SortText.LocationPriority };
|
|
148894
148901
|
}
|
|
148895
148902
|
function createCompletionEntry(symbol, sortText, replacementToken, contextToken, location, position, sourceFile, host, program, name, needsConvertPropertyAccess, origin, recommendedCompletion, propertyAccessToConvert, isJsxInitializer, importStatementCompletion, useSemicolons, options, preferences, completionKind, formatContext, isJsxIdentifierExpected, isRightOfOpenTag, includeSymbol) {
|
|
148896
|
-
var _a2;
|
|
148897
148903
|
let insertText;
|
|
148898
148904
|
let replacementSpan = getReplacementSpanForContextToken(replacementToken);
|
|
148899
148905
|
let data;
|
|
@@ -148951,10 +148957,6 @@ function createCompletionEntry(symbol, sortText, replacementToken, contextToken,
|
|
|
148951
148957
|
if ((origin == null ? void 0 : origin.kind) === 64 /* TypeOnlyAlias */) {
|
|
148952
148958
|
hasAction = true;
|
|
148953
148959
|
}
|
|
148954
|
-
if (contextToken && isPropertyAssignment(contextToken.parent) && ((_a2 = findNextToken(contextToken, contextToken == null ? void 0 : contextToken.parent, sourceFile)) == null ? void 0 : _a2.kind) !== 27 /* CommaToken */ && completionKind === 0 /* ObjectPropertyDeclaration */) {
|
|
148955
|
-
source = "ObjectLiteralExpression/" /* ObjectLiteralExpression */;
|
|
148956
|
-
hasAction = true;
|
|
148957
|
-
}
|
|
148958
148960
|
if (preferences.includeCompletionsWithClassMemberSnippets && preferences.includeCompletionsWithInsertText && completionKind === 3 /* MemberLike */ && isClassLikeMemberCompletion(symbol, location, sourceFile)) {
|
|
148959
148961
|
let importAdder;
|
|
148960
148962
|
({ insertText, isSnippet, importAdder, replacementSpan } = getEntryForMemberCompletion(host, program, options, preferences, name, symbol, location, position, contextToken, formatContext));
|
|
@@ -149643,7 +149645,7 @@ function getSymbolCompletionFromEntryId(program, log, sourceFile, position, entr
|
|
|
149643
149645
|
return firstDefined(symbols, (symbol, index) => {
|
|
149644
149646
|
const origin = symbolToOriginInfoMap[index];
|
|
149645
149647
|
const info = getCompletionEntryDisplayNameForSymbol(symbol, getEmitScriptTarget(compilerOptions), origin, completionKind, completionData.isJsxIdentifierExpected);
|
|
149646
|
-
return info && info.name === entryId.name && (entryId.source === "ClassMemberSnippet/" /* ClassMemberSnippet */ && symbol.flags & 106500 /* ClassMember */ || entryId.source === "ObjectLiteralMethodSnippet/" /* ObjectLiteralMethodSnippet */ && symbol.flags & (4 /* Property */ | 8192 /* Method */) || getSourceFromOrigin(origin) === entryId.source
|
|
149648
|
+
return info && info.name === entryId.name && (entryId.source === "ClassMemberSnippet/" /* ClassMemberSnippet */ && symbol.flags & 106500 /* ClassMember */ || entryId.source === "ObjectLiteralMethodSnippet/" /* ObjectLiteralMethodSnippet */ && symbol.flags & (4 /* Property */ | 8192 /* Method */) || getSourceFromOrigin(origin) === entryId.source) ? { type: "symbol", symbol, location, origin, contextToken, previousToken, isJsxInitializer, isTypeOnlyLocation } : void 0;
|
|
149647
149649
|
}) || { type: "none" };
|
|
149648
149650
|
}
|
|
149649
149651
|
function getCompletionEntryDetails(program, log, sourceFile, position, entryId, host, formatContext, preferences, cancellationToken) {
|
|
@@ -149781,21 +149783,6 @@ function getCompletionEntryCodeActionsAndSourceDisplay(name, location, contextTo
|
|
|
149781
149783
|
Debug.assertIsDefined(codeAction2, "Expected to have a code action for promoting type-only alias");
|
|
149782
149784
|
return { codeActions: [codeAction2], sourceDisplay: void 0 };
|
|
149783
149785
|
}
|
|
149784
|
-
if (source === "ObjectLiteralExpression/" /* ObjectLiteralExpression */ && contextToken) {
|
|
149785
|
-
const changes = ts_textChanges_exports.ChangeTracker.with(
|
|
149786
|
-
{ host, formatContext, preferences },
|
|
149787
|
-
(tracker) => tracker.insertText(sourceFile, contextToken.end, ",")
|
|
149788
|
-
);
|
|
149789
|
-
if (changes) {
|
|
149790
|
-
return {
|
|
149791
|
-
sourceDisplay: void 0,
|
|
149792
|
-
codeActions: [{
|
|
149793
|
-
changes,
|
|
149794
|
-
description: diagnosticToString([Diagnostics.Add_missing_comma_for_an_object_member_completion_0, name])
|
|
149795
|
-
}]
|
|
149796
|
-
};
|
|
149797
|
-
}
|
|
149798
|
-
}
|
|
149799
149786
|
if (!origin || !(originIsExport(origin) || originIsResolvedExport(origin))) {
|
|
149800
149787
|
return { codeActions: void 0, sourceDisplay: void 0 };
|
|
149801
149788
|
}
|
|
@@ -151203,10 +151190,6 @@ function tryGetObjectLikeCompletionContainer(contextToken) {
|
|
|
151203
151190
|
return isMethodDeclaration(parent2) ? tryCast(parent2.parent, isObjectLiteralExpression) : void 0;
|
|
151204
151191
|
case 79 /* Identifier */:
|
|
151205
151192
|
return contextToken.text === "async" && isShorthandPropertyAssignment(contextToken.parent) ? contextToken.parent.parent : void 0;
|
|
151206
|
-
default:
|
|
151207
|
-
if (parent2.parent && isObjectLiteralExpression(parent2.parent) && contextToken.kind !== 58 /* ColonToken */) {
|
|
151208
|
-
return parent2.parent;
|
|
151209
|
-
}
|
|
151210
151193
|
}
|
|
151211
151194
|
}
|
|
151212
151195
|
return void 0;
|
|
@@ -163900,10 +163883,6 @@ var ChangeTracker = class {
|
|
|
163900
163883
|
const suffix = this.nextCommaToken(sourceFile, oldNode) ? "" : "," + this.newLineCharacter;
|
|
163901
163884
|
this.replaceNode(sourceFile, oldNode, newNode, { suffix });
|
|
163902
163885
|
}
|
|
163903
|
-
replacePropertyAssignmentOnSameLine(sourceFile, oldNode, newNode) {
|
|
163904
|
-
const suffix = this.nextCommaToken(sourceFile, oldNode) ? "" : ",";
|
|
163905
|
-
this.replaceNode(sourceFile, oldNode, newNode, { suffix });
|
|
163906
|
-
}
|
|
163907
163886
|
insertNodeAt(sourceFile, pos, newNode, options = {}) {
|
|
163908
163887
|
this.replaceRange(sourceFile, createRange(pos), newNode, options);
|
|
163909
163888
|
}
|
package/lib/tsserverlibrary.js
CHANGED
|
@@ -35,7 +35,7 @@ var ts = (() => {
|
|
|
35
35
|
"src/compiler/corePublic.ts"() {
|
|
36
36
|
"use strict";
|
|
37
37
|
versionMajorMinor = "5.0";
|
|
38
|
-
version = `${versionMajorMinor}.0-insiders.
|
|
38
|
+
version = `${versionMajorMinor}.0-insiders.20230224`;
|
|
39
39
|
Comparison = /* @__PURE__ */ ((Comparison3) => {
|
|
40
40
|
Comparison3[Comparison3["LessThan"] = -1] = "LessThan";
|
|
41
41
|
Comparison3[Comparison3["EqualTo"] = 0] = "EqualTo";
|
|
@@ -4512,6 +4512,7 @@ ${lanes.join("\n")}
|
|
|
4512
4512
|
TypeFlags2[TypeFlags2["IncludesEmptyObject"] = 16777216 /* Conditional */] = "IncludesEmptyObject";
|
|
4513
4513
|
TypeFlags2[TypeFlags2["IncludesInstantiable"] = 33554432 /* Substitution */] = "IncludesInstantiable";
|
|
4514
4514
|
TypeFlags2[TypeFlags2["NotPrimitiveUnion"] = 36323363] = "NotPrimitiveUnion";
|
|
4515
|
+
TypeFlags2[TypeFlags2["HasWrapper"] = 402668540] = "HasWrapper";
|
|
4515
4516
|
return TypeFlags2;
|
|
4516
4517
|
})(TypeFlags || {});
|
|
4517
4518
|
ObjectFlags = /* @__PURE__ */ ((ObjectFlags3) => {
|
|
@@ -9111,8 +9112,7 @@ ${lanes.join("\n")}
|
|
|
9111
9112
|
_0_is_possibly_undefined: diag(18048, 1 /* Error */, "_0_is_possibly_undefined_18048", "'{0}' is possibly 'undefined'."),
|
|
9112
9113
|
_0_is_possibly_null_or_undefined: diag(18049, 1 /* Error */, "_0_is_possibly_null_or_undefined_18049", "'{0}' is possibly 'null' or 'undefined'."),
|
|
9113
9114
|
The_value_0_cannot_be_used_here: diag(18050, 1 /* Error */, "The_value_0_cannot_be_used_here_18050", "The value '{0}' cannot be used here."),
|
|
9114
|
-
Compiler_option_0_cannot_be_given_an_empty_string: diag(18051, 1 /* Error */, "Compiler_option_0_cannot_be_given_an_empty_string_18051", "Compiler option '{0}' cannot be given an empty string.")
|
|
9115
|
-
Add_missing_comma_for_an_object_member_completion_0: diag(18052, 3 /* Message */, "Add_missing_comma_for_an_object_member_completion_0_18052", "Add missing comma for an object member completion '{0}'.")
|
|
9115
|
+
Compiler_option_0_cannot_be_given_an_empty_string: diag(18051, 1 /* Error */, "Compiler_option_0_cannot_be_given_an_empty_string_18051", "Compiler option '{0}' cannot be given an empty string.")
|
|
9116
9116
|
};
|
|
9117
9117
|
}
|
|
9118
9118
|
});
|
|
@@ -61722,7 +61722,7 @@ ${lanes.join("\n")}
|
|
|
61722
61722
|
function tryElaborateErrorsForPrimitivesAndObjects(source2, target2) {
|
|
61723
61723
|
const sourceType = symbolValueDeclarationIsContextSensitive(source2.symbol) ? typeToString(source2, source2.symbol.valueDeclaration) : typeToString(source2);
|
|
61724
61724
|
const targetType = symbolValueDeclarationIsContextSensitive(target2.symbol) ? typeToString(target2, target2.symbol.valueDeclaration) : typeToString(target2);
|
|
61725
|
-
if (globalStringType === source2 && stringType === target2 || globalNumberType === source2 && numberType === target2 || globalBooleanType === source2 && booleanType === target2 || getGlobalESSymbolType() === source2 && esSymbolType === target2) {
|
|
61725
|
+
if (globalStringType === source2 && stringType === target2 || globalNumberType === source2 && numberType === target2 || globalBooleanType === source2 && booleanType === target2 || getGlobalESSymbolType() === source2 && esSymbolType === target2 || getGlobalBigIntType() === source2 && bigintType === target2) {
|
|
61726
61726
|
reportError(Diagnostics._0_is_a_primitive_but_1_is_a_wrapper_object_Prefer_using_0_when_possible, targetType, sourceType);
|
|
61727
61727
|
}
|
|
61728
61728
|
}
|
|
@@ -61879,6 +61879,9 @@ ${lanes.join("\n")}
|
|
|
61879
61879
|
}
|
|
61880
61880
|
if (source2.flags & 524288 /* Object */ && target2.flags & 134348796 /* Primitive */) {
|
|
61881
61881
|
tryElaborateErrorsForPrimitivesAndObjects(source2, target2);
|
|
61882
|
+
}
|
|
61883
|
+
if (target2.flags & 524288 /* Object */ && source2.flags & 134348796 /* Primitive */) {
|
|
61884
|
+
tryElaborateErrorsForPrimitivesAndObjects(target2, source2);
|
|
61882
61885
|
} else if (source2.symbol && source2.flags & 524288 /* Object */ && globalObjectType === source2) {
|
|
61883
61886
|
reportError(Diagnostics.The_Object_type_is_assignable_to_very_few_other_types_Did_you_mean_to_use_the_any_type_instead);
|
|
61884
61887
|
} else if (getObjectFlags(source2) & 2048 /* JsxAttributes */ && target2.flags & 2097152 /* Intersection */) {
|
|
@@ -62926,8 +62929,13 @@ ${lanes.join("\n")}
|
|
|
62926
62929
|
}
|
|
62927
62930
|
const sourceIsPrimitive = !!(sourceFlags & 134348796 /* Primitive */);
|
|
62928
62931
|
if (relation !== identityRelation) {
|
|
62932
|
+
const originalSource = source2;
|
|
62933
|
+
const originalFlags = sourceFlags;
|
|
62929
62934
|
source2 = getApparentType(source2);
|
|
62930
62935
|
sourceFlags = source2.flags;
|
|
62936
|
+
if (source2 !== originalSource && originalFlags & 402668540 /* HasWrapper */ && !(sourceFlags & 402668540 /* HasWrapper */) && source2 === target2) {
|
|
62937
|
+
return 0 /* False */;
|
|
62938
|
+
}
|
|
62931
62939
|
} else if (isGenericMappedType(source2)) {
|
|
62932
62940
|
return 0 /* False */;
|
|
62933
62941
|
}
|
|
@@ -147944,7 +147952,6 @@ ${lanes.join("\n")}
|
|
|
147944
147952
|
return { name: completionNameForLiteral(sourceFile, preferences, literal), kind: "string" /* string */, kindModifiers: "" /* none */, sortText: SortText.LocationPriority };
|
|
147945
147953
|
}
|
|
147946
147954
|
function createCompletionEntry(symbol, sortText, replacementToken, contextToken, location, position, sourceFile, host, program, name, needsConvertPropertyAccess, origin, recommendedCompletion, propertyAccessToConvert, isJsxInitializer, importStatementCompletion, useSemicolons, options, preferences, completionKind, formatContext, isJsxIdentifierExpected, isRightOfOpenTag, includeSymbol) {
|
|
147947
|
-
var _a2;
|
|
147948
147955
|
let insertText;
|
|
147949
147956
|
let replacementSpan = getReplacementSpanForContextToken(replacementToken);
|
|
147950
147957
|
let data;
|
|
@@ -148002,10 +148009,6 @@ ${lanes.join("\n")}
|
|
|
148002
148009
|
if ((origin == null ? void 0 : origin.kind) === 64 /* TypeOnlyAlias */) {
|
|
148003
148010
|
hasAction = true;
|
|
148004
148011
|
}
|
|
148005
|
-
if (contextToken && isPropertyAssignment(contextToken.parent) && ((_a2 = findNextToken(contextToken, contextToken == null ? void 0 : contextToken.parent, sourceFile)) == null ? void 0 : _a2.kind) !== 27 /* CommaToken */ && completionKind === 0 /* ObjectPropertyDeclaration */) {
|
|
148006
|
-
source = "ObjectLiteralExpression/" /* ObjectLiteralExpression */;
|
|
148007
|
-
hasAction = true;
|
|
148008
|
-
}
|
|
148009
148012
|
if (preferences.includeCompletionsWithClassMemberSnippets && preferences.includeCompletionsWithInsertText && completionKind === 3 /* MemberLike */ && isClassLikeMemberCompletion(symbol, location, sourceFile)) {
|
|
148010
148013
|
let importAdder;
|
|
148011
148014
|
({ insertText, isSnippet, importAdder, replacementSpan } = getEntryForMemberCompletion(host, program, options, preferences, name, symbol, location, position, contextToken, formatContext));
|
|
@@ -148694,7 +148697,7 @@ ${lanes.join("\n")}
|
|
|
148694
148697
|
return firstDefined(symbols, (symbol, index) => {
|
|
148695
148698
|
const origin = symbolToOriginInfoMap[index];
|
|
148696
148699
|
const info = getCompletionEntryDisplayNameForSymbol(symbol, getEmitScriptTarget(compilerOptions), origin, completionKind, completionData.isJsxIdentifierExpected);
|
|
148697
|
-
return info && info.name === entryId.name && (entryId.source === "ClassMemberSnippet/" /* ClassMemberSnippet */ && symbol.flags & 106500 /* ClassMember */ || entryId.source === "ObjectLiteralMethodSnippet/" /* ObjectLiteralMethodSnippet */ && symbol.flags & (4 /* Property */ | 8192 /* Method */) || getSourceFromOrigin(origin) === entryId.source
|
|
148700
|
+
return info && info.name === entryId.name && (entryId.source === "ClassMemberSnippet/" /* ClassMemberSnippet */ && symbol.flags & 106500 /* ClassMember */ || entryId.source === "ObjectLiteralMethodSnippet/" /* ObjectLiteralMethodSnippet */ && symbol.flags & (4 /* Property */ | 8192 /* Method */) || getSourceFromOrigin(origin) === entryId.source) ? { type: "symbol", symbol, location, origin, contextToken, previousToken, isJsxInitializer, isTypeOnlyLocation } : void 0;
|
|
148698
148701
|
}) || { type: "none" };
|
|
148699
148702
|
}
|
|
148700
148703
|
function getCompletionEntryDetails(program, log, sourceFile, position, entryId, host, formatContext, preferences, cancellationToken) {
|
|
@@ -148832,21 +148835,6 @@ ${lanes.join("\n")}
|
|
|
148832
148835
|
Debug.assertIsDefined(codeAction2, "Expected to have a code action for promoting type-only alias");
|
|
148833
148836
|
return { codeActions: [codeAction2], sourceDisplay: void 0 };
|
|
148834
148837
|
}
|
|
148835
|
-
if (source === "ObjectLiteralExpression/" /* ObjectLiteralExpression */ && contextToken) {
|
|
148836
|
-
const changes = ts_textChanges_exports.ChangeTracker.with(
|
|
148837
|
-
{ host, formatContext, preferences },
|
|
148838
|
-
(tracker) => tracker.insertText(sourceFile, contextToken.end, ",")
|
|
148839
|
-
);
|
|
148840
|
-
if (changes) {
|
|
148841
|
-
return {
|
|
148842
|
-
sourceDisplay: void 0,
|
|
148843
|
-
codeActions: [{
|
|
148844
|
-
changes,
|
|
148845
|
-
description: diagnosticToString([Diagnostics.Add_missing_comma_for_an_object_member_completion_0, name])
|
|
148846
|
-
}]
|
|
148847
|
-
};
|
|
148848
|
-
}
|
|
148849
|
-
}
|
|
148850
148838
|
if (!origin || !(originIsExport(origin) || originIsResolvedExport(origin))) {
|
|
148851
148839
|
return { codeActions: void 0, sourceDisplay: void 0 };
|
|
148852
148840
|
}
|
|
@@ -150245,10 +150233,6 @@ ${lanes.join("\n")}
|
|
|
150245
150233
|
return isMethodDeclaration(parent2) ? tryCast(parent2.parent, isObjectLiteralExpression) : void 0;
|
|
150246
150234
|
case 79 /* Identifier */:
|
|
150247
150235
|
return contextToken.text === "async" && isShorthandPropertyAssignment(contextToken.parent) ? contextToken.parent.parent : void 0;
|
|
150248
|
-
default:
|
|
150249
|
-
if (parent2.parent && isObjectLiteralExpression(parent2.parent) && contextToken.kind !== 58 /* ColonToken */) {
|
|
150250
|
-
return parent2.parent;
|
|
150251
|
-
}
|
|
150252
150236
|
}
|
|
150253
150237
|
}
|
|
150254
150238
|
return void 0;
|
|
@@ -150789,7 +150773,6 @@ ${lanes.join("\n")}
|
|
|
150789
150773
|
CompletionSource2["TypeOnlyAlias"] = "TypeOnlyAlias/";
|
|
150790
150774
|
CompletionSource2["ObjectLiteralMethodSnippet"] = "ObjectLiteralMethodSnippet/";
|
|
150791
150775
|
CompletionSource2["SwitchCases"] = "SwitchCases/";
|
|
150792
|
-
CompletionSource2["ObjectLiteralExpression"] = "ObjectLiteralExpression/";
|
|
150793
150776
|
return CompletionSource2;
|
|
150794
150777
|
})(CompletionSource || {});
|
|
150795
150778
|
SymbolOriginInfoKind = /* @__PURE__ */ ((SymbolOriginInfoKind2) => {
|
|
@@ -163783,10 +163766,6 @@ ${newComment.split("\n").map((c) => ` * ${c}`).join("\n")}
|
|
|
163783
163766
|
const suffix = this.nextCommaToken(sourceFile, oldNode) ? "" : "," + this.newLineCharacter;
|
|
163784
163767
|
this.replaceNode(sourceFile, oldNode, newNode, { suffix });
|
|
163785
163768
|
}
|
|
163786
|
-
replacePropertyAssignmentOnSameLine(sourceFile, oldNode, newNode) {
|
|
163787
|
-
const suffix = this.nextCommaToken(sourceFile, oldNode) ? "" : ",";
|
|
163788
|
-
this.replaceNode(sourceFile, oldNode, newNode, { suffix });
|
|
163789
|
-
}
|
|
163790
163769
|
insertNodeAt(sourceFile, pos, newNode, options = {}) {
|
|
163791
163770
|
this.replaceRange(sourceFile, createRange(pos), newNode, options);
|
|
163792
163771
|
}
|
package/lib/typescript.js
CHANGED
|
@@ -35,7 +35,7 @@ var ts = (() => {
|
|
|
35
35
|
"src/compiler/corePublic.ts"() {
|
|
36
36
|
"use strict";
|
|
37
37
|
versionMajorMinor = "5.0";
|
|
38
|
-
version = `${versionMajorMinor}.0-insiders.
|
|
38
|
+
version = `${versionMajorMinor}.0-insiders.20230224`;
|
|
39
39
|
Comparison = /* @__PURE__ */ ((Comparison3) => {
|
|
40
40
|
Comparison3[Comparison3["LessThan"] = -1] = "LessThan";
|
|
41
41
|
Comparison3[Comparison3["EqualTo"] = 0] = "EqualTo";
|
|
@@ -4512,6 +4512,7 @@ ${lanes.join("\n")}
|
|
|
4512
4512
|
TypeFlags2[TypeFlags2["IncludesEmptyObject"] = 16777216 /* Conditional */] = "IncludesEmptyObject";
|
|
4513
4513
|
TypeFlags2[TypeFlags2["IncludesInstantiable"] = 33554432 /* Substitution */] = "IncludesInstantiable";
|
|
4514
4514
|
TypeFlags2[TypeFlags2["NotPrimitiveUnion"] = 36323363] = "NotPrimitiveUnion";
|
|
4515
|
+
TypeFlags2[TypeFlags2["HasWrapper"] = 402668540] = "HasWrapper";
|
|
4515
4516
|
return TypeFlags2;
|
|
4516
4517
|
})(TypeFlags || {});
|
|
4517
4518
|
ObjectFlags = /* @__PURE__ */ ((ObjectFlags3) => {
|
|
@@ -9111,8 +9112,7 @@ ${lanes.join("\n")}
|
|
|
9111
9112
|
_0_is_possibly_undefined: diag(18048, 1 /* Error */, "_0_is_possibly_undefined_18048", "'{0}' is possibly 'undefined'."),
|
|
9112
9113
|
_0_is_possibly_null_or_undefined: diag(18049, 1 /* Error */, "_0_is_possibly_null_or_undefined_18049", "'{0}' is possibly 'null' or 'undefined'."),
|
|
9113
9114
|
The_value_0_cannot_be_used_here: diag(18050, 1 /* Error */, "The_value_0_cannot_be_used_here_18050", "The value '{0}' cannot be used here."),
|
|
9114
|
-
Compiler_option_0_cannot_be_given_an_empty_string: diag(18051, 1 /* Error */, "Compiler_option_0_cannot_be_given_an_empty_string_18051", "Compiler option '{0}' cannot be given an empty string.")
|
|
9115
|
-
Add_missing_comma_for_an_object_member_completion_0: diag(18052, 3 /* Message */, "Add_missing_comma_for_an_object_member_completion_0_18052", "Add missing comma for an object member completion '{0}'.")
|
|
9115
|
+
Compiler_option_0_cannot_be_given_an_empty_string: diag(18051, 1 /* Error */, "Compiler_option_0_cannot_be_given_an_empty_string_18051", "Compiler option '{0}' cannot be given an empty string.")
|
|
9116
9116
|
};
|
|
9117
9117
|
}
|
|
9118
9118
|
});
|
|
@@ -61722,7 +61722,7 @@ ${lanes.join("\n")}
|
|
|
61722
61722
|
function tryElaborateErrorsForPrimitivesAndObjects(source2, target2) {
|
|
61723
61723
|
const sourceType = symbolValueDeclarationIsContextSensitive(source2.symbol) ? typeToString(source2, source2.symbol.valueDeclaration) : typeToString(source2);
|
|
61724
61724
|
const targetType = symbolValueDeclarationIsContextSensitive(target2.symbol) ? typeToString(target2, target2.symbol.valueDeclaration) : typeToString(target2);
|
|
61725
|
-
if (globalStringType === source2 && stringType === target2 || globalNumberType === source2 && numberType === target2 || globalBooleanType === source2 && booleanType === target2 || getGlobalESSymbolType() === source2 && esSymbolType === target2) {
|
|
61725
|
+
if (globalStringType === source2 && stringType === target2 || globalNumberType === source2 && numberType === target2 || globalBooleanType === source2 && booleanType === target2 || getGlobalESSymbolType() === source2 && esSymbolType === target2 || getGlobalBigIntType() === source2 && bigintType === target2) {
|
|
61726
61726
|
reportError(Diagnostics._0_is_a_primitive_but_1_is_a_wrapper_object_Prefer_using_0_when_possible, targetType, sourceType);
|
|
61727
61727
|
}
|
|
61728
61728
|
}
|
|
@@ -61879,6 +61879,9 @@ ${lanes.join("\n")}
|
|
|
61879
61879
|
}
|
|
61880
61880
|
if (source2.flags & 524288 /* Object */ && target2.flags & 134348796 /* Primitive */) {
|
|
61881
61881
|
tryElaborateErrorsForPrimitivesAndObjects(source2, target2);
|
|
61882
|
+
}
|
|
61883
|
+
if (target2.flags & 524288 /* Object */ && source2.flags & 134348796 /* Primitive */) {
|
|
61884
|
+
tryElaborateErrorsForPrimitivesAndObjects(target2, source2);
|
|
61882
61885
|
} else if (source2.symbol && source2.flags & 524288 /* Object */ && globalObjectType === source2) {
|
|
61883
61886
|
reportError(Diagnostics.The_Object_type_is_assignable_to_very_few_other_types_Did_you_mean_to_use_the_any_type_instead);
|
|
61884
61887
|
} else if (getObjectFlags(source2) & 2048 /* JsxAttributes */ && target2.flags & 2097152 /* Intersection */) {
|
|
@@ -62926,8 +62929,13 @@ ${lanes.join("\n")}
|
|
|
62926
62929
|
}
|
|
62927
62930
|
const sourceIsPrimitive = !!(sourceFlags & 134348796 /* Primitive */);
|
|
62928
62931
|
if (relation !== identityRelation) {
|
|
62932
|
+
const originalSource = source2;
|
|
62933
|
+
const originalFlags = sourceFlags;
|
|
62929
62934
|
source2 = getApparentType(source2);
|
|
62930
62935
|
sourceFlags = source2.flags;
|
|
62936
|
+
if (source2 !== originalSource && originalFlags & 402668540 /* HasWrapper */ && !(sourceFlags & 402668540 /* HasWrapper */) && source2 === target2) {
|
|
62937
|
+
return 0 /* False */;
|
|
62938
|
+
}
|
|
62931
62939
|
} else if (isGenericMappedType(source2)) {
|
|
62932
62940
|
return 0 /* False */;
|
|
62933
62941
|
}
|
|
@@ -147958,7 +147966,6 @@ ${lanes.join("\n")}
|
|
|
147958
147966
|
return { name: completionNameForLiteral(sourceFile, preferences, literal), kind: "string" /* string */, kindModifiers: "" /* none */, sortText: SortText.LocationPriority };
|
|
147959
147967
|
}
|
|
147960
147968
|
function createCompletionEntry(symbol, sortText, replacementToken, contextToken, location, position, sourceFile, host, program, name, needsConvertPropertyAccess, origin, recommendedCompletion, propertyAccessToConvert, isJsxInitializer, importStatementCompletion, useSemicolons, options, preferences, completionKind, formatContext, isJsxIdentifierExpected, isRightOfOpenTag, includeSymbol) {
|
|
147961
|
-
var _a2;
|
|
147962
147969
|
let insertText;
|
|
147963
147970
|
let replacementSpan = getReplacementSpanForContextToken(replacementToken);
|
|
147964
147971
|
let data;
|
|
@@ -148016,10 +148023,6 @@ ${lanes.join("\n")}
|
|
|
148016
148023
|
if ((origin == null ? void 0 : origin.kind) === 64 /* TypeOnlyAlias */) {
|
|
148017
148024
|
hasAction = true;
|
|
148018
148025
|
}
|
|
148019
|
-
if (contextToken && isPropertyAssignment(contextToken.parent) && ((_a2 = findNextToken(contextToken, contextToken == null ? void 0 : contextToken.parent, sourceFile)) == null ? void 0 : _a2.kind) !== 27 /* CommaToken */ && completionKind === 0 /* ObjectPropertyDeclaration */) {
|
|
148020
|
-
source = "ObjectLiteralExpression/" /* ObjectLiteralExpression */;
|
|
148021
|
-
hasAction = true;
|
|
148022
|
-
}
|
|
148023
148026
|
if (preferences.includeCompletionsWithClassMemberSnippets && preferences.includeCompletionsWithInsertText && completionKind === 3 /* MemberLike */ && isClassLikeMemberCompletion(symbol, location, sourceFile)) {
|
|
148024
148027
|
let importAdder;
|
|
148025
148028
|
({ insertText, isSnippet, importAdder, replacementSpan } = getEntryForMemberCompletion(host, program, options, preferences, name, symbol, location, position, contextToken, formatContext));
|
|
@@ -148708,7 +148711,7 @@ ${lanes.join("\n")}
|
|
|
148708
148711
|
return firstDefined(symbols, (symbol, index) => {
|
|
148709
148712
|
const origin = symbolToOriginInfoMap[index];
|
|
148710
148713
|
const info = getCompletionEntryDisplayNameForSymbol(symbol, getEmitScriptTarget(compilerOptions), origin, completionKind, completionData.isJsxIdentifierExpected);
|
|
148711
|
-
return info && info.name === entryId.name && (entryId.source === "ClassMemberSnippet/" /* ClassMemberSnippet */ && symbol.flags & 106500 /* ClassMember */ || entryId.source === "ObjectLiteralMethodSnippet/" /* ObjectLiteralMethodSnippet */ && symbol.flags & (4 /* Property */ | 8192 /* Method */) || getSourceFromOrigin(origin) === entryId.source
|
|
148714
|
+
return info && info.name === entryId.name && (entryId.source === "ClassMemberSnippet/" /* ClassMemberSnippet */ && symbol.flags & 106500 /* ClassMember */ || entryId.source === "ObjectLiteralMethodSnippet/" /* ObjectLiteralMethodSnippet */ && symbol.flags & (4 /* Property */ | 8192 /* Method */) || getSourceFromOrigin(origin) === entryId.source) ? { type: "symbol", symbol, location, origin, contextToken, previousToken, isJsxInitializer, isTypeOnlyLocation } : void 0;
|
|
148712
148715
|
}) || { type: "none" };
|
|
148713
148716
|
}
|
|
148714
148717
|
function getCompletionEntryDetails(program, log, sourceFile, position, entryId, host, formatContext, preferences, cancellationToken) {
|
|
@@ -148846,21 +148849,6 @@ ${lanes.join("\n")}
|
|
|
148846
148849
|
Debug.assertIsDefined(codeAction2, "Expected to have a code action for promoting type-only alias");
|
|
148847
148850
|
return { codeActions: [codeAction2], sourceDisplay: void 0 };
|
|
148848
148851
|
}
|
|
148849
|
-
if (source === "ObjectLiteralExpression/" /* ObjectLiteralExpression */ && contextToken) {
|
|
148850
|
-
const changes = ts_textChanges_exports.ChangeTracker.with(
|
|
148851
|
-
{ host, formatContext, preferences },
|
|
148852
|
-
(tracker) => tracker.insertText(sourceFile, contextToken.end, ",")
|
|
148853
|
-
);
|
|
148854
|
-
if (changes) {
|
|
148855
|
-
return {
|
|
148856
|
-
sourceDisplay: void 0,
|
|
148857
|
-
codeActions: [{
|
|
148858
|
-
changes,
|
|
148859
|
-
description: diagnosticToString([Diagnostics.Add_missing_comma_for_an_object_member_completion_0, name])
|
|
148860
|
-
}]
|
|
148861
|
-
};
|
|
148862
|
-
}
|
|
148863
|
-
}
|
|
148864
148852
|
if (!origin || !(originIsExport(origin) || originIsResolvedExport(origin))) {
|
|
148865
148853
|
return { codeActions: void 0, sourceDisplay: void 0 };
|
|
148866
148854
|
}
|
|
@@ -150259,10 +150247,6 @@ ${lanes.join("\n")}
|
|
|
150259
150247
|
return isMethodDeclaration(parent2) ? tryCast(parent2.parent, isObjectLiteralExpression) : void 0;
|
|
150260
150248
|
case 79 /* Identifier */:
|
|
150261
150249
|
return contextToken.text === "async" && isShorthandPropertyAssignment(contextToken.parent) ? contextToken.parent.parent : void 0;
|
|
150262
|
-
default:
|
|
150263
|
-
if (parent2.parent && isObjectLiteralExpression(parent2.parent) && contextToken.kind !== 58 /* ColonToken */) {
|
|
150264
|
-
return parent2.parent;
|
|
150265
|
-
}
|
|
150266
150250
|
}
|
|
150267
150251
|
}
|
|
150268
150252
|
return void 0;
|
|
@@ -150803,7 +150787,6 @@ ${lanes.join("\n")}
|
|
|
150803
150787
|
CompletionSource2["TypeOnlyAlias"] = "TypeOnlyAlias/";
|
|
150804
150788
|
CompletionSource2["ObjectLiteralMethodSnippet"] = "ObjectLiteralMethodSnippet/";
|
|
150805
150789
|
CompletionSource2["SwitchCases"] = "SwitchCases/";
|
|
150806
|
-
CompletionSource2["ObjectLiteralExpression"] = "ObjectLiteralExpression/";
|
|
150807
150790
|
return CompletionSource2;
|
|
150808
150791
|
})(CompletionSource || {});
|
|
150809
150792
|
SymbolOriginInfoKind = /* @__PURE__ */ ((SymbolOriginInfoKind2) => {
|
|
@@ -163797,10 +163780,6 @@ ${newComment.split("\n").map((c) => ` * ${c}`).join("\n")}
|
|
|
163797
163780
|
const suffix = this.nextCommaToken(sourceFile, oldNode) ? "" : "," + this.newLineCharacter;
|
|
163798
163781
|
this.replaceNode(sourceFile, oldNode, newNode, { suffix });
|
|
163799
163782
|
}
|
|
163800
|
-
replacePropertyAssignmentOnSameLine(sourceFile, oldNode, newNode) {
|
|
163801
|
-
const suffix = this.nextCommaToken(sourceFile, oldNode) ? "" : ",";
|
|
163802
|
-
this.replaceNode(sourceFile, oldNode, newNode, { suffix });
|
|
163803
|
-
}
|
|
163804
163783
|
insertNodeAt(sourceFile, pos, newNode, options = {}) {
|
|
163805
163784
|
this.replaceRange(sourceFile, createRange(pos), newNode, options);
|
|
163806
163785
|
}
|
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-insiders.
|
|
57
|
+
var version = `${versionMajorMinor}.0-insiders.20230224`;
|
|
58
58
|
|
|
59
59
|
// src/compiler/core.ts
|
|
60
60
|
var emptyArray = [];
|
|
@@ -3235,6 +3235,7 @@ var TypeFlags = /* @__PURE__ */ ((TypeFlags2) => {
|
|
|
3235
3235
|
TypeFlags2[TypeFlags2["IncludesEmptyObject"] = 16777216 /* Conditional */] = "IncludesEmptyObject";
|
|
3236
3236
|
TypeFlags2[TypeFlags2["IncludesInstantiable"] = 33554432 /* Substitution */] = "IncludesInstantiable";
|
|
3237
3237
|
TypeFlags2[TypeFlags2["NotPrimitiveUnion"] = 36323363] = "NotPrimitiveUnion";
|
|
3238
|
+
TypeFlags2[TypeFlags2["HasWrapper"] = 402668540] = "HasWrapper";
|
|
3238
3239
|
return TypeFlags2;
|
|
3239
3240
|
})(TypeFlags || {});
|
|
3240
3241
|
var ObjectFlags = /* @__PURE__ */ ((ObjectFlags3) => {
|
|
@@ -7227,8 +7228,7 @@ var Diagnostics = {
|
|
|
7227
7228
|
_0_is_possibly_undefined: diag(18048, 1 /* Error */, "_0_is_possibly_undefined_18048", "'{0}' is possibly 'undefined'."),
|
|
7228
7229
|
_0_is_possibly_null_or_undefined: diag(18049, 1 /* Error */, "_0_is_possibly_null_or_undefined_18049", "'{0}' is possibly 'null' or 'undefined'."),
|
|
7229
7230
|
The_value_0_cannot_be_used_here: diag(18050, 1 /* Error */, "The_value_0_cannot_be_used_here_18050", "The value '{0}' cannot be used here."),
|
|
7230
|
-
Compiler_option_0_cannot_be_given_an_empty_string: diag(18051, 1 /* Error */, "Compiler_option_0_cannot_be_given_an_empty_string_18051", "Compiler option '{0}' cannot be given an empty string.")
|
|
7231
|
-
Add_missing_comma_for_an_object_member_completion_0: diag(18052, 3 /* Message */, "Add_missing_comma_for_an_object_member_completion_0_18052", "Add missing comma for an object member completion '{0}'.")
|
|
7231
|
+
Compiler_option_0_cannot_be_given_an_empty_string: diag(18051, 1 /* Error */, "Compiler_option_0_cannot_be_given_an_empty_string_18051", "Compiler option '{0}' cannot be given an empty string.")
|
|
7232
7232
|
};
|
|
7233
7233
|
|
|
7234
7234
|
// src/compiler/scanner.ts
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "@typescript-deploys/pr-build",
|
|
3
3
|
"author": "Microsoft Corp.",
|
|
4
4
|
"homepage": "https://www.typescriptlang.org/",
|
|
5
|
-
"version": "5.0.0-pr-
|
|
5
|
+
"version": "5.0.0-pr-52947-7",
|
|
6
6
|
"license": "Apache-2.0",
|
|
7
7
|
"description": "TypeScript is a language for application scale JavaScript development",
|
|
8
8
|
"keywords": [
|