typescript 4.5.1-rc → 4.5.5
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/cancellationToken.js +1 -1
- package/lib/lib.es5.d.ts +1 -1
- package/lib/tsc.js +370 -338
- package/lib/tsserver.js +720 -674
- package/lib/tsserverlibrary.js +696 -650
- package/lib/typescript.js +605 -559
- package/lib/typescriptServices.js +605 -559
- package/lib/typingsInstaller.js +448 -410
- package/package.json +2 -2
package/lib/tsc.js
CHANGED
|
@@ -69,7 +69,7 @@ var __generator = (this && this.__generator) || function (thisArg, body) {
|
|
|
69
69
|
var ts;
|
|
70
70
|
(function (ts) {
|
|
71
71
|
ts.versionMajorMinor = "4.5";
|
|
72
|
-
ts.version =
|
|
72
|
+
ts.version = "4.5.5";
|
|
73
73
|
var NativeCollections;
|
|
74
74
|
(function (NativeCollections) {
|
|
75
75
|
function tryGetNativeMap() {
|
|
@@ -88,7 +88,7 @@ var ts;
|
|
|
88
88
|
var constructor = (_a = NativeCollections[nativeFactory]()) !== null && _a !== void 0 ? _a : ts.ShimCollections === null || ts.ShimCollections === void 0 ? void 0 : ts.ShimCollections[shimFactory](ts.getIterator);
|
|
89
89
|
if (constructor)
|
|
90
90
|
return constructor;
|
|
91
|
-
throw new Error("TypeScript requires an environment that provides a compatible native "
|
|
91
|
+
throw new Error("TypeScript requires an environment that provides a compatible native ".concat(name, " implementation."));
|
|
92
92
|
}
|
|
93
93
|
})(ts || (ts = {}));
|
|
94
94
|
var ts;
|
|
@@ -1294,7 +1294,7 @@ var ts;
|
|
|
1294
1294
|
function cast(value, test) {
|
|
1295
1295
|
if (value !== undefined && test(value))
|
|
1296
1296
|
return value;
|
|
1297
|
-
return ts.Debug.fail("Invalid cast. The supplied value "
|
|
1297
|
+
return ts.Debug.fail("Invalid cast. The supplied value ".concat(value, " did not pass the test '").concat(ts.Debug.getFunctionName(test), "'."));
|
|
1298
1298
|
}
|
|
1299
1299
|
ts.cast = cast;
|
|
1300
1300
|
function noop(_) { }
|
|
@@ -1344,7 +1344,7 @@ var ts;
|
|
|
1344
1344
|
function memoizeOne(callback) {
|
|
1345
1345
|
var map = new ts.Map();
|
|
1346
1346
|
return function (arg) {
|
|
1347
|
-
var key = typeof arg
|
|
1347
|
+
var key = "".concat(typeof arg, ":").concat(arg);
|
|
1348
1348
|
var value = map.get(key);
|
|
1349
1349
|
if (value === undefined && !map.has(key)) {
|
|
1350
1350
|
value = callback(arg);
|
|
@@ -1679,7 +1679,7 @@ var ts;
|
|
|
1679
1679
|
ts.createGetCanonicalFileName = createGetCanonicalFileName;
|
|
1680
1680
|
function patternText(_a) {
|
|
1681
1681
|
var prefix = _a.prefix, suffix = _a.suffix;
|
|
1682
|
-
return prefix
|
|
1682
|
+
return "".concat(prefix, "*").concat(suffix);
|
|
1683
1683
|
}
|
|
1684
1684
|
ts.patternText = patternText;
|
|
1685
1685
|
function matchedText(pattern, candidate) {
|
|
@@ -1948,7 +1948,7 @@ var ts;
|
|
|
1948
1948
|
}
|
|
1949
1949
|
function fail(message, stackCrawlMark) {
|
|
1950
1950
|
debugger;
|
|
1951
|
-
var e = new Error(message ? "Debug Failure. "
|
|
1951
|
+
var e = new Error(message ? "Debug Failure. ".concat(message) : "Debug Failure.");
|
|
1952
1952
|
if (Error.captureStackTrace) {
|
|
1953
1953
|
Error.captureStackTrace(e, stackCrawlMark || fail);
|
|
1954
1954
|
}
|
|
@@ -1956,12 +1956,12 @@ var ts;
|
|
|
1956
1956
|
}
|
|
1957
1957
|
Debug.fail = fail;
|
|
1958
1958
|
function failBadSyntaxKind(node, message, stackCrawlMark) {
|
|
1959
|
-
return fail((message || "Unexpected node."
|
|
1959
|
+
return fail("".concat(message || "Unexpected node.", "\r\nNode ").concat(formatSyntaxKind(node.kind), " was unexpected."), stackCrawlMark || failBadSyntaxKind);
|
|
1960
1960
|
}
|
|
1961
1961
|
Debug.failBadSyntaxKind = failBadSyntaxKind;
|
|
1962
1962
|
function assert(expression, message, verboseDebugInfo, stackCrawlMark) {
|
|
1963
1963
|
if (!expression) {
|
|
1964
|
-
message = message ? "False expression: "
|
|
1964
|
+
message = message ? "False expression: ".concat(message) : "False expression.";
|
|
1965
1965
|
if (verboseDebugInfo) {
|
|
1966
1966
|
message += "\r\nVerbose Debug Information: " + (typeof verboseDebugInfo === "string" ? verboseDebugInfo : verboseDebugInfo());
|
|
1967
1967
|
}
|
|
@@ -1971,26 +1971,26 @@ var ts;
|
|
|
1971
1971
|
Debug.assert = assert;
|
|
1972
1972
|
function assertEqual(a, b, msg, msg2, stackCrawlMark) {
|
|
1973
1973
|
if (a !== b) {
|
|
1974
|
-
var message = msg ? msg2 ? msg
|
|
1975
|
-
fail("Expected "
|
|
1974
|
+
var message = msg ? msg2 ? "".concat(msg, " ").concat(msg2) : msg : "";
|
|
1975
|
+
fail("Expected ".concat(a, " === ").concat(b, ". ").concat(message), stackCrawlMark || assertEqual);
|
|
1976
1976
|
}
|
|
1977
1977
|
}
|
|
1978
1978
|
Debug.assertEqual = assertEqual;
|
|
1979
1979
|
function assertLessThan(a, b, msg, stackCrawlMark) {
|
|
1980
1980
|
if (a >= b) {
|
|
1981
|
-
fail("Expected "
|
|
1981
|
+
fail("Expected ".concat(a, " < ").concat(b, ". ").concat(msg || ""), stackCrawlMark || assertLessThan);
|
|
1982
1982
|
}
|
|
1983
1983
|
}
|
|
1984
1984
|
Debug.assertLessThan = assertLessThan;
|
|
1985
1985
|
function assertLessThanOrEqual(a, b, stackCrawlMark) {
|
|
1986
1986
|
if (a > b) {
|
|
1987
|
-
fail("Expected "
|
|
1987
|
+
fail("Expected ".concat(a, " <= ").concat(b), stackCrawlMark || assertLessThanOrEqual);
|
|
1988
1988
|
}
|
|
1989
1989
|
}
|
|
1990
1990
|
Debug.assertLessThanOrEqual = assertLessThanOrEqual;
|
|
1991
1991
|
function assertGreaterThanOrEqual(a, b, stackCrawlMark) {
|
|
1992
1992
|
if (a < b) {
|
|
1993
|
-
fail("Expected "
|
|
1993
|
+
fail("Expected ".concat(a, " >= ").concat(b), stackCrawlMark || assertGreaterThanOrEqual);
|
|
1994
1994
|
}
|
|
1995
1995
|
}
|
|
1996
1996
|
Debug.assertGreaterThanOrEqual = assertGreaterThanOrEqual;
|
|
@@ -2022,42 +2022,42 @@ var ts;
|
|
|
2022
2022
|
function assertNever(member, message, stackCrawlMark) {
|
|
2023
2023
|
if (message === void 0) { message = "Illegal value:"; }
|
|
2024
2024
|
var detail = typeof member === "object" && ts.hasProperty(member, "kind") && ts.hasProperty(member, "pos") && formatSyntaxKind ? "SyntaxKind: " + formatSyntaxKind(member.kind) : JSON.stringify(member);
|
|
2025
|
-
return fail(message
|
|
2025
|
+
return fail("".concat(message, " ").concat(detail), stackCrawlMark || assertNever);
|
|
2026
2026
|
}
|
|
2027
2027
|
Debug.assertNever = assertNever;
|
|
2028
2028
|
function assertEachNode(nodes, test, message, stackCrawlMark) {
|
|
2029
2029
|
if (shouldAssertFunction(1, "assertEachNode")) {
|
|
2030
|
-
assert(test === undefined || ts.every(nodes, test), message || "Unexpected node.", function () { return "Node array did not pass test '"
|
|
2030
|
+
assert(test === undefined || ts.every(nodes, test), message || "Unexpected node.", function () { return "Node array did not pass test '".concat(getFunctionName(test), "'."); }, stackCrawlMark || assertEachNode);
|
|
2031
2031
|
}
|
|
2032
2032
|
}
|
|
2033
2033
|
Debug.assertEachNode = assertEachNode;
|
|
2034
2034
|
function assertNode(node, test, message, stackCrawlMark) {
|
|
2035
2035
|
if (shouldAssertFunction(1, "assertNode")) {
|
|
2036
|
-
assert(node !== undefined && (test === undefined || test(node)), message || "Unexpected node.", function () { return "Node "
|
|
2036
|
+
assert(node !== undefined && (test === undefined || test(node)), message || "Unexpected node.", function () { return "Node ".concat(formatSyntaxKind(node === null || node === void 0 ? void 0 : node.kind), " did not pass test '").concat(getFunctionName(test), "'."); }, stackCrawlMark || assertNode);
|
|
2037
2037
|
}
|
|
2038
2038
|
}
|
|
2039
2039
|
Debug.assertNode = assertNode;
|
|
2040
2040
|
function assertNotNode(node, test, message, stackCrawlMark) {
|
|
2041
2041
|
if (shouldAssertFunction(1, "assertNotNode")) {
|
|
2042
|
-
assert(node === undefined || test === undefined || !test(node), message || "Unexpected node.", function () { return "Node "
|
|
2042
|
+
assert(node === undefined || test === undefined || !test(node), message || "Unexpected node.", function () { return "Node ".concat(formatSyntaxKind(node.kind), " should not have passed test '").concat(getFunctionName(test), "'."); }, stackCrawlMark || assertNotNode);
|
|
2043
2043
|
}
|
|
2044
2044
|
}
|
|
2045
2045
|
Debug.assertNotNode = assertNotNode;
|
|
2046
2046
|
function assertOptionalNode(node, test, message, stackCrawlMark) {
|
|
2047
2047
|
if (shouldAssertFunction(1, "assertOptionalNode")) {
|
|
2048
|
-
assert(test === undefined || node === undefined || test(node), message || "Unexpected node.", function () { return "Node "
|
|
2048
|
+
assert(test === undefined || node === undefined || test(node), message || "Unexpected node.", function () { return "Node ".concat(formatSyntaxKind(node === null || node === void 0 ? void 0 : node.kind), " did not pass test '").concat(getFunctionName(test), "'."); }, stackCrawlMark || assertOptionalNode);
|
|
2049
2049
|
}
|
|
2050
2050
|
}
|
|
2051
2051
|
Debug.assertOptionalNode = assertOptionalNode;
|
|
2052
2052
|
function assertOptionalToken(node, kind, message, stackCrawlMark) {
|
|
2053
2053
|
if (shouldAssertFunction(1, "assertOptionalToken")) {
|
|
2054
|
-
assert(kind === undefined || node === undefined || node.kind === kind, message || "Unexpected node.", function () { return "Node "
|
|
2054
|
+
assert(kind === undefined || node === undefined || node.kind === kind, message || "Unexpected node.", function () { return "Node ".concat(formatSyntaxKind(node === null || node === void 0 ? void 0 : node.kind), " was not a '").concat(formatSyntaxKind(kind), "' token."); }, stackCrawlMark || assertOptionalToken);
|
|
2055
2055
|
}
|
|
2056
2056
|
}
|
|
2057
2057
|
Debug.assertOptionalToken = assertOptionalToken;
|
|
2058
2058
|
function assertMissingNode(node, message, stackCrawlMark) {
|
|
2059
2059
|
if (shouldAssertFunction(1, "assertMissingNode")) {
|
|
2060
|
-
assert(node === undefined, message || "Unexpected node.", function () { return "Node "
|
|
2060
|
+
assert(node === undefined, message || "Unexpected node.", function () { return "Node ".concat(formatSyntaxKind(node.kind), " was unexpected'."); }, stackCrawlMark || assertMissingNode);
|
|
2061
2061
|
}
|
|
2062
2062
|
}
|
|
2063
2063
|
Debug.assertMissingNode = assertMissingNode;
|
|
@@ -2078,7 +2078,7 @@ var ts;
|
|
|
2078
2078
|
}
|
|
2079
2079
|
Debug.getFunctionName = getFunctionName;
|
|
2080
2080
|
function formatSymbol(symbol) {
|
|
2081
|
-
return "{ name: "
|
|
2081
|
+
return "{ name: ".concat(ts.unescapeLeadingUnderscores(symbol.escapedName), "; flags: ").concat(formatSymbolFlags(symbol.flags), "; declarations: ").concat(ts.map(symbol.declarations, function (node) { return formatSyntaxKind(node.kind); }), " }");
|
|
2082
2082
|
}
|
|
2083
2083
|
Debug.formatSymbol = formatSymbol;
|
|
2084
2084
|
function formatEnum(value, enumObject, isFlags) {
|
|
@@ -2096,7 +2096,7 @@ var ts;
|
|
|
2096
2096
|
break;
|
|
2097
2097
|
}
|
|
2098
2098
|
if (enumValue !== 0 && enumValue & value) {
|
|
2099
|
-
result = ""
|
|
2099
|
+
result = "".concat(result).concat(result ? "|" : "").concat(enumName);
|
|
2100
2100
|
remainingFlags &= ~enumValue;
|
|
2101
2101
|
}
|
|
2102
2102
|
}
|
|
@@ -2205,7 +2205,7 @@ var ts;
|
|
|
2205
2205
|
this.flags & 1 ? "FlowUnreachable" :
|
|
2206
2206
|
"UnknownFlow";
|
|
2207
2207
|
var remainingFlags = this.flags & ~(2048 - 1);
|
|
2208
|
-
return ""
|
|
2208
|
+
return "".concat(flowHeader).concat(remainingFlags ? " (".concat(formatFlowFlags(remainingFlags), ")") : "");
|
|
2209
2209
|
}
|
|
2210
2210
|
},
|
|
2211
2211
|
__debugFlowFlags: { get: function () { return formatEnum(this.flags, ts.FlowFlags, true); } },
|
|
@@ -2235,7 +2235,7 @@ var ts;
|
|
|
2235
2235
|
__tsDebuggerDisplay: {
|
|
2236
2236
|
value: function (defaultValue) {
|
|
2237
2237
|
defaultValue = String(defaultValue).replace(/(?:,[\s\w\d_]+:[^,]+)+\]$/, "]");
|
|
2238
|
-
return "NodeArray "
|
|
2238
|
+
return "NodeArray ".concat(defaultValue);
|
|
2239
2239
|
}
|
|
2240
2240
|
}
|
|
2241
2241
|
});
|
|
@@ -2281,7 +2281,7 @@ var ts;
|
|
|
2281
2281
|
var symbolHeader = this.flags & 33554432 ? "TransientSymbol" :
|
|
2282
2282
|
"Symbol";
|
|
2283
2283
|
var remainingSymbolFlags = this.flags & ~33554432;
|
|
2284
|
-
return symbolHeader
|
|
2284
|
+
return "".concat(symbolHeader, " '").concat(ts.symbolName(this), "'").concat(remainingSymbolFlags ? " (".concat(formatSymbolFlags(remainingSymbolFlags), ")") : "");
|
|
2285
2285
|
}
|
|
2286
2286
|
},
|
|
2287
2287
|
__debugFlags: { get: function () { return formatSymbolFlags(this.flags); } }
|
|
@@ -2290,11 +2290,11 @@ var ts;
|
|
|
2290
2290
|
__tsDebuggerDisplay: {
|
|
2291
2291
|
value: function () {
|
|
2292
2292
|
var typeHeader = this.flags & 98304 ? "NullableType" :
|
|
2293
|
-
this.flags & 384 ? "LiteralType "
|
|
2294
|
-
this.flags & 2048 ? "LiteralType "
|
|
2293
|
+
this.flags & 384 ? "LiteralType ".concat(JSON.stringify(this.value)) :
|
|
2294
|
+
this.flags & 2048 ? "LiteralType ".concat(this.value.negative ? "-" : "").concat(this.value.base10Value, "n") :
|
|
2295
2295
|
this.flags & 8192 ? "UniqueESSymbolType" :
|
|
2296
2296
|
this.flags & 32 ? "EnumType" :
|
|
2297
|
-
this.flags & 67359327 ? "IntrinsicType "
|
|
2297
|
+
this.flags & 67359327 ? "IntrinsicType ".concat(this.intrinsicName) :
|
|
2298
2298
|
this.flags & 1048576 ? "UnionType" :
|
|
2299
2299
|
this.flags & 2097152 ? "IntersectionType" :
|
|
2300
2300
|
this.flags & 4194304 ? "IndexType" :
|
|
@@ -2313,7 +2313,7 @@ var ts;
|
|
|
2313
2313
|
"ObjectType" :
|
|
2314
2314
|
"Type";
|
|
2315
2315
|
var remainingObjectFlags = this.flags & 524288 ? this.objectFlags & ~1343 : 0;
|
|
2316
|
-
return ""
|
|
2316
|
+
return "".concat(typeHeader).concat(this.symbol ? " '".concat(ts.symbolName(this.symbol), "'") : "").concat(remainingObjectFlags ? " (".concat(formatObjectFlags(remainingObjectFlags), ")") : "");
|
|
2317
2317
|
}
|
|
2318
2318
|
},
|
|
2319
2319
|
__debugFlags: { get: function () { return formatTypeFlags(this.flags); } },
|
|
@@ -2347,11 +2347,11 @@ var ts;
|
|
|
2347
2347
|
__tsDebuggerDisplay: {
|
|
2348
2348
|
value: function () {
|
|
2349
2349
|
var nodeHeader = ts.isGeneratedIdentifier(this) ? "GeneratedIdentifier" :
|
|
2350
|
-
ts.isIdentifier(this) ? "Identifier '"
|
|
2351
|
-
ts.isPrivateIdentifier(this) ? "PrivateIdentifier '"
|
|
2352
|
-
ts.isStringLiteral(this) ? "StringLiteral "
|
|
2353
|
-
ts.isNumericLiteral(this) ? "NumericLiteral "
|
|
2354
|
-
ts.isBigIntLiteral(this) ? "BigIntLiteral "
|
|
2350
|
+
ts.isIdentifier(this) ? "Identifier '".concat(ts.idText(this), "'") :
|
|
2351
|
+
ts.isPrivateIdentifier(this) ? "PrivateIdentifier '".concat(ts.idText(this), "'") :
|
|
2352
|
+
ts.isStringLiteral(this) ? "StringLiteral ".concat(JSON.stringify(this.text.length < 10 ? this.text : this.text.slice(10) + "...")) :
|
|
2353
|
+
ts.isNumericLiteral(this) ? "NumericLiteral ".concat(this.text) :
|
|
2354
|
+
ts.isBigIntLiteral(this) ? "BigIntLiteral ".concat(this.text, "n") :
|
|
2355
2355
|
ts.isTypeParameterDeclaration(this) ? "TypeParameterDeclaration" :
|
|
2356
2356
|
ts.isParameter(this) ? "ParameterDeclaration" :
|
|
2357
2357
|
ts.isConstructorDeclaration(this) ? "ConstructorDeclaration" :
|
|
@@ -2383,7 +2383,7 @@ var ts;
|
|
|
2383
2383
|
ts.isNamedTupleMember(this) ? "NamedTupleMember" :
|
|
2384
2384
|
ts.isImportTypeNode(this) ? "ImportTypeNode" :
|
|
2385
2385
|
formatSyntaxKind(this.kind);
|
|
2386
|
-
return ""
|
|
2386
|
+
return "".concat(nodeHeader).concat(this.flags ? " (".concat(formatNodeFlags(this.flags), ")") : "");
|
|
2387
2387
|
}
|
|
2388
2388
|
},
|
|
2389
2389
|
__debugKind: { get: function () { return formatSyntaxKind(this.kind); } },
|
|
@@ -2427,10 +2427,10 @@ var ts;
|
|
|
2427
2427
|
Debug.enableDebugInfo = enableDebugInfo;
|
|
2428
2428
|
function formatDeprecationMessage(name, error, errorAfter, since, message) {
|
|
2429
2429
|
var deprecationMessage = error ? "DeprecationError: " : "DeprecationWarning: ";
|
|
2430
|
-
deprecationMessage += "'"
|
|
2431
|
-
deprecationMessage += since ? "has been deprecated since v"
|
|
2432
|
-
deprecationMessage += error ? " and can no longer be used." : errorAfter ? " and will no longer be usable after v"
|
|
2433
|
-
deprecationMessage += message ? " "
|
|
2430
|
+
deprecationMessage += "'".concat(name, "' ");
|
|
2431
|
+
deprecationMessage += since ? "has been deprecated since v".concat(since) : "is deprecated";
|
|
2432
|
+
deprecationMessage += error ? " and can no longer be used." : errorAfter ? " and will no longer be usable after v".concat(errorAfter, ".") : ".";
|
|
2433
|
+
deprecationMessage += message ? " ".concat(ts.formatStringFromArgs(message, [name], 0)) : "";
|
|
2434
2434
|
return deprecationMessage;
|
|
2435
2435
|
}
|
|
2436
2436
|
function createErrorDeprecation(name, errorAfter, since, message) {
|
|
@@ -2527,11 +2527,11 @@ var ts;
|
|
|
2527
2527
|
}
|
|
2528
2528
|
};
|
|
2529
2529
|
Version.prototype.toString = function () {
|
|
2530
|
-
var result = this.major
|
|
2530
|
+
var result = "".concat(this.major, ".").concat(this.minor, ".").concat(this.patch);
|
|
2531
2531
|
if (ts.some(this.prerelease))
|
|
2532
|
-
result += "-"
|
|
2532
|
+
result += "-".concat(this.prerelease.join("."));
|
|
2533
2533
|
if (ts.some(this.build))
|
|
2534
|
-
result += "+"
|
|
2534
|
+
result += "+".concat(this.build.join("."));
|
|
2535
2535
|
return result;
|
|
2536
2536
|
};
|
|
2537
2537
|
Version.zero = new Version(0, 0, 0);
|
|
@@ -2753,7 +2753,7 @@ var ts;
|
|
|
2753
2753
|
return ts.map(comparators, formatComparator).join(" ");
|
|
2754
2754
|
}
|
|
2755
2755
|
function formatComparator(comparator) {
|
|
2756
|
-
return ""
|
|
2756
|
+
return "".concat(comparator.operator).concat(comparator.operand);
|
|
2757
2757
|
}
|
|
2758
2758
|
})(ts || (ts = {}));
|
|
2759
2759
|
var ts;
|
|
@@ -2982,7 +2982,7 @@ var ts;
|
|
|
2982
2982
|
fs = require("fs");
|
|
2983
2983
|
}
|
|
2984
2984
|
catch (e) {
|
|
2985
|
-
throw new Error("tracing requires having fs\n(original error: "
|
|
2985
|
+
throw new Error("tracing requires having fs\n(original error: ".concat(e.message || e, ")"));
|
|
2986
2986
|
}
|
|
2987
2987
|
}
|
|
2988
2988
|
mode = tracingMode;
|
|
@@ -2993,11 +2993,11 @@ var ts;
|
|
|
2993
2993
|
if (!fs.existsSync(traceDir)) {
|
|
2994
2994
|
fs.mkdirSync(traceDir, { recursive: true });
|
|
2995
2995
|
}
|
|
2996
|
-
var countPart = mode === "build" ? "."
|
|
2997
|
-
: mode === "server" ? "."
|
|
2996
|
+
var countPart = mode === "build" ? ".".concat(process.pid, "-").concat(++traceCount)
|
|
2997
|
+
: mode === "server" ? ".".concat(process.pid)
|
|
2998
2998
|
: "";
|
|
2999
|
-
var tracePath = ts.combinePaths(traceDir, "trace"
|
|
3000
|
-
var typesPath = ts.combinePaths(traceDir, "types"
|
|
2999
|
+
var tracePath = ts.combinePaths(traceDir, "trace".concat(countPart, ".json"));
|
|
3000
|
+
var typesPath = ts.combinePaths(traceDir, "types".concat(countPart, ".json"));
|
|
3001
3001
|
legend.push({
|
|
3002
3002
|
configFilePath: configFilePath,
|
|
3003
3003
|
tracePath: tracePath,
|
|
@@ -3065,7 +3065,7 @@ var ts;
|
|
|
3065
3065
|
writeEvent("E", phase, name, args, undefined, endTime);
|
|
3066
3066
|
}
|
|
3067
3067
|
else if (sampleInterval - (time % sampleInterval) <= endTime - time) {
|
|
3068
|
-
writeEvent("X", phase, name, args, "\"dur\":"
|
|
3068
|
+
writeEvent("X", phase, name, args, "\"dur\":".concat(endTime - time), time);
|
|
3069
3069
|
}
|
|
3070
3070
|
}
|
|
3071
3071
|
function writeEvent(eventType, phase, name, args, extras, time) {
|
|
@@ -3073,11 +3073,11 @@ var ts;
|
|
|
3073
3073
|
if (mode === "server" && phase === "checkTypes")
|
|
3074
3074
|
return;
|
|
3075
3075
|
ts.performance.mark("beginTracing");
|
|
3076
|
-
fs.writeSync(traceFd, ",\n{\"pid\":1,\"tid\":1,\"ph\":\""
|
|
3076
|
+
fs.writeSync(traceFd, ",\n{\"pid\":1,\"tid\":1,\"ph\":\"".concat(eventType, "\",\"cat\":\"").concat(phase, "\",\"ts\":").concat(time, ",\"name\":\"").concat(name, "\""));
|
|
3077
3077
|
if (extras)
|
|
3078
|
-
fs.writeSync(traceFd, ","
|
|
3078
|
+
fs.writeSync(traceFd, ",".concat(extras));
|
|
3079
3079
|
if (args)
|
|
3080
|
-
fs.writeSync(traceFd, ",\"args\":"
|
|
3080
|
+
fs.writeSync(traceFd, ",\"args\":".concat(JSON.stringify(args)));
|
|
3081
3081
|
fs.writeSync(traceFd, "}");
|
|
3082
3082
|
ts.performance.mark("endTracing");
|
|
3083
3083
|
ts.performance.measure("Tracing", "beginTracing", "endTracing");
|
|
@@ -3882,7 +3882,7 @@ var ts;
|
|
|
3882
3882
|
pollingChunkSize = getCustomPollingBasedLevels("TSC_WATCH_POLLINGCHUNKSIZE", defaultChunkLevels) || pollingChunkSize;
|
|
3883
3883
|
ts.unchangedPollThresholds = getCustomPollingBasedLevels("TSC_WATCH_UNCHANGEDPOLLTHRESHOLDS", defaultChunkLevels) || ts.unchangedPollThresholds;
|
|
3884
3884
|
function getLevel(envVar, level) {
|
|
3885
|
-
return system.getEnvironmentVariable(envVar
|
|
3885
|
+
return system.getEnvironmentVariable("".concat(envVar, "_").concat(level.toUpperCase()));
|
|
3886
3886
|
}
|
|
3887
3887
|
function getCustomLevels(baseVariable) {
|
|
3888
3888
|
var customLevels;
|
|
@@ -4302,7 +4302,7 @@ var ts;
|
|
|
4302
4302
|
}
|
|
4303
4303
|
function onTimerToUpdateChildWatches() {
|
|
4304
4304
|
timerToUpdateChildWatches = undefined;
|
|
4305
|
-
ts.sysLog("sysLog:: onTimerToUpdateChildWatches:: "
|
|
4305
|
+
ts.sysLog("sysLog:: onTimerToUpdateChildWatches:: ".concat(cacheToUpdateChildWatches.size));
|
|
4306
4306
|
var start = ts.timestamp();
|
|
4307
4307
|
var invokeMap = new ts.Map();
|
|
4308
4308
|
while (!timerToUpdateChildWatches && cacheToUpdateChildWatches.size) {
|
|
@@ -4313,7 +4313,7 @@ var ts;
|
|
|
4313
4313
|
var hasChanges = updateChildWatches(dirName, dirPath, options);
|
|
4314
4314
|
invokeCallbacks(dirPath, invokeMap, hasChanges ? undefined : fileNames);
|
|
4315
4315
|
}
|
|
4316
|
-
ts.sysLog("sysLog:: invokingWatchers:: Elapsed:: "
|
|
4316
|
+
ts.sysLog("sysLog:: invokingWatchers:: Elapsed:: ".concat(ts.timestamp() - start, "ms:: ").concat(cacheToUpdateChildWatches.size));
|
|
4317
4317
|
callbackCache.forEach(function (callbacks, rootDirName) {
|
|
4318
4318
|
var existing = invokeMap.get(rootDirName);
|
|
4319
4319
|
if (existing) {
|
|
@@ -4329,7 +4329,7 @@ var ts;
|
|
|
4329
4329
|
}
|
|
4330
4330
|
});
|
|
4331
4331
|
var elapsed = ts.timestamp() - start;
|
|
4332
|
-
ts.sysLog("sysLog:: Elapsed:: "
|
|
4332
|
+
ts.sysLog("sysLog:: Elapsed:: ".concat(elapsed, "ms:: onTimerToUpdateChildWatches:: ").concat(cacheToUpdateChildWatches.size, " ").concat(timerToUpdateChildWatches));
|
|
4333
4333
|
}
|
|
4334
4334
|
function removeChildWatches(parentWatcher) {
|
|
4335
4335
|
if (!parentWatcher)
|
|
@@ -4721,7 +4721,7 @@ var ts;
|
|
|
4721
4721
|
var externalFileCounter = 0;
|
|
4722
4722
|
var remappedPaths = new ts.Map();
|
|
4723
4723
|
var normalizedDir = ts.normalizeSlashes(__dirname);
|
|
4724
|
-
var fileUrlRoot = "file://"
|
|
4724
|
+
var fileUrlRoot = "file://".concat(ts.getRootLength(normalizedDir) === 1 ? "" : "/").concat(normalizedDir);
|
|
4725
4725
|
for (var _i = 0, _a = profile.nodes; _i < _a.length; _i++) {
|
|
4726
4726
|
var node = _a[_i];
|
|
4727
4727
|
if (node.callFrame.url) {
|
|
@@ -4730,7 +4730,7 @@ var ts;
|
|
|
4730
4730
|
node.callFrame.url = ts.getRelativePathToDirectoryOrUrl(fileUrlRoot, url, fileUrlRoot, ts.createGetCanonicalFileName(useCaseSensitiveFileNames), true);
|
|
4731
4731
|
}
|
|
4732
4732
|
else if (!nativePattern.test(url)) {
|
|
4733
|
-
node.callFrame.url = (remappedPaths.has(url) ? remappedPaths : remappedPaths.set(url, "external"
|
|
4733
|
+
node.callFrame.url = (remappedPaths.has(url) ? remappedPaths : remappedPaths.set(url, "external".concat(externalFileCounter, ".js"))).get(url);
|
|
4734
4734
|
externalFileCounter++;
|
|
4735
4735
|
}
|
|
4736
4736
|
}
|
|
@@ -4746,7 +4746,7 @@ var ts;
|
|
|
4746
4746
|
if (!err) {
|
|
4747
4747
|
try {
|
|
4748
4748
|
if ((_b = statSync(profilePath)) === null || _b === void 0 ? void 0 : _b.isDirectory()) {
|
|
4749
|
-
profilePath = _path.join(profilePath, (new Date()).toISOString().replace(/:/g, "-")
|
|
4749
|
+
profilePath = _path.join(profilePath, "".concat((new Date()).toISOString().replace(/:/g, "-"), "+P").concat(process.pid, ".cpuprofile"));
|
|
4750
4750
|
}
|
|
4751
4751
|
}
|
|
4752
4752
|
catch (_c) {
|
|
@@ -4831,7 +4831,7 @@ var ts;
|
|
|
4831
4831
|
}
|
|
4832
4832
|
};
|
|
4833
4833
|
function invokeCallbackAndUpdateWatcher(createWatcher) {
|
|
4834
|
-
ts.sysLog("sysLog:: "
|
|
4834
|
+
ts.sysLog("sysLog:: ".concat(fileOrDirectory, ":: Changing watcher to ").concat(createWatcher === watchPresentFileSystemEntry ? "Present" : "Missing", "FileSystemEntryWatcher"));
|
|
4835
4835
|
callback("rename", "");
|
|
4836
4836
|
if (watcher) {
|
|
4837
4837
|
watcher.close();
|
|
@@ -4848,7 +4848,7 @@ var ts;
|
|
|
4848
4848
|
}
|
|
4849
4849
|
}
|
|
4850
4850
|
if (hitSystemWatcherLimit) {
|
|
4851
|
-
ts.sysLog("sysLog:: "
|
|
4851
|
+
ts.sysLog("sysLog:: ".concat(fileOrDirectory, ":: Defaulting to fsWatchFile"));
|
|
4852
4852
|
return watchPresentFileSystemEntryWithFsWatchFile();
|
|
4853
4853
|
}
|
|
4854
4854
|
try {
|
|
@@ -4860,7 +4860,7 @@ var ts;
|
|
|
4860
4860
|
}
|
|
4861
4861
|
catch (e) {
|
|
4862
4862
|
hitSystemWatcherLimit || (hitSystemWatcherLimit = e.code === "ENOSPC");
|
|
4863
|
-
ts.sysLog("sysLog:: "
|
|
4863
|
+
ts.sysLog("sysLog:: ".concat(fileOrDirectory, ":: Changing to fsWatchFile"));
|
|
4864
4864
|
return watchPresentFileSystemEntryWithFsWatchFile();
|
|
4865
4865
|
}
|
|
4866
4866
|
}
|
|
@@ -4976,7 +4976,7 @@ var ts;
|
|
|
4976
4976
|
}
|
|
4977
4977
|
}
|
|
4978
4978
|
function readDirectory(path, extensions, excludes, includes, depth) {
|
|
4979
|
-
return ts.matchFiles(path, extensions, excludes, includes, useCaseSensitiveFileNames, process.cwd(), depth, getAccessibleFileSystemEntries, realpath
|
|
4979
|
+
return ts.matchFiles(path, extensions, excludes, includes, useCaseSensitiveFileNames, process.cwd(), depth, getAccessibleFileSystemEntries, realpath);
|
|
4980
4980
|
}
|
|
4981
4981
|
function fileSystemEntryExists(path, entryKind) {
|
|
4982
4982
|
var originalStackTraceLimit = Error.stackTraceLimit;
|
|
@@ -7066,7 +7066,7 @@ var ts;
|
|
|
7066
7066
|
line = line < 0 ? 0 : line >= lineStarts.length ? lineStarts.length - 1 : line;
|
|
7067
7067
|
}
|
|
7068
7068
|
else {
|
|
7069
|
-
ts.Debug.fail("Bad line number. Line: "
|
|
7069
|
+
ts.Debug.fail("Bad line number. Line: ".concat(line, ", lineStarts.length: ").concat(lineStarts.length, " , line map is correct? ").concat(debugText !== undefined ? ts.arraysEqual(lineStarts, computeLineStarts(debugText)) : "unknown"));
|
|
7070
7070
|
}
|
|
7071
7071
|
}
|
|
7072
7072
|
var res = lineStarts[line] + character;
|
|
@@ -9570,7 +9570,7 @@ var ts;
|
|
|
9570
9570
|
function getTextOfJSDocComment(comment) {
|
|
9571
9571
|
return typeof comment === "string" ? comment
|
|
9572
9572
|
: comment === null || comment === void 0 ? void 0 : comment.map(function (c) {
|
|
9573
|
-
return c.kind === 319 ? c.text : "{@link "
|
|
9573
|
+
return c.kind === 319 ? c.text : "{@link ".concat(c.name ? ts.entityNameToString(c.name) + " " : "").concat(c.text, "}");
|
|
9574
9574
|
}).join("");
|
|
9575
9575
|
}
|
|
9576
9576
|
ts.getTextOfJSDocComment = getTextOfJSDocComment;
|
|
@@ -10670,8 +10670,8 @@ var ts;
|
|
|
10670
10670
|
}
|
|
10671
10671
|
function packageIdToString(_a) {
|
|
10672
10672
|
var name = _a.name, subModuleName = _a.subModuleName, version = _a.version;
|
|
10673
|
-
var fullName = subModuleName ? name
|
|
10674
|
-
return fullName
|
|
10673
|
+
var fullName = subModuleName ? "".concat(name, "/").concat(subModuleName) : name;
|
|
10674
|
+
return "".concat(fullName, "@").concat(version);
|
|
10675
10675
|
}
|
|
10676
10676
|
ts.packageIdToString = packageIdToString;
|
|
10677
10677
|
function typeDirectiveIsEqualTo(oldResolution, newResolution) {
|
|
@@ -10741,7 +10741,7 @@ var ts;
|
|
|
10741
10741
|
function nodePosToString(node) {
|
|
10742
10742
|
var file = getSourceFileOfNode(node);
|
|
10743
10743
|
var loc = ts.getLineAndCharacterOfPosition(file, node.pos);
|
|
10744
|
-
return file.fileName
|
|
10744
|
+
return "".concat(file.fileName, "(").concat(loc.line + 1, ",").concat(loc.character + 1, ")");
|
|
10745
10745
|
}
|
|
10746
10746
|
ts.nodePosToString = nodePosToString;
|
|
10747
10747
|
function getEndLinePosition(line, sourceFile) {
|
|
@@ -10842,7 +10842,7 @@ var ts;
|
|
|
10842
10842
|
ts.isPinnedComment = isPinnedComment;
|
|
10843
10843
|
function createCommentDirectivesMap(sourceFile, commentDirectives) {
|
|
10844
10844
|
var directivesByLine = new ts.Map(commentDirectives.map(function (commentDirective) { return ([
|
|
10845
|
-
""
|
|
10845
|
+
"".concat(ts.getLineAndCharacterOfPosition(sourceFile, commentDirective.range.end).line),
|
|
10846
10846
|
commentDirective,
|
|
10847
10847
|
]); }));
|
|
10848
10848
|
var usedLines = new ts.Map();
|
|
@@ -10859,10 +10859,10 @@ var ts;
|
|
|
10859
10859
|
});
|
|
10860
10860
|
}
|
|
10861
10861
|
function markUsed(line) {
|
|
10862
|
-
if (!directivesByLine.has(""
|
|
10862
|
+
if (!directivesByLine.has("".concat(line))) {
|
|
10863
10863
|
return false;
|
|
10864
10864
|
}
|
|
10865
|
-
usedLines.set(""
|
|
10865
|
+
usedLines.set("".concat(line), true);
|
|
10866
10866
|
return true;
|
|
10867
10867
|
}
|
|
10868
10868
|
}
|
|
@@ -11046,7 +11046,7 @@ var ts;
|
|
|
11046
11046
|
}
|
|
11047
11047
|
return node.text;
|
|
11048
11048
|
}
|
|
11049
|
-
return ts.Debug.fail("Literal kind '"
|
|
11049
|
+
return ts.Debug.fail("Literal kind '".concat(node.kind, "' not accounted for."));
|
|
11050
11050
|
}
|
|
11051
11051
|
ts.getLiteralText = getLiteralText;
|
|
11052
11052
|
function canUseOriginalText(node, flags) {
|
|
@@ -12247,7 +12247,7 @@ var ts;
|
|
|
12247
12247
|
}
|
|
12248
12248
|
ts.getExternalModuleImportEqualsDeclarationExpression = getExternalModuleImportEqualsDeclarationExpression;
|
|
12249
12249
|
function getExternalModuleRequireArgument(node) {
|
|
12250
|
-
return
|
|
12250
|
+
return isVariableDeclarationInitializedToBareOrAccessedRequire(node) && getLeftmostAccessExpression(node.initializer).arguments[0];
|
|
12251
12251
|
}
|
|
12252
12252
|
ts.getExternalModuleRequireArgument = getExternalModuleRequireArgument;
|
|
12253
12253
|
function isInternalModuleImportEqualsDeclaration(node) {
|
|
@@ -12301,17 +12301,26 @@ var ts;
|
|
|
12301
12301
|
return !requireStringLiteralLikeArgument || ts.isStringLiteralLike(arg);
|
|
12302
12302
|
}
|
|
12303
12303
|
ts.isRequireCall = isRequireCall;
|
|
12304
|
-
function
|
|
12304
|
+
function isVariableDeclarationInitializedToRequire(node) {
|
|
12305
|
+
return isVariableDeclarationInitializedWithRequireHelper(node, false);
|
|
12306
|
+
}
|
|
12307
|
+
ts.isVariableDeclarationInitializedToRequire = isVariableDeclarationInitializedToRequire;
|
|
12308
|
+
function isVariableDeclarationInitializedToBareOrAccessedRequire(node) {
|
|
12309
|
+
return isVariableDeclarationInitializedWithRequireHelper(node, true);
|
|
12310
|
+
}
|
|
12311
|
+
ts.isVariableDeclarationInitializedToBareOrAccessedRequire = isVariableDeclarationInitializedToBareOrAccessedRequire;
|
|
12312
|
+
function isVariableDeclarationInitializedWithRequireHelper(node, allowAccessedRequire) {
|
|
12305
12313
|
if (node.kind === 202) {
|
|
12306
12314
|
node = node.parent.parent;
|
|
12307
12315
|
}
|
|
12308
|
-
return ts.isVariableDeclaration(node) &&
|
|
12316
|
+
return ts.isVariableDeclaration(node) &&
|
|
12317
|
+
!!node.initializer &&
|
|
12318
|
+
isRequireCall(allowAccessedRequire ? getLeftmostAccessExpression(node.initializer) : node.initializer, true);
|
|
12309
12319
|
}
|
|
12310
|
-
ts.isRequireVariableDeclaration = isRequireVariableDeclaration;
|
|
12311
12320
|
function isRequireVariableStatement(node) {
|
|
12312
12321
|
return ts.isVariableStatement(node)
|
|
12313
12322
|
&& node.declarationList.declarations.length > 0
|
|
12314
|
-
&& ts.every(node.declarationList.declarations, function (decl) { return
|
|
12323
|
+
&& ts.every(node.declarationList.declarations, function (decl) { return isVariableDeclarationInitializedToRequire(decl); });
|
|
12315
12324
|
}
|
|
12316
12325
|
ts.isRequireVariableStatement = isRequireVariableStatement;
|
|
12317
12326
|
function isSingleOrDoubleQuote(charCode) {
|
|
@@ -13340,11 +13349,11 @@ var ts;
|
|
|
13340
13349
|
}
|
|
13341
13350
|
ts.getEscapedTextOfIdentifierOrLiteral = getEscapedTextOfIdentifierOrLiteral;
|
|
13342
13351
|
function getPropertyNameForUniqueESSymbol(symbol) {
|
|
13343
|
-
return "__@"
|
|
13352
|
+
return "__@".concat(ts.getSymbolId(symbol), "@").concat(symbol.escapedName);
|
|
13344
13353
|
}
|
|
13345
13354
|
ts.getPropertyNameForUniqueESSymbol = getPropertyNameForUniqueESSymbol;
|
|
13346
13355
|
function getSymbolNameForPrivateIdentifier(containingClassSymbol, description) {
|
|
13347
|
-
return "__#"
|
|
13356
|
+
return "__#".concat(ts.getSymbolId(containingClassSymbol), "@").concat(description);
|
|
13348
13357
|
}
|
|
13349
13358
|
ts.getSymbolNameForPrivateIdentifier = getSymbolNameForPrivateIdentifier;
|
|
13350
13359
|
function isKnownSymbol(symbol) {
|
|
@@ -15634,7 +15643,7 @@ var ts;
|
|
|
15634
15643
|
}
|
|
15635
15644
|
ts.getJSXImplicitImportBase = getJSXImplicitImportBase;
|
|
15636
15645
|
function getJSXRuntimeImport(base, options) {
|
|
15637
|
-
return base ? base
|
|
15646
|
+
return base ? "".concat(base, "/").concat(options.jsx === 5 ? "jsx-dev-runtime" : "jsx-runtime") : undefined;
|
|
15638
15647
|
}
|
|
15639
15648
|
ts.getJSXRuntimeImport = getJSXRuntimeImport;
|
|
15640
15649
|
function hasZeroOrOneAsteriskCharacter(str) {
|
|
@@ -15742,15 +15751,15 @@ var ts;
|
|
|
15742
15751
|
}
|
|
15743
15752
|
var wildcardCharCodes = [42, 63];
|
|
15744
15753
|
ts.commonPackageFolders = ["node_modules", "bower_components", "jspm_packages"];
|
|
15745
|
-
var implicitExcludePathRegexPattern = "(?!("
|
|
15754
|
+
var implicitExcludePathRegexPattern = "(?!(".concat(ts.commonPackageFolders.join("|"), ")(/|$))");
|
|
15746
15755
|
var filesMatcher = {
|
|
15747
15756
|
singleAsteriskRegexFragment: "([^./]|(\\.(?!min\\.js$))?)*",
|
|
15748
|
-
doubleAsteriskRegexFragment: "(/"
|
|
15757
|
+
doubleAsteriskRegexFragment: "(/".concat(implicitExcludePathRegexPattern, "[^/.][^/]*)*?"),
|
|
15749
15758
|
replaceWildcardCharacter: function (match) { return replaceWildcardCharacter(match, filesMatcher.singleAsteriskRegexFragment); }
|
|
15750
15759
|
};
|
|
15751
15760
|
var directoriesMatcher = {
|
|
15752
15761
|
singleAsteriskRegexFragment: "[^/]*",
|
|
15753
|
-
doubleAsteriskRegexFragment: "(/"
|
|
15762
|
+
doubleAsteriskRegexFragment: "(/".concat(implicitExcludePathRegexPattern, "[^/.][^/]*)*?"),
|
|
15754
15763
|
replaceWildcardCharacter: function (match) { return replaceWildcardCharacter(match, directoriesMatcher.singleAsteriskRegexFragment); }
|
|
15755
15764
|
};
|
|
15756
15765
|
var excludeMatcher = {
|
|
@@ -15768,9 +15777,9 @@ var ts;
|
|
|
15768
15777
|
if (!patterns || !patterns.length) {
|
|
15769
15778
|
return undefined;
|
|
15770
15779
|
}
|
|
15771
|
-
var pattern = patterns.map(function (pattern) { return "("
|
|
15780
|
+
var pattern = patterns.map(function (pattern) { return "(".concat(pattern, ")"); }).join("|");
|
|
15772
15781
|
var terminator = usage === "exclude" ? "($|/)" : "$";
|
|
15773
|
-
return "^("
|
|
15782
|
+
return "^(".concat(pattern, ")").concat(terminator);
|
|
15774
15783
|
}
|
|
15775
15784
|
ts.getRegularExpressionForWildcard = getRegularExpressionForWildcard;
|
|
15776
15785
|
function getRegularExpressionsForWildcards(specs, basePath, usage) {
|
|
@@ -15788,7 +15797,7 @@ var ts;
|
|
|
15788
15797
|
ts.isImplicitGlob = isImplicitGlob;
|
|
15789
15798
|
function getPatternFromSpec(spec, basePath, usage) {
|
|
15790
15799
|
var pattern = spec && getSubPatternFromSpec(spec, basePath, usage, wildcardMatchers[usage]);
|
|
15791
|
-
return pattern && "^("
|
|
15800
|
+
return pattern && "^(".concat(pattern, ")").concat(usage === "exclude" ? "($|/)" : "$");
|
|
15792
15801
|
}
|
|
15793
15802
|
ts.getPatternFromSpec = getPatternFromSpec;
|
|
15794
15803
|
function getSubPatternFromSpec(spec, basePath, usage, _a) {
|
|
@@ -15854,11 +15863,11 @@ var ts;
|
|
|
15854
15863
|
currentDirectory = ts.normalizePath(currentDirectory);
|
|
15855
15864
|
var absolutePath = ts.combinePaths(currentDirectory, path);
|
|
15856
15865
|
return {
|
|
15857
|
-
includeFilePatterns: ts.map(getRegularExpressionsForWildcards(includes, absolutePath, "files"), function (pattern) { return "^"
|
|
15866
|
+
includeFilePatterns: ts.map(getRegularExpressionsForWildcards(includes, absolutePath, "files"), function (pattern) { return "^".concat(pattern, "$"); }),
|
|
15858
15867
|
includeFilePattern: getRegularExpressionForWildcard(includes, absolutePath, "files"),
|
|
15859
15868
|
includeDirectoryPattern: getRegularExpressionForWildcard(includes, absolutePath, "directories"),
|
|
15860
15869
|
excludePattern: getRegularExpressionForWildcard(excludes, absolutePath, "exclude"),
|
|
15861
|
-
basePaths: getBasePaths(
|
|
15870
|
+
basePaths: getBasePaths(path, includes, useCaseSensitiveFileNames)
|
|
15862
15871
|
};
|
|
15863
15872
|
}
|
|
15864
15873
|
ts.getFileMatcherPatterns = getFileMatcherPatterns;
|
|
@@ -15866,7 +15875,7 @@ var ts;
|
|
|
15866
15875
|
return new RegExp(pattern, useCaseSensitiveFileNames ? "" : "i");
|
|
15867
15876
|
}
|
|
15868
15877
|
ts.getRegexFromPattern = getRegexFromPattern;
|
|
15869
|
-
function matchFiles(path, extensions, excludes, includes, useCaseSensitiveFileNames, currentDirectory, depth, getFileSystemEntries, realpath
|
|
15878
|
+
function matchFiles(path, extensions, excludes, includes, useCaseSensitiveFileNames, currentDirectory, depth, getFileSystemEntries, realpath) {
|
|
15870
15879
|
path = ts.normalizePath(path);
|
|
15871
15880
|
currentDirectory = ts.normalizePath(currentDirectory);
|
|
15872
15881
|
var patterns = getFileMatcherPatterns(path, excludes, includes, useCaseSensitiveFileNames, currentDirectory);
|
|
@@ -15877,20 +15886,18 @@ var ts;
|
|
|
15877
15886
|
var visited = new ts.Map();
|
|
15878
15887
|
var toCanonical = ts.createGetCanonicalFileName(useCaseSensitiveFileNames);
|
|
15879
15888
|
for (var _i = 0, _a = patterns.basePaths; _i < _a.length; _i++) {
|
|
15880
|
-
var
|
|
15881
|
-
|
|
15882
|
-
visitDirectory(absoluteBasePath, depth);
|
|
15883
|
-
}
|
|
15889
|
+
var basePath = _a[_i];
|
|
15890
|
+
visitDirectory(basePath, ts.combinePaths(currentDirectory, basePath), depth);
|
|
15884
15891
|
}
|
|
15885
15892
|
return ts.flatten(results);
|
|
15886
|
-
function visitDirectory(absolutePath, depth) {
|
|
15893
|
+
function visitDirectory(path, absolutePath, depth) {
|
|
15887
15894
|
var canonicalPath = toCanonical(realpath(absolutePath));
|
|
15888
15895
|
if (visited.has(canonicalPath))
|
|
15889
15896
|
return;
|
|
15890
15897
|
visited.set(canonicalPath, true);
|
|
15891
|
-
var _a = getFileSystemEntries(
|
|
15898
|
+
var _a = getFileSystemEntries(path), files = _a.files, directories = _a.directories;
|
|
15892
15899
|
var _loop_1 = function (current) {
|
|
15893
|
-
var name = ts.combinePaths(
|
|
15900
|
+
var name = ts.combinePaths(path, current);
|
|
15894
15901
|
var absoluteName = ts.combinePaths(absolutePath, current);
|
|
15895
15902
|
if (extensions && !ts.fileExtensionIsOneOf(name, extensions))
|
|
15896
15903
|
return "continue";
|
|
@@ -15918,27 +15925,28 @@ var ts;
|
|
|
15918
15925
|
}
|
|
15919
15926
|
for (var _c = 0, _d = ts.sort(directories, ts.compareStringsCaseSensitive); _c < _d.length; _c++) {
|
|
15920
15927
|
var current = _d[_c];
|
|
15928
|
+
var name = ts.combinePaths(path, current);
|
|
15921
15929
|
var absoluteName = ts.combinePaths(absolutePath, current);
|
|
15922
15930
|
if ((!includeDirectoryRegex || includeDirectoryRegex.test(absoluteName)) &&
|
|
15923
15931
|
(!excludeRegex || !excludeRegex.test(absoluteName))) {
|
|
15924
|
-
visitDirectory(absoluteName, depth);
|
|
15932
|
+
visitDirectory(name, absoluteName, depth);
|
|
15925
15933
|
}
|
|
15926
15934
|
}
|
|
15927
15935
|
}
|
|
15928
15936
|
}
|
|
15929
15937
|
ts.matchFiles = matchFiles;
|
|
15930
|
-
function getBasePaths(
|
|
15931
|
-
var basePaths = [
|
|
15938
|
+
function getBasePaths(path, includes, useCaseSensitiveFileNames) {
|
|
15939
|
+
var basePaths = [path];
|
|
15932
15940
|
if (includes) {
|
|
15933
15941
|
var includeBasePaths = [];
|
|
15934
15942
|
for (var _i = 0, includes_1 = includes; _i < includes_1.length; _i++) {
|
|
15935
15943
|
var include = includes_1[_i];
|
|
15936
|
-
var
|
|
15937
|
-
includeBasePaths.push(getIncludeBasePath(
|
|
15944
|
+
var absolute = ts.isRootedDiskPath(include) ? include : ts.normalizePath(ts.combinePaths(path, include));
|
|
15945
|
+
includeBasePaths.push(getIncludeBasePath(absolute));
|
|
15938
15946
|
}
|
|
15939
15947
|
includeBasePaths.sort(ts.getStringComparer(!useCaseSensitiveFileNames));
|
|
15940
15948
|
var _loop_2 = function (includeBasePath) {
|
|
15941
|
-
if (ts.every(basePaths, function (basePath) { return !ts.containsPath(basePath, includeBasePath,
|
|
15949
|
+
if (ts.every(basePaths, function (basePath) { return !ts.containsPath(basePath, includeBasePath, path, !useCaseSensitiveFileNames); })) {
|
|
15942
15950
|
basePaths.push(includeBasePath);
|
|
15943
15951
|
}
|
|
15944
15952
|
};
|
|
@@ -16100,7 +16108,7 @@ var ts;
|
|
|
16100
16108
|
ts.resolutionExtensionIsTSOrJson = resolutionExtensionIsTSOrJson;
|
|
16101
16109
|
function extensionFromPath(path) {
|
|
16102
16110
|
var ext = tryGetExtensionFromPath(path);
|
|
16103
|
-
return ext !== undefined ? ext : ts.Debug.fail("File "
|
|
16111
|
+
return ext !== undefined ? ext : ts.Debug.fail("File ".concat(path, " has unknown extension."));
|
|
16104
16112
|
}
|
|
16105
16113
|
ts.extensionFromPath = extensionFromPath;
|
|
16106
16114
|
function isAnySupportedFileExtension(path) {
|
|
@@ -21110,7 +21118,7 @@ var ts;
|
|
|
21110
21118
|
case 326: return "augments";
|
|
21111
21119
|
case 327: return "implements";
|
|
21112
21120
|
default:
|
|
21113
|
-
return ts.Debug.fail("Unsupported kind: "
|
|
21121
|
+
return ts.Debug.fail("Unsupported kind: ".concat(ts.Debug.formatSyntaxKind(kind)));
|
|
21114
21122
|
}
|
|
21115
21123
|
}
|
|
21116
21124
|
var rawTextScanner;
|
|
@@ -21429,7 +21437,7 @@ var ts;
|
|
|
21429
21437
|
};
|
|
21430
21438
|
var definedTextGetter_1 = function (path) {
|
|
21431
21439
|
var result = textGetter_1(path);
|
|
21432
|
-
return result !== undefined ? result : "/* Input file "
|
|
21440
|
+
return result !== undefined ? result : "/* Input file ".concat(path, " was missing */\r\n");
|
|
21433
21441
|
};
|
|
21434
21442
|
var buildInfo_1;
|
|
21435
21443
|
var getAndCacheBuildInfo_1 = function (getText) {
|
|
@@ -25091,7 +25099,7 @@ var ts;
|
|
|
25091
25099
|
for (var _i = 0, viableKeywordSuggestions_1 = viableKeywordSuggestions; _i < viableKeywordSuggestions_1.length; _i++) {
|
|
25092
25100
|
var keyword = viableKeywordSuggestions_1[_i];
|
|
25093
25101
|
if (expressionText.length > keyword.length + 2 && ts.startsWith(expressionText, keyword)) {
|
|
25094
|
-
return keyword
|
|
25102
|
+
return "".concat(keyword, " ").concat(expressionText.slice(keyword.length));
|
|
25095
25103
|
}
|
|
25096
25104
|
}
|
|
25097
25105
|
return undefined;
|
|
@@ -30595,7 +30603,7 @@ var ts;
|
|
|
30595
30603
|
if (namedArgRegExCache.has(name)) {
|
|
30596
30604
|
return namedArgRegExCache.get(name);
|
|
30597
30605
|
}
|
|
30598
|
-
var result = new RegExp("(\\s"
|
|
30606
|
+
var result = new RegExp("(\\s".concat(name, "\\s*=\\s*)(?:(?:'([^']*)')|(?:\"([^\"]*)\"))"), "im");
|
|
30599
30607
|
namedArgRegExCache.set(name, result);
|
|
30600
30608
|
return result;
|
|
30601
30609
|
}
|
|
@@ -31989,8 +31997,8 @@ var ts;
|
|
|
31989
31997
|
}
|
|
31990
31998
|
ts.createCompilerDiagnosticForInvalidCustomType = createCompilerDiagnosticForInvalidCustomType;
|
|
31991
31999
|
function createDiagnosticForInvalidCustomType(opt, createDiagnostic) {
|
|
31992
|
-
var namesOfType = ts.arrayFrom(opt.type.keys()).map(function (key) { return "'"
|
|
31993
|
-
return createDiagnostic(ts.Diagnostics.Argument_for_0_option_must_be_Colon_1, "--"
|
|
32000
|
+
var namesOfType = ts.arrayFrom(opt.type.keys()).map(function (key) { return "'".concat(key, "'"); }).join(", ");
|
|
32001
|
+
return createDiagnostic(ts.Diagnostics.Argument_for_0_option_must_be_Colon_1, "--".concat(opt.name), namesOfType);
|
|
31994
32002
|
}
|
|
31995
32003
|
function parseCustomTypeOption(opt, value, errors) {
|
|
31996
32004
|
return convertJsonOptionOfCustomType(opt, ts.trimString(value || ""), errors);
|
|
@@ -32707,10 +32715,10 @@ var ts;
|
|
|
32707
32715
|
var newValue = compilerOptionsMap.get(cmd.name);
|
|
32708
32716
|
var defaultValue = getDefaultValueForOption(cmd);
|
|
32709
32717
|
if (newValue !== defaultValue) {
|
|
32710
|
-
result.push(""
|
|
32718
|
+
result.push("".concat(tab).concat(cmd.name, ": ").concat(newValue));
|
|
32711
32719
|
}
|
|
32712
32720
|
else if (ts.hasProperty(ts.defaultInitCompilerOptions, cmd.name)) {
|
|
32713
|
-
result.push(""
|
|
32721
|
+
result.push("".concat(tab).concat(cmd.name, ": ").concat(defaultValue));
|
|
32714
32722
|
}
|
|
32715
32723
|
});
|
|
32716
32724
|
return result.join(newLine) + newLine;
|
|
@@ -32748,19 +32756,19 @@ var ts;
|
|
|
32748
32756
|
if (entries.length !== 0) {
|
|
32749
32757
|
entries.push({ value: "" });
|
|
32750
32758
|
}
|
|
32751
|
-
entries.push({ value: "/* "
|
|
32759
|
+
entries.push({ value: "/* ".concat(category, " */") });
|
|
32752
32760
|
for (var _i = 0, options_1 = options; _i < options_1.length; _i++) {
|
|
32753
32761
|
var option = options_1[_i];
|
|
32754
32762
|
var optionName = void 0;
|
|
32755
32763
|
if (compilerOptionsMap.has(option.name)) {
|
|
32756
|
-
optionName = "\""
|
|
32764
|
+
optionName = "\"".concat(option.name, "\": ").concat(JSON.stringify(compilerOptionsMap.get(option.name))).concat((seenKnownKeys += 1) === compilerOptionsMap.size ? "" : ",");
|
|
32757
32765
|
}
|
|
32758
32766
|
else {
|
|
32759
|
-
optionName = "// \""
|
|
32767
|
+
optionName = "// \"".concat(option.name, "\": ").concat(JSON.stringify(getDefaultValueForOption(option)), ",");
|
|
32760
32768
|
}
|
|
32761
32769
|
entries.push({
|
|
32762
32770
|
value: optionName,
|
|
32763
|
-
description: "/* "
|
|
32771
|
+
description: "/* ".concat(option.description && ts.getLocaleSpecificMessage(option.description) || option.name, " */")
|
|
32764
32772
|
});
|
|
32765
32773
|
marginLength = Math.max(optionName.length, marginLength);
|
|
32766
32774
|
}
|
|
@@ -32768,24 +32776,24 @@ var ts;
|
|
|
32768
32776
|
var tab = makePadding(2);
|
|
32769
32777
|
var result = [];
|
|
32770
32778
|
result.push("{");
|
|
32771
|
-
result.push(tab
|
|
32772
|
-
result.push(""
|
|
32779
|
+
result.push("".concat(tab, "\"compilerOptions\": {"));
|
|
32780
|
+
result.push("".concat(tab).concat(tab, "/* ").concat(ts.getLocaleSpecificMessage(ts.Diagnostics.Visit_https_Colon_Slash_Slashaka_ms_Slashtsconfig_json_to_read_more_about_this_file), " */"));
|
|
32773
32781
|
result.push("");
|
|
32774
32782
|
for (var _a = 0, entries_2 = entries; _a < entries_2.length; _a++) {
|
|
32775
32783
|
var entry = entries_2[_a];
|
|
32776
32784
|
var value = entry.value, _b = entry.description, description = _b === void 0 ? "" : _b;
|
|
32777
|
-
result.push(value && ""
|
|
32785
|
+
result.push(value && "".concat(tab).concat(tab).concat(value).concat(description && (makePadding(marginLength - value.length + 2) + description)));
|
|
32778
32786
|
}
|
|
32779
32787
|
if (fileNames.length) {
|
|
32780
|
-
result.push(tab
|
|
32781
|
-
result.push(tab
|
|
32788
|
+
result.push("".concat(tab, "},"));
|
|
32789
|
+
result.push("".concat(tab, "\"files\": ["));
|
|
32782
32790
|
for (var i = 0; i < fileNames.length; i++) {
|
|
32783
|
-
result.push(""
|
|
32791
|
+
result.push("".concat(tab).concat(tab).concat(JSON.stringify(fileNames[i])).concat(i === fileNames.length - 1 ? "" : ","));
|
|
32784
32792
|
}
|
|
32785
|
-
result.push(tab
|
|
32793
|
+
result.push("".concat(tab, "]"));
|
|
32786
32794
|
}
|
|
32787
32795
|
else {
|
|
32788
|
-
result.push(tab
|
|
32796
|
+
result.push("".concat(tab, "}"));
|
|
32789
32797
|
}
|
|
32790
32798
|
result.push("}");
|
|
32791
32799
|
return result.join(newLine) + newLine;
|
|
@@ -33135,7 +33143,7 @@ var ts;
|
|
|
33135
33143
|
if (ts.isRootedDiskPath(extendedConfig) || ts.startsWith(extendedConfig, "./") || ts.startsWith(extendedConfig, "../")) {
|
|
33136
33144
|
var extendedConfigPath = ts.getNormalizedAbsolutePath(extendedConfig, basePath);
|
|
33137
33145
|
if (!host.fileExists(extendedConfigPath) && !ts.endsWith(extendedConfigPath, ".json")) {
|
|
33138
|
-
extendedConfigPath = extendedConfigPath
|
|
33146
|
+
extendedConfigPath = "".concat(extendedConfigPath, ".json");
|
|
33139
33147
|
if (!host.fileExists(extendedConfigPath)) {
|
|
33140
33148
|
errors.push(createDiagnostic(ts.Diagnostics.File_0_not_found, extendedConfig));
|
|
33141
33149
|
return undefined;
|
|
@@ -33331,7 +33339,7 @@ var ts;
|
|
|
33331
33339
|
if (ts.fileExtensionIs(file, ".json")) {
|
|
33332
33340
|
if (!jsonOnlyIncludeRegexes) {
|
|
33333
33341
|
var includes = validatedIncludeSpecs.filter(function (s) { return ts.endsWith(s, ".json"); });
|
|
33334
|
-
var includeFilePatterns = ts.map(ts.getRegularExpressionsForWildcards(includes, basePath, "files"), function (pattern) { return "^"
|
|
33342
|
+
var includeFilePatterns = ts.map(ts.getRegularExpressionsForWildcards(includes, basePath, "files"), function (pattern) { return "^".concat(pattern, "$"); });
|
|
33335
33343
|
jsonOnlyIncludeRegexes = includeFilePatterns ? includeFilePatterns.map(function (pattern) { return ts.getRegexFromPattern(pattern, host.useCaseSensitiveFileNames); }) : ts.emptyArray;
|
|
33336
33344
|
}
|
|
33337
33345
|
var includeIndex = ts.findIndex(jsonOnlyIncludeRegexes, function (re) { return re.test(file); });
|
|
@@ -33703,7 +33711,7 @@ var ts;
|
|
|
33703
33711
|
var bestVersionKey = result.version, bestVersionPaths = result.paths;
|
|
33704
33712
|
if (typeof bestVersionPaths !== "object") {
|
|
33705
33713
|
if (state.traceEnabled) {
|
|
33706
|
-
trace(state.host, ts.Diagnostics.Expected_type_of_0_field_in_package_json_to_be_1_got_2, "typesVersions['"
|
|
33714
|
+
trace(state.host, ts.Diagnostics.Expected_type_of_0_field_in_package_json_to_be_1_got_2, "typesVersions['".concat(bestVersionKey, "']"), "object", typeof bestVersionPaths);
|
|
33707
33715
|
}
|
|
33708
33716
|
return;
|
|
33709
33717
|
}
|
|
@@ -33802,7 +33810,10 @@ var ts;
|
|
|
33802
33810
|
}
|
|
33803
33811
|
}
|
|
33804
33812
|
var failedLookupLocations = [];
|
|
33805
|
-
var
|
|
33813
|
+
var features = ts.getEmitModuleResolutionKind(options) === ts.ModuleResolutionKind.Node12 ? NodeResolutionFeatures.Node12Default :
|
|
33814
|
+
ts.getEmitModuleResolutionKind(options) === ts.ModuleResolutionKind.NodeNext ? NodeResolutionFeatures.NodeNextDefault :
|
|
33815
|
+
NodeResolutionFeatures.None;
|
|
33816
|
+
var moduleResolutionState = { compilerOptions: options, host: host, traceEnabled: traceEnabled, failedLookupLocations: failedLookupLocations, packageJsonInfoCache: cache, features: features, conditions: ["node", "require", "types"] };
|
|
33806
33817
|
var resolved = primaryLookup();
|
|
33807
33818
|
var primary = true;
|
|
33808
33819
|
if (!resolved) {
|
|
@@ -34047,7 +34058,7 @@ var ts;
|
|
|
34047
34058
|
};
|
|
34048
34059
|
return cache;
|
|
34049
34060
|
function getUnderlyingCacheKey(specifier, mode) {
|
|
34050
|
-
var result = mode === undefined ? specifier : mode
|
|
34061
|
+
var result = mode === undefined ? specifier : "".concat(mode, "|").concat(specifier);
|
|
34051
34062
|
memoizedReverseKeys.set(result, [specifier, mode]);
|
|
34052
34063
|
return result;
|
|
34053
34064
|
}
|
|
@@ -34077,7 +34088,7 @@ var ts;
|
|
|
34077
34088
|
}
|
|
34078
34089
|
function getOrCreateCacheForModuleName(nonRelativeModuleName, mode, redirectedReference) {
|
|
34079
34090
|
ts.Debug.assert(!ts.isExternalModuleNameRelative(nonRelativeModuleName));
|
|
34080
|
-
return getOrCreateCache(moduleNameToDirectoryMap, redirectedReference, mode === undefined ? nonRelativeModuleName : mode
|
|
34091
|
+
return getOrCreateCache(moduleNameToDirectoryMap, redirectedReference, mode === undefined ? nonRelativeModuleName : "".concat(mode, "|").concat(nonRelativeModuleName), createPerModuleNameCache);
|
|
34081
34092
|
}
|
|
34082
34093
|
function createPerModuleNameCache() {
|
|
34083
34094
|
var directoryPathMap = new ts.Map();
|
|
@@ -34205,10 +34216,10 @@ var ts;
|
|
|
34205
34216
|
result = classicNameResolver(moduleName, containingFile, compilerOptions, host, cache, redirectedReference);
|
|
34206
34217
|
break;
|
|
34207
34218
|
default:
|
|
34208
|
-
return ts.Debug.fail("Unexpected moduleResolution: "
|
|
34219
|
+
return ts.Debug.fail("Unexpected moduleResolution: ".concat(moduleResolution));
|
|
34209
34220
|
}
|
|
34210
34221
|
if (result && result.resolvedModule)
|
|
34211
|
-
ts.perfLogger.logInfoEvent("Module \""
|
|
34222
|
+
ts.perfLogger.logInfoEvent("Module \"".concat(moduleName, "\" resolved to \"").concat(result.resolvedModule.resolvedFileName, "\""));
|
|
34212
34223
|
ts.perfLogger.logStopResolveModule((result && result.resolvedModule) ? "" + result.resolvedModule.resolvedFileName : "null");
|
|
34213
34224
|
if (perFolderCache) {
|
|
34214
34225
|
perFolderCache.set(moduleName, resolutionMode, result);
|
|
@@ -34338,7 +34349,7 @@ var ts;
|
|
|
34338
34349
|
function resolveJSModule(moduleName, initialDir, host) {
|
|
34339
34350
|
var _a = tryResolveJSModuleWorker(moduleName, initialDir, host), resolvedModule = _a.resolvedModule, failedLookupLocations = _a.failedLookupLocations;
|
|
34340
34351
|
if (!resolvedModule) {
|
|
34341
|
-
throw new Error("Could not resolve JS module '"
|
|
34352
|
+
throw new Error("Could not resolve JS module '".concat(moduleName, "' starting at '").concat(initialDir, "'. Looked in: ").concat(failedLookupLocations.join(", ")));
|
|
34342
34353
|
}
|
|
34343
34354
|
return resolvedModule.resolvedFileName;
|
|
34344
34355
|
}
|
|
@@ -34355,13 +34366,15 @@ var ts;
|
|
|
34355
34366
|
NodeResolutionFeatures[NodeResolutionFeatures["Exports"] = 8] = "Exports";
|
|
34356
34367
|
NodeResolutionFeatures[NodeResolutionFeatures["ExportsPatternTrailers"] = 16] = "ExportsPatternTrailers";
|
|
34357
34368
|
NodeResolutionFeatures[NodeResolutionFeatures["AllFeatures"] = 30] = "AllFeatures";
|
|
34369
|
+
NodeResolutionFeatures[NodeResolutionFeatures["Node12Default"] = 14] = "Node12Default";
|
|
34370
|
+
NodeResolutionFeatures[NodeResolutionFeatures["NodeNextDefault"] = 30] = "NodeNextDefault";
|
|
34358
34371
|
NodeResolutionFeatures[NodeResolutionFeatures["EsmMode"] = 32] = "EsmMode";
|
|
34359
34372
|
})(NodeResolutionFeatures || (NodeResolutionFeatures = {}));
|
|
34360
34373
|
function node12ModuleNameResolver(moduleName, containingFile, compilerOptions, host, cache, redirectedReference, resolutionMode) {
|
|
34361
|
-
return nodeNextModuleNameResolverWorker(NodeResolutionFeatures.
|
|
34374
|
+
return nodeNextModuleNameResolverWorker(NodeResolutionFeatures.Node12Default, moduleName, containingFile, compilerOptions, host, cache, redirectedReference, resolutionMode);
|
|
34362
34375
|
}
|
|
34363
34376
|
function nodeNextModuleNameResolver(moduleName, containingFile, compilerOptions, host, cache, redirectedReference, resolutionMode) {
|
|
34364
|
-
return nodeNextModuleNameResolverWorker(NodeResolutionFeatures.
|
|
34377
|
+
return nodeNextModuleNameResolverWorker(NodeResolutionFeatures.NodeNextDefault, moduleName, containingFile, compilerOptions, host, cache, redirectedReference, resolutionMode);
|
|
34365
34378
|
}
|
|
34366
34379
|
function nodeNextModuleNameResolverWorker(features, moduleName, containingFile, compilerOptions, host, cache, redirectedReference, resolutionMode) {
|
|
34367
34380
|
var containingDirectory = ts.getDirectoryPath(containingFile);
|
|
@@ -34439,7 +34452,7 @@ var ts;
|
|
|
34439
34452
|
if (traceEnabled) {
|
|
34440
34453
|
trace(host, ts.Diagnostics.Resolving_real_path_for_0_result_1, path, real);
|
|
34441
34454
|
}
|
|
34442
|
-
ts.Debug.assert(host.fileExists(real), path
|
|
34455
|
+
ts.Debug.assert(host.fileExists(real), "".concat(path, " linked to nonexistent file ").concat(real));
|
|
34443
34456
|
return real;
|
|
34444
34457
|
}
|
|
34445
34458
|
function nodeLoadModuleByRelativeName(extensions, candidate, onlyRecordFailures, state, considerPackageJson) {
|
|
@@ -34786,7 +34799,7 @@ var ts;
|
|
|
34786
34799
|
return undefined;
|
|
34787
34800
|
}
|
|
34788
34801
|
var trailingParts = parts.slice(nameParts.length);
|
|
34789
|
-
return loadModuleFromExports(scope, extensions, !ts.length(trailingParts) ? "." : "."
|
|
34802
|
+
return loadModuleFromExports(scope, extensions, !ts.length(trailingParts) ? "." : ".".concat(ts.directorySeparator).concat(trailingParts.join(ts.directorySeparator)), state, cache, redirectedReference);
|
|
34790
34803
|
}
|
|
34791
34804
|
function loadModuleFromExports(scope, extensions, subpath, state, cache, redirectedReference) {
|
|
34792
34805
|
if (!scope.packageJsonContent.exports) {
|
|
@@ -35098,7 +35111,7 @@ var ts;
|
|
|
35098
35111
|
return mangled;
|
|
35099
35112
|
}
|
|
35100
35113
|
function getTypesPackageName(packageName) {
|
|
35101
|
-
return "@types/"
|
|
35114
|
+
return "@types/".concat(mangleScopedPackageName(packageName));
|
|
35102
35115
|
}
|
|
35103
35116
|
ts.getTypesPackageName = getTypesPackageName;
|
|
35104
35117
|
function mangleScopedPackageName(packageName) {
|
|
@@ -35424,7 +35437,7 @@ var ts;
|
|
|
35424
35437
|
if (name) {
|
|
35425
35438
|
if (ts.isAmbientModule(node)) {
|
|
35426
35439
|
var moduleName = ts.getTextOfIdentifierOrLiteral(name);
|
|
35427
|
-
return (ts.isGlobalScopeAugmentation(node) ? "__global" : "\""
|
|
35440
|
+
return (ts.isGlobalScopeAugmentation(node) ? "__global" : "\"".concat(moduleName, "\""));
|
|
35428
35441
|
}
|
|
35429
35442
|
if (name.kind === 161) {
|
|
35430
35443
|
var nameExpression = name.expression;
|
|
@@ -35473,7 +35486,7 @@ var ts;
|
|
|
35473
35486
|
case 315:
|
|
35474
35487
|
return (ts.isJSDocConstructSignature(node) ? "__new" : "__call");
|
|
35475
35488
|
case 163:
|
|
35476
|
-
ts.Debug.assert(node.parent.kind === 315, "Impossible parameter parent kind", function () { return "parent is: "
|
|
35489
|
+
ts.Debug.assert(node.parent.kind === 315, "Impossible parameter parent kind", function () { return "parent is: ".concat(ts.SyntaxKind ? ts.SyntaxKind[node.parent.kind] : node.parent.kind, ", expected JSDocFunctionType"); });
|
|
35477
35490
|
var functionType = node.parent;
|
|
35478
35491
|
var index = functionType.parameters.indexOf(node);
|
|
35479
35492
|
return "arg" + index;
|
|
@@ -35539,7 +35552,7 @@ var ts;
|
|
|
35539
35552
|
}
|
|
35540
35553
|
var relatedInformation_1 = [];
|
|
35541
35554
|
if (ts.isTypeAliasDeclaration(node) && ts.nodeIsMissing(node.type) && ts.hasSyntacticModifier(node, 1) && symbol.flags & (2097152 | 788968 | 1920)) {
|
|
35542
|
-
relatedInformation_1.push(createDiagnosticForNode(node, ts.Diagnostics.Did_you_mean_0, "export type { "
|
|
35555
|
+
relatedInformation_1.push(createDiagnosticForNode(node, ts.Diagnostics.Did_you_mean_0, "export type { ".concat(ts.unescapeLeadingUnderscores(node.name.escapedText), " }")));
|
|
35543
35556
|
}
|
|
35544
35557
|
var declarationName_1 = ts.getNameOfDeclaration(node) || node;
|
|
35545
35558
|
ts.forEach(symbol.declarations, function (declaration, index) {
|
|
@@ -37358,7 +37371,7 @@ var ts;
|
|
|
37358
37371
|
}
|
|
37359
37372
|
}
|
|
37360
37373
|
function bindSourceFileAsExternalModule() {
|
|
37361
|
-
bindAnonymousDeclaration(file, 512, "\""
|
|
37374
|
+
bindAnonymousDeclaration(file, 512, "\"".concat(ts.removeFileExtension(file.fileName), "\""));
|
|
37362
37375
|
}
|
|
37363
37376
|
function bindExportAssignment(node) {
|
|
37364
37377
|
if (!container.symbol || !container.symbol.exports) {
|
|
@@ -37766,7 +37779,7 @@ var ts;
|
|
|
37766
37779
|
checkStrictModeEvalOrArguments(node, node.name);
|
|
37767
37780
|
}
|
|
37768
37781
|
if (!ts.isBindingPattern(node.name)) {
|
|
37769
|
-
if (ts.isInJSFile(node) && ts.
|
|
37782
|
+
if (ts.isInJSFile(node) && ts.isVariableDeclarationInitializedToBareOrAccessedRequire(node) && !ts.getJSDocTypeTag(node)) {
|
|
37770
37783
|
declareSymbolAndAddToSymbolTable(node, 2097152, 2097152);
|
|
37771
37784
|
}
|
|
37772
37785
|
else if (ts.isBlockOrCatchScoped(node)) {
|
|
@@ -39072,7 +39085,7 @@ var ts;
|
|
|
39072
39085
|
if (sourceSymbolFile && targetSymbolFile && amalgamatedDuplicates && !isEitherEnum && sourceSymbolFile !== targetSymbolFile) {
|
|
39073
39086
|
var firstFile_1 = ts.comparePaths(sourceSymbolFile.path, targetSymbolFile.path) === -1 ? sourceSymbolFile : targetSymbolFile;
|
|
39074
39087
|
var secondFile_1 = firstFile_1 === sourceSymbolFile ? targetSymbolFile : sourceSymbolFile;
|
|
39075
|
-
var filesDuplicates = ts.getOrUpdate(amalgamatedDuplicates, firstFile_1.path
|
|
39088
|
+
var filesDuplicates = ts.getOrUpdate(amalgamatedDuplicates, "".concat(firstFile_1.path, "|").concat(secondFile_1.path), function () {
|
|
39076
39089
|
return ({ firstFile: firstFile_1, secondFile: secondFile_1, conflictingSymbols: new ts.Map() });
|
|
39077
39090
|
});
|
|
39078
39091
|
var conflictingSymbolInfo = ts.getOrUpdate(filesDuplicates.conflictingSymbols, symbolName_1, function () {
|
|
@@ -39438,11 +39451,12 @@ var ts;
|
|
|
39438
39451
|
}
|
|
39439
39452
|
}
|
|
39440
39453
|
}
|
|
39441
|
-
function resolveName(location, name, meaning, nameNotFoundMessage, nameArg, isUse, excludeGlobals) {
|
|
39454
|
+
function resolveName(location, name, meaning, nameNotFoundMessage, nameArg, isUse, excludeGlobals, getSpellingSuggstions) {
|
|
39442
39455
|
if (excludeGlobals === void 0) { excludeGlobals = false; }
|
|
39443
|
-
|
|
39456
|
+
if (getSpellingSuggstions === void 0) { getSpellingSuggstions = true; }
|
|
39457
|
+
return resolveNameHelper(location, name, meaning, nameNotFoundMessage, nameArg, isUse, excludeGlobals, getSpellingSuggstions, getSymbol);
|
|
39444
39458
|
}
|
|
39445
|
-
function resolveNameHelper(location, name, meaning, nameNotFoundMessage, nameArg, isUse, excludeGlobals, lookup) {
|
|
39459
|
+
function resolveNameHelper(location, name, meaning, nameNotFoundMessage, nameArg, isUse, excludeGlobals, getSpellingSuggestions, lookup) {
|
|
39446
39460
|
var _a, _b, _c;
|
|
39447
39461
|
var originalLocation = location;
|
|
39448
39462
|
var result;
|
|
@@ -39677,7 +39691,7 @@ var ts;
|
|
|
39677
39691
|
}
|
|
39678
39692
|
}
|
|
39679
39693
|
if (!result) {
|
|
39680
|
-
if (nameNotFoundMessage) {
|
|
39694
|
+
if (nameNotFoundMessage && produceDiagnostics) {
|
|
39681
39695
|
if (!errorLocation ||
|
|
39682
39696
|
!checkAndReportErrorForMissingPrefix(errorLocation, name, nameArg) &&
|
|
39683
39697
|
!checkAndReportErrorForExtendingInterface(errorLocation) &&
|
|
@@ -39687,7 +39701,7 @@ var ts;
|
|
|
39687
39701
|
!checkAndReportErrorForUsingNamespaceModuleAsValue(errorLocation, name, meaning) &&
|
|
39688
39702
|
!checkAndReportErrorForUsingValueAsType(errorLocation, name, meaning)) {
|
|
39689
39703
|
var suggestion = void 0;
|
|
39690
|
-
if (suggestionCount < maximumSuggestionCount) {
|
|
39704
|
+
if (getSpellingSuggestions && suggestionCount < maximumSuggestionCount) {
|
|
39691
39705
|
suggestion = getSuggestedSymbolForNonexistentSymbol(originalLocation, name, meaning);
|
|
39692
39706
|
var isGlobalScopeAugmentationDeclaration = (suggestion === null || suggestion === void 0 ? void 0 : suggestion.valueDeclaration) && ts.isAmbientModule(suggestion.valueDeclaration) && ts.isGlobalScopeAugmentation(suggestion.valueDeclaration);
|
|
39693
39707
|
if (isGlobalScopeAugmentationDeclaration) {
|
|
@@ -39722,7 +39736,7 @@ var ts;
|
|
|
39722
39736
|
}
|
|
39723
39737
|
return undefined;
|
|
39724
39738
|
}
|
|
39725
|
-
if (nameNotFoundMessage) {
|
|
39739
|
+
if (nameNotFoundMessage && produceDiagnostics) {
|
|
39726
39740
|
if (propertyWithInvalidInitializer && !(ts.getEmitScriptTarget(compilerOptions) === 99 && useDefineForClassFields)) {
|
|
39727
39741
|
var propertyName = propertyWithInvalidInitializer.name;
|
|
39728
39742
|
error(errorLocation, ts.Diagnostics.Initializer_of_instance_member_variable_0_cannot_reference_identifier_1_declared_in_the_constructor, ts.declarationNameToString(propertyName), diagnosticName(nameArg));
|
|
@@ -40040,7 +40054,7 @@ var ts;
|
|
|
40040
40054
|
&& isAliasableOrJsExpression(node.parent.right)
|
|
40041
40055
|
|| node.kind === 295
|
|
40042
40056
|
|| node.kind === 294 && isAliasableOrJsExpression(node.initializer)
|
|
40043
|
-
|| ts.
|
|
40057
|
+
|| ts.isVariableDeclarationInitializedToBareOrAccessedRequire(node);
|
|
40044
40058
|
}
|
|
40045
40059
|
function isAliasableOrJsExpression(e) {
|
|
40046
40060
|
return ts.isAliasableExpression(e) || ts.isFunctionExpression(e) && isJSConstructor(e);
|
|
@@ -40896,7 +40910,7 @@ var ts;
|
|
|
40896
40910
|
if (!sigs || !sigs.length) {
|
|
40897
40911
|
sigs = getSignaturesOfStructuredType(type, 1);
|
|
40898
40912
|
}
|
|
40899
|
-
if ((sigs && sigs.length) || getPropertyOfType(type, "default")) {
|
|
40913
|
+
if ((sigs && sigs.length) || getPropertyOfType(type, "default", true)) {
|
|
40900
40914
|
var moduleType = getTypeWithSyntheticDefaultImportType(type, symbol, moduleSymbol, reference);
|
|
40901
40915
|
return cloneTypeAsModuleType(symbol, moduleType, referenceParent);
|
|
40902
40916
|
}
|
|
@@ -41345,7 +41359,7 @@ var ts;
|
|
|
41345
41359
|
var links = getSymbolLinks(symbol);
|
|
41346
41360
|
var cache = (links.accessibleChainCache || (links.accessibleChainCache = new ts.Map()));
|
|
41347
41361
|
var firstRelevantLocation = forEachSymbolTableInScope(enclosingDeclaration, function (_, __, ___, node) { return node; });
|
|
41348
|
-
var key = (useOnlyExternalAliasing ? 0 : 1
|
|
41362
|
+
var key = "".concat(useOnlyExternalAliasing ? 0 : 1, "|").concat(firstRelevantLocation && getNodeId(firstRelevantLocation), "|").concat(meaning);
|
|
41349
41363
|
if (cache.has(key)) {
|
|
41350
41364
|
return cache.get(key);
|
|
41351
41365
|
}
|
|
@@ -42112,7 +42126,7 @@ var ts;
|
|
|
42112
42126
|
context.symbolDepth = new ts.Map();
|
|
42113
42127
|
}
|
|
42114
42128
|
var links = context.enclosingDeclaration && getNodeLinks(context.enclosingDeclaration);
|
|
42115
|
-
var key = getTypeId(type)
|
|
42129
|
+
var key = "".concat(getTypeId(type), "|").concat(context.flags);
|
|
42116
42130
|
if (links) {
|
|
42117
42131
|
links.serializedTypes || (links.serializedTypes = new ts.Map());
|
|
42118
42132
|
}
|
|
@@ -42367,7 +42381,7 @@ var ts;
|
|
|
42367
42381
|
}
|
|
42368
42382
|
}
|
|
42369
42383
|
if (checkTruncationLength(context) && (i + 2 < properties.length - 1)) {
|
|
42370
|
-
typeElements.push(ts.factory.createPropertySignature(undefined, "... "
|
|
42384
|
+
typeElements.push(ts.factory.createPropertySignature(undefined, "... ".concat(properties.length - i, " more ..."), undefined, undefined));
|
|
42371
42385
|
addPropertyToElementList(properties[properties.length - 1], context, typeElements);
|
|
42372
42386
|
break;
|
|
42373
42387
|
}
|
|
@@ -42475,7 +42489,7 @@ var ts;
|
|
|
42475
42489
|
else if (types.length > 2) {
|
|
42476
42490
|
return [
|
|
42477
42491
|
typeToTypeNodeHelper(types[0], context),
|
|
42478
|
-
ts.factory.createTypeReferenceNode("... "
|
|
42492
|
+
ts.factory.createTypeReferenceNode("... ".concat(types.length - 2, " more ..."), undefined),
|
|
42479
42493
|
typeToTypeNodeHelper(types[types.length - 1], context)
|
|
42480
42494
|
];
|
|
42481
42495
|
}
|
|
@@ -42488,7 +42502,7 @@ var ts;
|
|
|
42488
42502
|
var type = types_2[_i];
|
|
42489
42503
|
i++;
|
|
42490
42504
|
if (checkTruncationLength(context) && (i + 2 < types.length - 1)) {
|
|
42491
|
-
result_5.push(ts.factory.createTypeReferenceNode("... "
|
|
42505
|
+
result_5.push(ts.factory.createTypeReferenceNode("... ".concat(types.length - i, " more ..."), undefined));
|
|
42492
42506
|
var typeNode_1 = typeToTypeNodeHelper(types[types.length - 1], context);
|
|
42493
42507
|
if (typeNode_1) {
|
|
42494
42508
|
result_5.push(typeNode_1);
|
|
@@ -42953,7 +42967,7 @@ var ts;
|
|
|
42953
42967
|
var text = rawtext;
|
|
42954
42968
|
while (((_b = context.typeParameterNamesByText) === null || _b === void 0 ? void 0 : _b.has(text)) || typeParameterShadowsNameInScope(text, context, type)) {
|
|
42955
42969
|
i++;
|
|
42956
|
-
text = rawtext
|
|
42970
|
+
text = "".concat(rawtext, "_").concat(i);
|
|
42957
42971
|
}
|
|
42958
42972
|
if (text !== rawtext) {
|
|
42959
42973
|
result = ts.factory.createIdentifier(text, result.typeArguments);
|
|
@@ -43241,7 +43255,7 @@ var ts;
|
|
|
43241
43255
|
function getNameForJSDocFunctionParameter(p, index) {
|
|
43242
43256
|
return p.name && ts.isIdentifier(p.name) && p.name.escapedText === "this" ? "this"
|
|
43243
43257
|
: getEffectiveDotDotDotForParameter(p) ? "args"
|
|
43244
|
-
: "arg"
|
|
43258
|
+
: "arg".concat(index);
|
|
43245
43259
|
}
|
|
43246
43260
|
function rewriteModuleSpecifier(parent, lit) {
|
|
43247
43261
|
if (bundled) {
|
|
@@ -44050,7 +44064,7 @@ var ts;
|
|
|
44050
44064
|
}
|
|
44051
44065
|
return results_1;
|
|
44052
44066
|
}
|
|
44053
|
-
return ts.Debug.fail("Unhandled class member kind! "
|
|
44067
|
+
return ts.Debug.fail("Unhandled class member kind! ".concat(p.__debugFlags || p.flags));
|
|
44054
44068
|
};
|
|
44055
44069
|
}
|
|
44056
44070
|
function serializePropertySymbolForInterface(p, baseType) {
|
|
@@ -44120,7 +44134,7 @@ var ts;
|
|
|
44120
44134
|
if (ref) {
|
|
44121
44135
|
return ref;
|
|
44122
44136
|
}
|
|
44123
|
-
var tempName = getUnusedName(rootName
|
|
44137
|
+
var tempName = getUnusedName("".concat(rootName, "_base"));
|
|
44124
44138
|
var statement = ts.factory.createVariableStatement(undefined, ts.factory.createVariableDeclarationList([
|
|
44125
44139
|
ts.factory.createVariableDeclaration(tempName, undefined, typeToTypeNodeHelper(staticType, context))
|
|
44126
44140
|
], 2));
|
|
@@ -44165,7 +44179,7 @@ var ts;
|
|
|
44165
44179
|
var original = input;
|
|
44166
44180
|
while ((_a = context.usedSymbolNames) === null || _a === void 0 ? void 0 : _a.has(input)) {
|
|
44167
44181
|
i++;
|
|
44168
|
-
input = original
|
|
44182
|
+
input = "".concat(original, "_").concat(i);
|
|
44169
44183
|
}
|
|
44170
44184
|
(_b = context.usedSymbolNames) === null || _b === void 0 ? void 0 : _b.add(input);
|
|
44171
44185
|
if (id) {
|
|
@@ -44271,15 +44285,15 @@ var ts;
|
|
|
44271
44285
|
if (nameType.flags & 384) {
|
|
44272
44286
|
var name = "" + nameType.value;
|
|
44273
44287
|
if (!ts.isIdentifierText(name, ts.getEmitScriptTarget(compilerOptions)) && !isNumericLiteralName(name)) {
|
|
44274
|
-
return "\""
|
|
44288
|
+
return "\"".concat(ts.escapeString(name, 34), "\"");
|
|
44275
44289
|
}
|
|
44276
44290
|
if (isNumericLiteralName(name) && ts.startsWith(name, "-")) {
|
|
44277
|
-
return "["
|
|
44291
|
+
return "[".concat(name, "]");
|
|
44278
44292
|
}
|
|
44279
44293
|
return name;
|
|
44280
44294
|
}
|
|
44281
44295
|
if (nameType.flags & 8192) {
|
|
44282
|
-
return "["
|
|
44296
|
+
return "[".concat(getNameOfSymbolAsWritten(nameType.symbol, context), "]");
|
|
44283
44297
|
}
|
|
44284
44298
|
}
|
|
44285
44299
|
}
|
|
@@ -46678,7 +46692,7 @@ var ts;
|
|
|
46678
46692
|
!leftName ? rightName :
|
|
46679
46693
|
!rightName ? leftName :
|
|
46680
46694
|
undefined;
|
|
46681
|
-
var paramSymbol = createSymbol(1 | (isOptional && !isRestParam ? 16777216 : 0), paramName || "arg"
|
|
46695
|
+
var paramSymbol = createSymbol(1 | (isOptional && !isRestParam ? 16777216 : 0), paramName || "arg".concat(i));
|
|
46682
46696
|
paramSymbol.type = isRestParam ? createArrayType(unionParamType) : unionParamType;
|
|
46683
46697
|
params[i] = paramSymbol;
|
|
46684
46698
|
}
|
|
@@ -48363,7 +48377,7 @@ var ts;
|
|
|
48363
48377
|
return result;
|
|
48364
48378
|
}
|
|
48365
48379
|
function getAliasId(aliasSymbol, aliasTypeArguments) {
|
|
48366
|
-
return aliasSymbol ? "@"
|
|
48380
|
+
return aliasSymbol ? "@".concat(getSymbolId(aliasSymbol)) + (aliasTypeArguments ? ":".concat(getTypeListId(aliasTypeArguments)) : "") : "";
|
|
48367
48381
|
}
|
|
48368
48382
|
function getPropagatingFlagsOfTypes(types, excludeKinds) {
|
|
48369
48383
|
var result = 0;
|
|
@@ -48526,7 +48540,7 @@ var ts;
|
|
|
48526
48540
|
return undefined;
|
|
48527
48541
|
}
|
|
48528
48542
|
function getSymbolPath(symbol) {
|
|
48529
|
-
return symbol.parent ? getSymbolPath(symbol.parent)
|
|
48543
|
+
return symbol.parent ? "".concat(getSymbolPath(symbol.parent), ".").concat(symbol.escapedName) : symbol.escapedName;
|
|
48530
48544
|
}
|
|
48531
48545
|
function getUnresolvedSymbolForEntityName(name) {
|
|
48532
48546
|
var identifier = name.kind === 160 ? name.right :
|
|
@@ -48537,7 +48551,7 @@ var ts;
|
|
|
48537
48551
|
var parentSymbol = name.kind === 160 ? getUnresolvedSymbolForEntityName(name.left) :
|
|
48538
48552
|
name.kind === 205 ? getUnresolvedSymbolForEntityName(name.expression) :
|
|
48539
48553
|
undefined;
|
|
48540
|
-
var path = parentSymbol ? getSymbolPath(parentSymbol)
|
|
48554
|
+
var path = parentSymbol ? "".concat(getSymbolPath(parentSymbol), ".").concat(text) : text;
|
|
48541
48555
|
var result = unresolvedSymbols.get(path);
|
|
48542
48556
|
if (!result) {
|
|
48543
48557
|
unresolvedSymbols.set(path, result = createSymbol(524288, text, 1048576));
|
|
@@ -48603,7 +48617,7 @@ var ts;
|
|
|
48603
48617
|
if (substitute.flags & 3 || substitute === baseType) {
|
|
48604
48618
|
return baseType;
|
|
48605
48619
|
}
|
|
48606
|
-
var id = getTypeId(baseType)
|
|
48620
|
+
var id = "".concat(getTypeId(baseType), ">").concat(getTypeId(substitute));
|
|
48607
48621
|
var cached = substitutionTypes.get(id);
|
|
48608
48622
|
if (cached) {
|
|
48609
48623
|
return cached;
|
|
@@ -48790,7 +48804,7 @@ var ts;
|
|
|
48790
48804
|
return symbol;
|
|
48791
48805
|
}
|
|
48792
48806
|
function getGlobalSymbol(name, meaning, diagnostic) {
|
|
48793
|
-
return resolveName(undefined, name, meaning, diagnostic, name, false);
|
|
48807
|
+
return resolveName(undefined, name, meaning, diagnostic, name, false, false, false);
|
|
48794
48808
|
}
|
|
48795
48809
|
function getGlobalType(name, arity, reportErrors) {
|
|
48796
48810
|
var symbol = getGlobalTypeSymbol(name, reportErrors);
|
|
@@ -49208,6 +49222,8 @@ var ts;
|
|
|
49208
49222
|
}
|
|
49209
49223
|
if (!(flags & 131072)) {
|
|
49210
49224
|
includes |= flags & 205258751;
|
|
49225
|
+
if (flags & 465829888)
|
|
49226
|
+
includes |= 33554432;
|
|
49211
49227
|
if (type === wildcardType)
|
|
49212
49228
|
includes |= 8388608;
|
|
49213
49229
|
if (!strictNullChecks && flags & 98304) {
|
|
@@ -49400,7 +49416,7 @@ var ts;
|
|
|
49400
49416
|
origin = createOriginUnionOrIntersectionType(1048576, reducedTypes);
|
|
49401
49417
|
}
|
|
49402
49418
|
}
|
|
49403
|
-
var objectFlags = (includes &
|
|
49419
|
+
var objectFlags = (includes & 36323363 ? 0 : 65536) |
|
|
49404
49420
|
(includes & 2097152 ? 33554432 : 0);
|
|
49405
49421
|
return getUnionTypeFromSortedList(typeSet, objectFlags, aliasSymbol, aliasTypeArguments, origin);
|
|
49406
49422
|
}
|
|
@@ -49445,9 +49461,9 @@ var ts;
|
|
|
49445
49461
|
return types[0];
|
|
49446
49462
|
}
|
|
49447
49463
|
var typeKey = !origin ? getTypeListId(types) :
|
|
49448
|
-
origin.flags & 1048576 ? "|"
|
|
49449
|
-
origin.flags & 2097152 ? "&"
|
|
49450
|
-
"#"
|
|
49464
|
+
origin.flags & 1048576 ? "|".concat(getTypeListId(origin.types)) :
|
|
49465
|
+
origin.flags & 2097152 ? "&".concat(getTypeListId(origin.types)) :
|
|
49466
|
+
"#".concat(origin.type.id, "|").concat(getTypeListId(types));
|
|
49451
49467
|
var id = typeKey + getAliasId(aliasSymbol, aliasTypeArguments);
|
|
49452
49468
|
var type = unionTypes.get(id);
|
|
49453
49469
|
if (!type) {
|
|
@@ -49897,7 +49913,7 @@ var ts;
|
|
|
49897
49913
|
if (ts.every(newTexts, function (t) { return t === ""; }) && ts.every(newTypes, function (t) { return !!(t.flags & 4); })) {
|
|
49898
49914
|
return stringType;
|
|
49899
49915
|
}
|
|
49900
|
-
var id = getTypeListId(newTypes)
|
|
49916
|
+
var id = "".concat(getTypeListId(newTypes), "|").concat(ts.map(newTexts, function (t) { return t.length; }).join(","), "|").concat(newTexts.join(""));
|
|
49901
49917
|
var type = templateLiteralTypes.get(id);
|
|
49902
49918
|
if (!type) {
|
|
49903
49919
|
templateLiteralTypes.set(id, type = createTemplateLiteralType(newTexts, newTypes));
|
|
@@ -49957,7 +49973,7 @@ var ts;
|
|
|
49957
49973
|
return str;
|
|
49958
49974
|
}
|
|
49959
49975
|
function getStringMappingTypeForGenericType(symbol, type) {
|
|
49960
|
-
var id = getSymbolId(symbol)
|
|
49976
|
+
var id = "".concat(getSymbolId(symbol), ",").concat(getTypeId(type));
|
|
49961
49977
|
var result = stringMappingTypes.get(id);
|
|
49962
49978
|
if (!result) {
|
|
49963
49979
|
stringMappingTypes.set(id, result = createStringMappingType(symbol, type));
|
|
@@ -50868,7 +50884,7 @@ var ts;
|
|
|
50868
50884
|
function createUniqueESSymbolType(symbol) {
|
|
50869
50885
|
var type = createType(8192);
|
|
50870
50886
|
type.symbol = symbol;
|
|
50871
|
-
type.escapedName = "__@"
|
|
50887
|
+
type.escapedName = "__@".concat(type.symbol.escapedName, "@").concat(getSymbolId(type.symbol));
|
|
50872
50888
|
return type;
|
|
50873
50889
|
}
|
|
50874
50890
|
function getESSymbolLikeTypeForNode(node) {
|
|
@@ -52260,7 +52276,7 @@ var ts;
|
|
|
52260
52276
|
return true;
|
|
52261
52277
|
}
|
|
52262
52278
|
if (source.flags & 524288 && target.flags & 524288) {
|
|
52263
|
-
var related = relation.get(getRelationKey(source, target, 0, relation));
|
|
52279
|
+
var related = relation.get(getRelationKey(source, target, 0, relation, false));
|
|
52264
52280
|
if (related !== undefined) {
|
|
52265
52281
|
return !!(related & 1);
|
|
52266
52282
|
}
|
|
@@ -52389,20 +52405,20 @@ var ts;
|
|
|
52389
52405
|
switch (msg.code) {
|
|
52390
52406
|
case ts.Diagnostics.Types_of_property_0_are_incompatible.code: {
|
|
52391
52407
|
if (path.indexOf("new ") === 0) {
|
|
52392
|
-
path = "("
|
|
52408
|
+
path = "(".concat(path, ")");
|
|
52393
52409
|
}
|
|
52394
52410
|
var str = "" + args[0];
|
|
52395
52411
|
if (path.length === 0) {
|
|
52396
|
-
path = ""
|
|
52412
|
+
path = "".concat(str);
|
|
52397
52413
|
}
|
|
52398
52414
|
else if (ts.isIdentifierText(str, ts.getEmitScriptTarget(compilerOptions))) {
|
|
52399
|
-
path = path
|
|
52415
|
+
path = "".concat(path, ".").concat(str);
|
|
52400
52416
|
}
|
|
52401
52417
|
else if (str[0] === "[" && str[str.length - 1] === "]") {
|
|
52402
|
-
path = ""
|
|
52418
|
+
path = "".concat(path).concat(str);
|
|
52403
52419
|
}
|
|
52404
52420
|
else {
|
|
52405
|
-
path = path
|
|
52421
|
+
path = "".concat(path, "[").concat(str, "]");
|
|
52406
52422
|
}
|
|
52407
52423
|
break;
|
|
52408
52424
|
}
|
|
@@ -52429,7 +52445,7 @@ var ts;
|
|
|
52429
52445
|
msg.code === ts.Diagnostics.Construct_signatures_with_no_arguments_have_incompatible_return_types_0_and_1.code)
|
|
52430
52446
|
? ""
|
|
52431
52447
|
: "...";
|
|
52432
|
-
path = ""
|
|
52448
|
+
path = "".concat(prefix).concat(path, "(").concat(params, ")");
|
|
52433
52449
|
}
|
|
52434
52450
|
break;
|
|
52435
52451
|
}
|
|
@@ -52442,7 +52458,7 @@ var ts;
|
|
|
52442
52458
|
break;
|
|
52443
52459
|
}
|
|
52444
52460
|
default:
|
|
52445
|
-
return ts.Debug.fail("Unhandled Diagnostic: "
|
|
52461
|
+
return ts.Debug.fail("Unhandled Diagnostic: ".concat(msg.code));
|
|
52446
52462
|
}
|
|
52447
52463
|
}
|
|
52448
52464
|
if (path) {
|
|
@@ -52974,7 +52990,8 @@ var ts;
|
|
|
52974
52990
|
if (overflow) {
|
|
52975
52991
|
return 0;
|
|
52976
52992
|
}
|
|
52977
|
-
var
|
|
52993
|
+
var keyIntersectionState = intersectionState | (inPropertyCheck ? 16 : 0);
|
|
52994
|
+
var id = getRelationKey(source, target, keyIntersectionState, relation, false);
|
|
52978
52995
|
var entry = relation.get(id);
|
|
52979
52996
|
if (entry !== undefined) {
|
|
52980
52997
|
if (reportErrors && entry & 2 && !(entry & 4)) {
|
|
@@ -52998,12 +53015,9 @@ var ts;
|
|
|
52998
53015
|
targetStack = [];
|
|
52999
53016
|
}
|
|
53000
53017
|
else {
|
|
53001
|
-
var broadestEquivalentId = id.
|
|
53002
|
-
var index = ts.length(id.slice(0, offset).match(/[-=]/g) || undefined);
|
|
53003
|
-
return "=" + index;
|
|
53004
|
-
}); }).join(",");
|
|
53018
|
+
var broadestEquivalentId = id.startsWith("*") ? getRelationKey(source, target, keyIntersectionState, relation, true) : undefined;
|
|
53005
53019
|
for (var i = 0; i < maybeCount; i++) {
|
|
53006
|
-
if (id === maybeKeys[i] || broadestEquivalentId === maybeKeys[i]) {
|
|
53020
|
+
if (id === maybeKeys[i] || broadestEquivalentId && broadestEquivalentId === maybeKeys[i]) {
|
|
53007
53021
|
return 3;
|
|
53008
53022
|
}
|
|
53009
53023
|
}
|
|
@@ -53245,7 +53259,7 @@ var ts;
|
|
|
53245
53259
|
originalErrorInfo = undefined;
|
|
53246
53260
|
}
|
|
53247
53261
|
}
|
|
53248
|
-
else if (isGenericMappedType(target)) {
|
|
53262
|
+
else if (isGenericMappedType(target) && relation !== identityRelation) {
|
|
53249
53263
|
var keysRemapped = !!target.declaration.nameType;
|
|
53250
53264
|
var templateType = getTemplateTypeFromMappedType(target);
|
|
53251
53265
|
var modifiers = getMappedTypeModifiers(target);
|
|
@@ -54277,40 +54291,48 @@ var ts;
|
|
|
54277
54291
|
function isTypeReferenceWithGenericArguments(type) {
|
|
54278
54292
|
return isNonDeferredTypeReference(type) && ts.some(getTypeArguments(type), function (t) { return !!(t.flags & 262144) || isTypeReferenceWithGenericArguments(t); });
|
|
54279
54293
|
}
|
|
54280
|
-
function
|
|
54281
|
-
|
|
54282
|
-
var
|
|
54283
|
-
|
|
54284
|
-
|
|
54285
|
-
|
|
54286
|
-
|
|
54287
|
-
|
|
54288
|
-
|
|
54289
|
-
|
|
54294
|
+
function getGenericTypeReferenceRelationKey(source, target, postFix, ignoreConstraints) {
|
|
54295
|
+
var typeParameters = [];
|
|
54296
|
+
var constraintMarker = "";
|
|
54297
|
+
var sourceId = getTypeReferenceId(source, 0);
|
|
54298
|
+
var targetId = getTypeReferenceId(target, 0);
|
|
54299
|
+
return "".concat(constraintMarker).concat(sourceId, ",").concat(targetId).concat(postFix);
|
|
54300
|
+
function getTypeReferenceId(type, depth) {
|
|
54301
|
+
if (depth === void 0) { depth = 0; }
|
|
54302
|
+
var result = "" + type.target.id;
|
|
54303
|
+
for (var _i = 0, _a = getTypeArguments(type); _i < _a.length; _i++) {
|
|
54304
|
+
var t = _a[_i];
|
|
54305
|
+
if (t.flags & 262144) {
|
|
54306
|
+
if (ignoreConstraints || isUnconstrainedTypeParameter(t)) {
|
|
54307
|
+
var index = typeParameters.indexOf(t);
|
|
54308
|
+
if (index < 0) {
|
|
54309
|
+
index = typeParameters.length;
|
|
54310
|
+
typeParameters.push(t);
|
|
54311
|
+
}
|
|
54312
|
+
result += "=" + index;
|
|
54313
|
+
continue;
|
|
54314
|
+
}
|
|
54315
|
+
constraintMarker = "*";
|
|
54316
|
+
}
|
|
54317
|
+
else if (depth < 4 && isTypeReferenceWithGenericArguments(t)) {
|
|
54318
|
+
result += "<" + getTypeReferenceId(t, depth + 1) + ">";
|
|
54319
|
+
continue;
|
|
54290
54320
|
}
|
|
54291
|
-
result += "=" + index;
|
|
54292
|
-
}
|
|
54293
|
-
else if (depth < 4 && isTypeReferenceWithGenericArguments(t)) {
|
|
54294
|
-
result += "<" + getTypeReferenceId(t, typeParameters, depth + 1) + ">";
|
|
54295
|
-
}
|
|
54296
|
-
else {
|
|
54297
54321
|
result += "-" + t.id;
|
|
54298
54322
|
}
|
|
54323
|
+
return result;
|
|
54299
54324
|
}
|
|
54300
|
-
return result;
|
|
54301
54325
|
}
|
|
54302
|
-
function getRelationKey(source, target, intersectionState, relation) {
|
|
54326
|
+
function getRelationKey(source, target, intersectionState, relation, ignoreConstraints) {
|
|
54303
54327
|
if (relation === identityRelation && source.id > target.id) {
|
|
54304
54328
|
var temp = source;
|
|
54305
54329
|
source = target;
|
|
54306
54330
|
target = temp;
|
|
54307
54331
|
}
|
|
54308
54332
|
var postFix = intersectionState ? ":" + intersectionState : "";
|
|
54309
|
-
|
|
54310
|
-
|
|
54311
|
-
|
|
54312
|
-
}
|
|
54313
|
-
return source.id + "," + target.id + postFix;
|
|
54333
|
+
return isTypeReferenceWithGenericArguments(source) && isTypeReferenceWithGenericArguments(target) ?
|
|
54334
|
+
getGenericTypeReferenceRelationKey(source, target, postFix, ignoreConstraints) :
|
|
54335
|
+
"".concat(source.id, ",").concat(target.id).concat(postFix);
|
|
54314
54336
|
}
|
|
54315
54337
|
function forEachProperty(prop, callback) {
|
|
54316
54338
|
if (ts.getCheckFlags(prop) & 6) {
|
|
@@ -54349,16 +54371,21 @@ var ts;
|
|
|
54349
54371
|
!hasBaseType(checkClass, getDeclaringClass(p)) : false; }) ? undefined : checkClass;
|
|
54350
54372
|
}
|
|
54351
54373
|
function isDeeplyNestedType(type, stack, depth, maxDepth) {
|
|
54352
|
-
if (maxDepth === void 0) { maxDepth =
|
|
54374
|
+
if (maxDepth === void 0) { maxDepth = 3; }
|
|
54353
54375
|
if (depth >= maxDepth) {
|
|
54354
54376
|
var identity_1 = getRecursionIdentity(type);
|
|
54355
54377
|
var count = 0;
|
|
54378
|
+
var lastTypeId = 0;
|
|
54356
54379
|
for (var i = 0; i < depth; i++) {
|
|
54357
|
-
|
|
54358
|
-
|
|
54359
|
-
if (
|
|
54360
|
-
|
|
54380
|
+
var t = stack[i];
|
|
54381
|
+
if (getRecursionIdentity(t) === identity_1) {
|
|
54382
|
+
if (t.id >= lastTypeId) {
|
|
54383
|
+
count++;
|
|
54384
|
+
if (count >= maxDepth) {
|
|
54385
|
+
return true;
|
|
54386
|
+
}
|
|
54361
54387
|
}
|
|
54388
|
+
lastTypeId = t.id;
|
|
54362
54389
|
}
|
|
54363
54390
|
}
|
|
54364
54391
|
}
|
|
@@ -54998,7 +55025,8 @@ var ts;
|
|
|
54998
55025
|
(resolveName(param, param.name.escapedText, 788968, undefined, param.name.escapedText, true) ||
|
|
54999
55026
|
param.name.originalKeywordKind && ts.isTypeNodeKind(param.name.originalKeywordKind))) {
|
|
55000
55027
|
var newName = "arg" + param.parent.parameters.indexOf(param);
|
|
55001
|
-
|
|
55028
|
+
var typeName = ts.declarationNameToString(param.name) + (param.dotDotDotToken ? "[]" : "");
|
|
55029
|
+
errorOrSuggestion(noImplicitAny, declaration, ts.Diagnostics.Parameter_has_a_name_but_no_type_Did_you_mean_0_Colon_1, newName, typeName);
|
|
55002
55030
|
return;
|
|
55003
55031
|
}
|
|
55004
55032
|
diagnostic = declaration.dotDotDotToken ?
|
|
@@ -56120,10 +56148,10 @@ var ts;
|
|
|
56120
56148
|
case 79:
|
|
56121
56149
|
if (!ts.isThisInTypeQuery(node)) {
|
|
56122
56150
|
var symbol = getResolvedSymbol(node);
|
|
56123
|
-
return symbol !== unknownSymbol ? (flowContainer ? getNodeId(flowContainer) : "-1"
|
|
56151
|
+
return symbol !== unknownSymbol ? "".concat(flowContainer ? getNodeId(flowContainer) : "-1", "|").concat(getTypeId(declaredType), "|").concat(getTypeId(initialType), "|").concat(getSymbolId(symbol)) : undefined;
|
|
56124
56152
|
}
|
|
56125
56153
|
case 108:
|
|
56126
|
-
return "0|"
|
|
56154
|
+
return "0|".concat(flowContainer ? getNodeId(flowContainer) : "-1", "|").concat(getTypeId(declaredType), "|").concat(getTypeId(initialType));
|
|
56127
56155
|
case 229:
|
|
56128
56156
|
case 211:
|
|
56129
56157
|
return getFlowCacheKey(node.expression, declaredType, initialType, flowContainer);
|
|
@@ -59364,7 +59392,7 @@ var ts;
|
|
|
59364
59392
|
!leftName ? rightName :
|
|
59365
59393
|
!rightName ? leftName :
|
|
59366
59394
|
undefined;
|
|
59367
|
-
var paramSymbol = createSymbol(1 | (isOptional && !isRestParam ? 16777216 : 0), paramName || "arg"
|
|
59395
|
+
var paramSymbol = createSymbol(1 | (isOptional && !isRestParam ? 16777216 : 0), paramName || "arg".concat(i));
|
|
59368
59396
|
paramSymbol.type = isRestParam ? createArrayType(unionParamType) : unionParamType;
|
|
59369
59397
|
params[i] = paramSymbol;
|
|
59370
59398
|
}
|
|
@@ -60882,7 +60910,7 @@ var ts;
|
|
|
60882
60910
|
}
|
|
60883
60911
|
function getSuggestedSymbolForNonexistentSymbol(location, outerName, meaning) {
|
|
60884
60912
|
ts.Debug.assert(outerName !== undefined, "outername should always be defined");
|
|
60885
|
-
var result = resolveNameHelper(location, outerName, meaning, undefined, outerName, false, false, function (symbols, name, meaning) {
|
|
60913
|
+
var result = resolveNameHelper(location, outerName, meaning, undefined, outerName, false, false, true, function (symbols, name, meaning) {
|
|
60886
60914
|
ts.Debug.assertEqual(outerName, name, "name should equal outerName");
|
|
60887
60915
|
var symbol = getSymbol(symbols, name, meaning);
|
|
60888
60916
|
if (symbol)
|
|
@@ -65693,6 +65721,8 @@ var ts;
|
|
|
65693
65721
|
if (!typeReferenceNode)
|
|
65694
65722
|
return undefined;
|
|
65695
65723
|
var typeParameters = getTypeParametersForTypeReference(typeReferenceNode);
|
|
65724
|
+
if (!typeParameters)
|
|
65725
|
+
return undefined;
|
|
65696
65726
|
var constraint = getConstraintOfTypeParameter(typeParameters[typeReferenceNode.typeArguments.indexOf(node)]);
|
|
65697
65727
|
return constraint && instantiateType(constraint, createTypeMapper(typeParameters, getEffectiveTypeArguments(typeReferenceNode, typeParameters)));
|
|
65698
65728
|
}
|
|
@@ -67214,7 +67244,7 @@ var ts;
|
|
|
67214
67244
|
return;
|
|
67215
67245
|
}
|
|
67216
67246
|
var symbol = getSymbolOfNode(node);
|
|
67217
|
-
if (symbol.flags & 2097152 && ts.
|
|
67247
|
+
if (symbol.flags & 2097152 && ts.isVariableDeclarationInitializedToBareOrAccessedRequire(node)) {
|
|
67218
67248
|
checkAliasSymbol(node);
|
|
67219
67249
|
return;
|
|
67220
67250
|
}
|
|
@@ -67805,7 +67835,7 @@ var ts;
|
|
|
67805
67835
|
function getPropertyNameForKnownSymbolName(symbolName) {
|
|
67806
67836
|
var ctorType = getGlobalESSymbolConstructorSymbol(false);
|
|
67807
67837
|
var uniqueType = ctorType && getTypeOfPropertyOfType(getTypeOfSymbol(ctorType), ts.escapeLeadingUnderscores(symbolName));
|
|
67808
|
-
return uniqueType && isTypeUsableAsPropertyName(uniqueType) ? getPropertyNameFromType(uniqueType) : "__@"
|
|
67838
|
+
return uniqueType && isTypeUsableAsPropertyName(uniqueType) ? getPropertyNameFromType(uniqueType) : "__@".concat(symbolName);
|
|
67809
67839
|
}
|
|
67810
67840
|
function getIterationTypesOfIterableSlow(type, resolver, errorNode) {
|
|
67811
67841
|
var _a;
|
|
@@ -74053,7 +74083,7 @@ var ts;
|
|
|
74053
74083
|
value >= 52 && value < 62 ? 48 + value - 52 :
|
|
74054
74084
|
value === 62 ? 43 :
|
|
74055
74085
|
value === 63 ? 47 :
|
|
74056
|
-
ts.Debug.fail(value
|
|
74086
|
+
ts.Debug.fail("".concat(value, ": not a base64 value"));
|
|
74057
74087
|
}
|
|
74058
74088
|
function base64FormatDecode(ch) {
|
|
74059
74089
|
return ch >= 65 && ch <= 90 ? ch - 65 :
|
|
@@ -74126,7 +74156,7 @@ var ts;
|
|
|
74126
74156
|
var mappings = ts.arrayFrom(decoder, processMapping);
|
|
74127
74157
|
if (decoder.error !== undefined) {
|
|
74128
74158
|
if (host.log) {
|
|
74129
|
-
host.log("Encountered error while decoding sourcemap: "
|
|
74159
|
+
host.log("Encountered error while decoding sourcemap: ".concat(decoder.error));
|
|
74130
74160
|
}
|
|
74131
74161
|
decodedMappings = ts.emptyArray;
|
|
74132
74162
|
}
|
|
@@ -76561,7 +76591,7 @@ var ts;
|
|
|
76561
76591
|
var propertyName = ts.isPropertyAccessExpression(originalNode)
|
|
76562
76592
|
? ts.declarationNameToString(originalNode.name)
|
|
76563
76593
|
: ts.getTextOfNode(originalNode.argumentExpression);
|
|
76564
|
-
ts.addSyntheticTrailingComment(substitute, 3, " "
|
|
76594
|
+
ts.addSyntheticTrailingComment(substitute, 3, " ".concat(propertyName, " "));
|
|
76565
76595
|
}
|
|
76566
76596
|
return substitute;
|
|
76567
76597
|
}
|
|
@@ -77745,8 +77775,8 @@ var ts;
|
|
|
77745
77775
|
}
|
|
77746
77776
|
function createHoistedVariableForClass(name, node) {
|
|
77747
77777
|
var className = getPrivateIdentifierEnvironment().className;
|
|
77748
|
-
var prefix = className ? "_"
|
|
77749
|
-
var identifier = factory.createUniqueName(prefix
|
|
77778
|
+
var prefix = className ? "_".concat(className) : "";
|
|
77779
|
+
var identifier = factory.createUniqueName("".concat(prefix, "_").concat(name), 16);
|
|
77750
77780
|
if (resolver.getNodeCheckFlags(node) & 524288) {
|
|
77751
77781
|
addBlockScopedVariable(identifier);
|
|
77752
77782
|
}
|
|
@@ -79315,7 +79345,7 @@ var ts;
|
|
|
79315
79345
|
specifierSourceImports = ts.createMap();
|
|
79316
79346
|
currentFileState.utilizedImplicitRuntimeImports.set(importSource, specifierSourceImports);
|
|
79317
79347
|
}
|
|
79318
|
-
var generatedName = factory.createUniqueName("_"
|
|
79348
|
+
var generatedName = factory.createUniqueName("_".concat(name), 16 | 32 | 64);
|
|
79319
79349
|
var specifier = factory.createImportSpecifier(false, factory.createIdentifier(name), generatedName);
|
|
79320
79350
|
generatedName.generatedImportReference = specifier;
|
|
79321
79351
|
specifierSourceImports.set(name, specifier);
|
|
@@ -80250,11 +80280,11 @@ var ts;
|
|
|
80250
80280
|
}
|
|
80251
80281
|
else {
|
|
80252
80282
|
if (node.kind === 245) {
|
|
80253
|
-
labelMarker = "break-"
|
|
80283
|
+
labelMarker = "break-".concat(label.escapedText);
|
|
80254
80284
|
setLabeledJump(convertedLoopState, true, ts.idText(label), labelMarker);
|
|
80255
80285
|
}
|
|
80256
80286
|
else {
|
|
80257
|
-
labelMarker = "continue-"
|
|
80287
|
+
labelMarker = "continue-".concat(label.escapedText);
|
|
80258
80288
|
setLabeledJump(convertedLoopState, false, ts.idText(label), labelMarker);
|
|
80259
80289
|
}
|
|
80260
80290
|
}
|
|
@@ -85874,7 +85904,7 @@ var ts;
|
|
|
85874
85904
|
return getTypeAliasDeclarationVisibilityError;
|
|
85875
85905
|
}
|
|
85876
85906
|
else {
|
|
85877
|
-
return ts.Debug.assertNever(node, "Attempted to set a declaration diagnostic context for unhandled node kind: "
|
|
85907
|
+
return ts.Debug.assertNever(node, "Attempted to set a declaration diagnostic context for unhandled node kind: ".concat(ts.SyntaxKind[node.kind]));
|
|
85878
85908
|
}
|
|
85879
85909
|
function getVariableDeclarationTypeVisibilityDiagnosticMessage(symbolAccessibilityResult) {
|
|
85880
85910
|
if (node.kind === 253 || node.kind === 202) {
|
|
@@ -86071,7 +86101,7 @@ var ts;
|
|
|
86071
86101
|
ts.Diagnostics.Parameter_0_of_accessor_has_or_is_using_name_1_from_private_module_2 :
|
|
86072
86102
|
ts.Diagnostics.Parameter_0_of_accessor_has_or_is_using_private_name_1;
|
|
86073
86103
|
default:
|
|
86074
|
-
return ts.Debug.fail("Unknown parent for parameter: "
|
|
86104
|
+
return ts.Debug.fail("Unknown parent for parameter: ".concat(ts.SyntaxKind[node.parent.kind]));
|
|
86075
86105
|
}
|
|
86076
86106
|
}
|
|
86077
86107
|
function getTypeParameterConstraintVisibilityError() {
|
|
@@ -86758,7 +86788,7 @@ var ts;
|
|
|
86758
86788
|
while (ts.length(lateMarkedStatements)) {
|
|
86759
86789
|
var i = lateMarkedStatements.shift();
|
|
86760
86790
|
if (!ts.isLateVisibilityPaintedStatement(i)) {
|
|
86761
|
-
return ts.Debug.fail("Late replaced statement was found which is not handled by the declaration transformer!: "
|
|
86791
|
+
return ts.Debug.fail("Late replaced statement was found which is not handled by the declaration transformer!: ".concat(ts.SyntaxKind ? ts.SyntaxKind[i.kind] : i.kind));
|
|
86762
86792
|
}
|
|
86763
86793
|
var priorNeedsDeclare = needsDeclare;
|
|
86764
86794
|
needsDeclare = i.parent && ts.isSourceFile(i.parent) && !(ts.isExternalModule(i.parent) && isBundledEmit);
|
|
@@ -86923,7 +86953,7 @@ var ts;
|
|
|
86923
86953
|
return cleanup(input);
|
|
86924
86954
|
return cleanup(factory.updateImportTypeNode(input, factory.updateLiteralTypeNode(input.argument, rewriteModuleSpecifier(input, input.argument.literal)), input.qualifier, ts.visitNodes(input.typeArguments, visitDeclarationSubtree, ts.isTypeNode), input.isTypeOf));
|
|
86925
86955
|
}
|
|
86926
|
-
default: ts.Debug.assertNever(input, "Attempted to process unhandled node kind: "
|
|
86956
|
+
default: ts.Debug.assertNever(input, "Attempted to process unhandled node kind: ".concat(ts.SyntaxKind[input.kind]));
|
|
86927
86957
|
}
|
|
86928
86958
|
}
|
|
86929
86959
|
if (ts.isTupleTypeNode(input) && (ts.getLineAndCharacterOfPosition(currentSourceFile, input.pos).line === ts.getLineAndCharacterOfPosition(currentSourceFile, input.end).line)) {
|
|
@@ -87167,7 +87197,7 @@ var ts;
|
|
|
87167
87197
|
var extendsClause_1 = ts.getEffectiveBaseTypeNode(input);
|
|
87168
87198
|
if (extendsClause_1 && !ts.isEntityNameExpression(extendsClause_1.expression) && extendsClause_1.expression.kind !== 104) {
|
|
87169
87199
|
var oldId = input.name ? ts.unescapeLeadingUnderscores(input.name.escapedText) : "default";
|
|
87170
|
-
var newId_1 = factory.createUniqueName(oldId
|
|
87200
|
+
var newId_1 = factory.createUniqueName("".concat(oldId, "_base"), 16);
|
|
87171
87201
|
getSymbolAccessibilityDiagnostic = function () { return ({
|
|
87172
87202
|
diagnosticMessage: ts.Diagnostics.extends_clause_of_exported_class_0_has_or_is_using_private_name_1,
|
|
87173
87203
|
errorNode: extendsClause_1,
|
|
@@ -87204,7 +87234,7 @@ var ts;
|
|
|
87204
87234
|
}))));
|
|
87205
87235
|
}
|
|
87206
87236
|
}
|
|
87207
|
-
return ts.Debug.assertNever(input, "Unhandled top-level node in declaration emit: "
|
|
87237
|
+
return ts.Debug.assertNever(input, "Unhandled top-level node in declaration emit: ".concat(ts.SyntaxKind[input.kind]));
|
|
87208
87238
|
function cleanup(node) {
|
|
87209
87239
|
if (isEnclosingDeclaration(input)) {
|
|
87210
87240
|
enclosingDeclaration = previousEnclosingDeclaration;
|
|
@@ -87973,13 +88003,13 @@ var ts;
|
|
|
87973
88003
|
if (ts.fileExtensionIs(inputFileName, ".json"))
|
|
87974
88004
|
return;
|
|
87975
88005
|
if (js && configFile.options.sourceMap) {
|
|
87976
|
-
addOutput(js
|
|
88006
|
+
addOutput("".concat(js, ".map"));
|
|
87977
88007
|
}
|
|
87978
88008
|
if (ts.getEmitDeclarations(configFile.options)) {
|
|
87979
88009
|
var dts = getOutputDeclarationFileName(inputFileName, configFile, ignoreCase, getCommonSourceDirectory);
|
|
87980
88010
|
addOutput(dts);
|
|
87981
88011
|
if (configFile.options.declarationMap) {
|
|
87982
|
-
addOutput(dts
|
|
88012
|
+
addOutput("".concat(dts, ".map"));
|
|
87983
88013
|
}
|
|
87984
88014
|
}
|
|
87985
88015
|
}
|
|
@@ -88039,7 +88069,7 @@ var ts;
|
|
|
88039
88069
|
function getFirstProjectOutput(configFile, ignoreCase) {
|
|
88040
88070
|
if (ts.outFile(configFile.options)) {
|
|
88041
88071
|
var jsFilePath = getOutputPathsForBundle(configFile.options, false).jsFilePath;
|
|
88042
|
-
return ts.Debug.checkDefined(jsFilePath, "project "
|
|
88072
|
+
return ts.Debug.checkDefined(jsFilePath, "project ".concat(configFile.options.configFilePath, " expected to have at least one output"));
|
|
88043
88073
|
}
|
|
88044
88074
|
var getCommonSourceDirectory = ts.memoize(function () { return getCommonSourceDirectoryOfConfig(configFile, ignoreCase); });
|
|
88045
88075
|
for (var _a = 0, _b = configFile.fileNames; _a < _b.length; _a++) {
|
|
@@ -88058,7 +88088,7 @@ var ts;
|
|
|
88058
88088
|
var buildInfoPath = getTsBuildInfoEmitOutputFilePath(configFile.options);
|
|
88059
88089
|
if (buildInfoPath)
|
|
88060
88090
|
return buildInfoPath;
|
|
88061
|
-
return ts.Debug.fail("project "
|
|
88091
|
+
return ts.Debug.fail("project ".concat(configFile.options.configFilePath, " expected to have at least one output"));
|
|
88062
88092
|
}
|
|
88063
88093
|
ts.getFirstProjectOutput = getFirstProjectOutput;
|
|
88064
88094
|
function emitFiles(resolver, host, targetSourceFile, _a, emitOnlyDtsFiles, onlyBuildInfo, forceDtsEmit) {
|
|
@@ -88268,7 +88298,7 @@ var ts;
|
|
|
88268
88298
|
if (sourceMappingURL) {
|
|
88269
88299
|
if (!writer.isAtStartOfLine())
|
|
88270
88300
|
writer.rawWrite(newLine);
|
|
88271
|
-
writer.writeComment("//# "
|
|
88301
|
+
writer.writeComment("//# ".concat("sourceMappingURL", "=").concat(sourceMappingURL));
|
|
88272
88302
|
}
|
|
88273
88303
|
if (sourceMapFilePath) {
|
|
88274
88304
|
var sourceMap = sourceMapGenerator.toString();
|
|
@@ -88308,7 +88338,7 @@ var ts;
|
|
|
88308
88338
|
if (mapOptions.inlineSourceMap) {
|
|
88309
88339
|
var sourceMapText = sourceMapGenerator.toString();
|
|
88310
88340
|
var base64SourceMapText = ts.base64encode(ts.sys, sourceMapText);
|
|
88311
|
-
return "data:application/json;base64,"
|
|
88341
|
+
return "data:application/json;base64,".concat(base64SourceMapText);
|
|
88312
88342
|
}
|
|
88313
88343
|
var sourceMapFile = ts.getBaseFileName(ts.normalizeSlashes(ts.Debug.checkDefined(sourceMapFilePath)));
|
|
88314
88344
|
if (mapOptions.mapRoot) {
|
|
@@ -88472,7 +88502,7 @@ var ts;
|
|
|
88472
88502
|
return;
|
|
88473
88503
|
break;
|
|
88474
88504
|
default:
|
|
88475
|
-
ts.Debug.fail("Unexpected path: "
|
|
88505
|
+
ts.Debug.fail("Unexpected path: ".concat(name));
|
|
88476
88506
|
}
|
|
88477
88507
|
outputFiles.push({ name: name, text: text, writeByteOrderMark: writeByteOrderMark });
|
|
88478
88508
|
},
|
|
@@ -89280,7 +89310,7 @@ var ts;
|
|
|
89280
89310
|
return writeTokenNode(node, writeKeyword);
|
|
89281
89311
|
if (ts.isTokenKind(node.kind))
|
|
89282
89312
|
return writeTokenNode(node, writePunctuation);
|
|
89283
|
-
ts.Debug.fail("Unhandled SyntaxKind: "
|
|
89313
|
+
ts.Debug.fail("Unhandled SyntaxKind: ".concat(ts.Debug.formatSyntaxKind(node.kind), "."));
|
|
89284
89314
|
}
|
|
89285
89315
|
function emitMappedTypeParameter(node) {
|
|
89286
89316
|
emit(node.name);
|
|
@@ -89420,12 +89450,12 @@ var ts;
|
|
|
89420
89450
|
}
|
|
89421
89451
|
}
|
|
89422
89452
|
function emitPlaceholder(hint, node, snippet) {
|
|
89423
|
-
nonEscapingWrite("${"
|
|
89453
|
+
nonEscapingWrite("${".concat(snippet.order, ":"));
|
|
89424
89454
|
pipelineEmitWithHintWorker(hint, node, false);
|
|
89425
89455
|
nonEscapingWrite("}");
|
|
89426
89456
|
}
|
|
89427
89457
|
function emitTabStop(snippet) {
|
|
89428
|
-
nonEscapingWrite("$"
|
|
89458
|
+
nonEscapingWrite("$".concat(snippet.order));
|
|
89429
89459
|
}
|
|
89430
89460
|
function emitIdentifier(node) {
|
|
89431
89461
|
var writeText = node.symbol ? writeSymbol : write;
|
|
@@ -91053,17 +91083,17 @@ var ts;
|
|
|
91053
91083
|
writeLine();
|
|
91054
91084
|
}
|
|
91055
91085
|
if (currentSourceFile && currentSourceFile.moduleName) {
|
|
91056
|
-
writeComment("/// <amd-module name=\""
|
|
91086
|
+
writeComment("/// <amd-module name=\"".concat(currentSourceFile.moduleName, "\" />"));
|
|
91057
91087
|
writeLine();
|
|
91058
91088
|
}
|
|
91059
91089
|
if (currentSourceFile && currentSourceFile.amdDependencies) {
|
|
91060
91090
|
for (var _a = 0, _b = currentSourceFile.amdDependencies; _a < _b.length; _a++) {
|
|
91061
91091
|
var dep = _b[_a];
|
|
91062
91092
|
if (dep.name) {
|
|
91063
|
-
writeComment("/// <amd-dependency name=\""
|
|
91093
|
+
writeComment("/// <amd-dependency name=\"".concat(dep.name, "\" path=\"").concat(dep.path, "\" />"));
|
|
91064
91094
|
}
|
|
91065
91095
|
else {
|
|
91066
|
-
writeComment("/// <amd-dependency path=\""
|
|
91096
|
+
writeComment("/// <amd-dependency path=\"".concat(dep.path, "\" />"));
|
|
91067
91097
|
}
|
|
91068
91098
|
writeLine();
|
|
91069
91099
|
}
|
|
@@ -91071,7 +91101,7 @@ var ts;
|
|
|
91071
91101
|
for (var _c = 0, files_2 = files; _c < files_2.length; _c++) {
|
|
91072
91102
|
var directive = files_2[_c];
|
|
91073
91103
|
var pos = writer.getTextPos();
|
|
91074
|
-
writeComment("/// <reference path=\""
|
|
91104
|
+
writeComment("/// <reference path=\"".concat(directive.fileName, "\" />"));
|
|
91075
91105
|
if (bundleFileInfo)
|
|
91076
91106
|
bundleFileInfo.sections.push({ pos: pos, end: writer.getTextPos(), kind: "reference", data: directive.fileName });
|
|
91077
91107
|
writeLine();
|
|
@@ -91079,7 +91109,7 @@ var ts;
|
|
|
91079
91109
|
for (var _d = 0, types_24 = types; _d < types_24.length; _d++) {
|
|
91080
91110
|
var directive = types_24[_d];
|
|
91081
91111
|
var pos = writer.getTextPos();
|
|
91082
|
-
writeComment("/// <reference types=\""
|
|
91112
|
+
writeComment("/// <reference types=\"".concat(directive.fileName, "\" />"));
|
|
91083
91113
|
if (bundleFileInfo)
|
|
91084
91114
|
bundleFileInfo.sections.push({ pos: pos, end: writer.getTextPos(), kind: "type", data: directive.fileName });
|
|
91085
91115
|
writeLine();
|
|
@@ -91087,7 +91117,7 @@ var ts;
|
|
|
91087
91117
|
for (var _e = 0, libs_1 = libs; _e < libs_1.length; _e++) {
|
|
91088
91118
|
var directive = libs_1[_e];
|
|
91089
91119
|
var pos = writer.getTextPos();
|
|
91090
|
-
writeComment("/// <reference lib=\""
|
|
91120
|
+
writeComment("/// <reference lib=\"".concat(directive.fileName, "\" />"));
|
|
91091
91121
|
if (bundleFileInfo)
|
|
91092
91122
|
bundleFileInfo.sections.push({ pos: pos, end: writer.getTextPos(), kind: "lib", data: directive.fileName });
|
|
91093
91123
|
writeLine();
|
|
@@ -91781,9 +91811,9 @@ var ts;
|
|
|
91781
91811
|
var textSourceNode = node.textSourceNode;
|
|
91782
91812
|
if (ts.isIdentifier(textSourceNode) || ts.isNumericLiteral(textSourceNode)) {
|
|
91783
91813
|
var text = ts.isNumericLiteral(textSourceNode) ? textSourceNode.text : getTextOfNode(textSourceNode);
|
|
91784
|
-
return jsxAttributeEscape ? "\""
|
|
91785
|
-
neverAsciiEscape || (ts.getEmitFlags(node) & 16777216) ? "\""
|
|
91786
|
-
"\""
|
|
91814
|
+
return jsxAttributeEscape ? "\"".concat(ts.escapeJsxAttributeString(text), "\"") :
|
|
91815
|
+
neverAsciiEscape || (ts.getEmitFlags(node) & 16777216) ? "\"".concat(ts.escapeString(text), "\"") :
|
|
91816
|
+
"\"".concat(ts.escapeNonAsciiString(text), "\"");
|
|
91787
91817
|
}
|
|
91788
91818
|
else {
|
|
91789
91819
|
return getLiteralTextOfNode(textSourceNode, neverAsciiEscape, jsxAttributeEscape);
|
|
@@ -92182,8 +92212,8 @@ var ts;
|
|
|
92182
92212
|
}
|
|
92183
92213
|
function formatSynthesizedComment(comment) {
|
|
92184
92214
|
return comment.kind === 3
|
|
92185
|
-
? "/*"
|
|
92186
|
-
: "//"
|
|
92215
|
+
? "/*".concat(comment.text, "*/")
|
|
92216
|
+
: "//".concat(comment.text);
|
|
92187
92217
|
}
|
|
92188
92218
|
function emitBodyWithDetachedComments(node, detachedRange, emitCallback) {
|
|
92189
92219
|
enterComment();
|
|
@@ -92628,7 +92658,7 @@ var ts;
|
|
|
92628
92658
|
var rootResult = tryReadDirectory(rootDir, rootDirPath);
|
|
92629
92659
|
var rootSymLinkResult;
|
|
92630
92660
|
if (rootResult !== undefined) {
|
|
92631
|
-
return ts.matchFiles(rootDir, extensions, excludes, includes, useCaseSensitiveFileNames, currentDirectory, depth, getFileSystemEntries, realpath
|
|
92661
|
+
return ts.matchFiles(rootDir, extensions, excludes, includes, useCaseSensitiveFileNames, currentDirectory, depth, getFileSystemEntries, realpath);
|
|
92632
92662
|
}
|
|
92633
92663
|
return host.readDirectory(rootDir, extensions, excludes, includes, depth);
|
|
92634
92664
|
function getFileSystemEntries(dir) {
|
|
@@ -92797,18 +92827,18 @@ var ts;
|
|
|
92797
92827
|
var watchedDirPath = _a.watchedDirPath, fileOrDirectory = _a.fileOrDirectory, fileOrDirectoryPath = _a.fileOrDirectoryPath, configFileName = _a.configFileName, options = _a.options, program = _a.program, extraFileExtensions = _a.extraFileExtensions, currentDirectory = _a.currentDirectory, useCaseSensitiveFileNames = _a.useCaseSensitiveFileNames, writeLog = _a.writeLog, toPath = _a.toPath;
|
|
92798
92828
|
var newPath = ts.removeIgnoredPath(fileOrDirectoryPath);
|
|
92799
92829
|
if (!newPath) {
|
|
92800
|
-
writeLog("Project: "
|
|
92830
|
+
writeLog("Project: ".concat(configFileName, " Detected ignored path: ").concat(fileOrDirectory));
|
|
92801
92831
|
return true;
|
|
92802
92832
|
}
|
|
92803
92833
|
fileOrDirectoryPath = newPath;
|
|
92804
92834
|
if (fileOrDirectoryPath === watchedDirPath)
|
|
92805
92835
|
return false;
|
|
92806
92836
|
if (ts.hasExtension(fileOrDirectoryPath) && !ts.isSupportedSourceFileName(fileOrDirectory, options, extraFileExtensions)) {
|
|
92807
|
-
writeLog("Project: "
|
|
92837
|
+
writeLog("Project: ".concat(configFileName, " Detected file add/remove of non supported extension: ").concat(fileOrDirectory));
|
|
92808
92838
|
return true;
|
|
92809
92839
|
}
|
|
92810
92840
|
if (ts.isExcludedFile(fileOrDirectory, options.configFile.configFileSpecs, ts.getNormalizedAbsolutePath(ts.getDirectoryPath(configFileName), currentDirectory), useCaseSensitiveFileNames, currentDirectory)) {
|
|
92811
|
-
writeLog("Project: "
|
|
92841
|
+
writeLog("Project: ".concat(configFileName, " Detected excluded file: ").concat(fileOrDirectory));
|
|
92812
92842
|
return true;
|
|
92813
92843
|
}
|
|
92814
92844
|
if (!program)
|
|
@@ -92827,7 +92857,7 @@ var ts;
|
|
|
92827
92857
|
var builderProgram = !realProgram && !ts.isArray(program) ? program : undefined;
|
|
92828
92858
|
if (hasSourceFile((filePathWithoutExtension + ".ts")) ||
|
|
92829
92859
|
hasSourceFile((filePathWithoutExtension + ".tsx"))) {
|
|
92830
|
-
writeLog("Project: "
|
|
92860
|
+
writeLog("Project: ".concat(configFileName, " Detected output file: ").concat(fileOrDirectory));
|
|
92831
92861
|
return true;
|
|
92832
92862
|
}
|
|
92833
92863
|
return false;
|
|
@@ -92895,36 +92925,36 @@ var ts;
|
|
|
92895
92925
|
host.useCaseSensitiveFileNames();
|
|
92896
92926
|
}
|
|
92897
92927
|
function createExcludeWatcherWithLogging(file, flags, options, detailInfo1, detailInfo2) {
|
|
92898
|
-
log("ExcludeWatcher:: Added:: "
|
|
92928
|
+
log("ExcludeWatcher:: Added:: ".concat(getWatchInfo(file, flags, options, detailInfo1, detailInfo2, getDetailWatchInfo)));
|
|
92899
92929
|
return {
|
|
92900
|
-
close: function () { return log("ExcludeWatcher:: Close:: "
|
|
92930
|
+
close: function () { return log("ExcludeWatcher:: Close:: ".concat(getWatchInfo(file, flags, options, detailInfo1, detailInfo2, getDetailWatchInfo))); }
|
|
92901
92931
|
};
|
|
92902
92932
|
}
|
|
92903
92933
|
function createFileWatcherWithLogging(file, cb, flags, options, detailInfo1, detailInfo2) {
|
|
92904
|
-
log("FileWatcher:: Added:: "
|
|
92934
|
+
log("FileWatcher:: Added:: ".concat(getWatchInfo(file, flags, options, detailInfo1, detailInfo2, getDetailWatchInfo)));
|
|
92905
92935
|
var watcher = triggerInvokingFactory.watchFile(file, cb, flags, options, detailInfo1, detailInfo2);
|
|
92906
92936
|
return {
|
|
92907
92937
|
close: function () {
|
|
92908
|
-
log("FileWatcher:: Close:: "
|
|
92938
|
+
log("FileWatcher:: Close:: ".concat(getWatchInfo(file, flags, options, detailInfo1, detailInfo2, getDetailWatchInfo)));
|
|
92909
92939
|
watcher.close();
|
|
92910
92940
|
}
|
|
92911
92941
|
};
|
|
92912
92942
|
}
|
|
92913
92943
|
function createDirectoryWatcherWithLogging(file, cb, flags, options, detailInfo1, detailInfo2) {
|
|
92914
|
-
var watchInfo = "DirectoryWatcher:: Added:: "
|
|
92944
|
+
var watchInfo = "DirectoryWatcher:: Added:: ".concat(getWatchInfo(file, flags, options, detailInfo1, detailInfo2, getDetailWatchInfo));
|
|
92915
92945
|
log(watchInfo);
|
|
92916
92946
|
var start = ts.timestamp();
|
|
92917
92947
|
var watcher = triggerInvokingFactory.watchDirectory(file, cb, flags, options, detailInfo1, detailInfo2);
|
|
92918
92948
|
var elapsed = ts.timestamp() - start;
|
|
92919
|
-
log("Elapsed:: "
|
|
92949
|
+
log("Elapsed:: ".concat(elapsed, "ms ").concat(watchInfo));
|
|
92920
92950
|
return {
|
|
92921
92951
|
close: function () {
|
|
92922
|
-
var watchInfo = "DirectoryWatcher:: Close:: "
|
|
92952
|
+
var watchInfo = "DirectoryWatcher:: Close:: ".concat(getWatchInfo(file, flags, options, detailInfo1, detailInfo2, getDetailWatchInfo));
|
|
92923
92953
|
log(watchInfo);
|
|
92924
92954
|
var start = ts.timestamp();
|
|
92925
92955
|
watcher.close();
|
|
92926
92956
|
var elapsed = ts.timestamp() - start;
|
|
92927
|
-
log("Elapsed:: "
|
|
92957
|
+
log("Elapsed:: ".concat(elapsed, "ms ").concat(watchInfo));
|
|
92928
92958
|
}
|
|
92929
92959
|
};
|
|
92930
92960
|
}
|
|
@@ -92934,16 +92964,16 @@ var ts;
|
|
|
92934
92964
|
for (var _i = 0; _i < arguments.length; _i++) {
|
|
92935
92965
|
args[_i] = arguments[_i];
|
|
92936
92966
|
}
|
|
92937
|
-
var triggerredInfo = (key === "watchFile" ? "FileWatcher" : "DirectoryWatcher"
|
|
92967
|
+
var triggerredInfo = "".concat(key === "watchFile" ? "FileWatcher" : "DirectoryWatcher", ":: Triggered with ").concat(args[0], " ").concat(args[1] !== undefined ? args[1] : "", ":: ").concat(getWatchInfo(file, flags, options, detailInfo1, detailInfo2, getDetailWatchInfo));
|
|
92938
92968
|
log(triggerredInfo);
|
|
92939
92969
|
var start = ts.timestamp();
|
|
92940
92970
|
cb.call.apply(cb, __spreadArray([undefined], args, false));
|
|
92941
92971
|
var elapsed = ts.timestamp() - start;
|
|
92942
|
-
log("Elapsed:: "
|
|
92972
|
+
log("Elapsed:: ".concat(elapsed, "ms ").concat(triggerredInfo));
|
|
92943
92973
|
}, flags, options, detailInfo1, detailInfo2); };
|
|
92944
92974
|
}
|
|
92945
92975
|
function getWatchInfo(file, flags, options, detailInfo1, detailInfo2, getDetailWatchInfo) {
|
|
92946
|
-
return "WatchInfo: "
|
|
92976
|
+
return "WatchInfo: ".concat(file, " ").concat(flags, " ").concat(JSON.stringify(options), " ").concat(getDetailWatchInfo ? getDetailWatchInfo(detailInfo1, detailInfo2) : detailInfo2 === undefined ? detailInfo1 : "".concat(detailInfo1, " ").concat(detailInfo2));
|
|
92947
92977
|
}
|
|
92948
92978
|
}
|
|
92949
92979
|
ts.getWatchFactory = getWatchFactory;
|
|
@@ -93233,12 +93263,12 @@ var ts;
|
|
|
93233
93263
|
}
|
|
93234
93264
|
ts.formatDiagnostics = formatDiagnostics;
|
|
93235
93265
|
function formatDiagnostic(diagnostic, host) {
|
|
93236
|
-
var errorMessage = ts.diagnosticCategoryName(diagnostic)
|
|
93266
|
+
var errorMessage = "".concat(ts.diagnosticCategoryName(diagnostic), " TS").concat(diagnostic.code, ": ").concat(flattenDiagnosticMessageText(diagnostic.messageText, host.getNewLine())).concat(host.getNewLine());
|
|
93237
93267
|
if (diagnostic.file) {
|
|
93238
93268
|
var _a = ts.getLineAndCharacterOfPosition(diagnostic.file, diagnostic.start), line = _a.line, character = _a.character;
|
|
93239
93269
|
var fileName = diagnostic.file.fileName;
|
|
93240
93270
|
var relativeFileName = ts.convertToRelativePath(fileName, host.getCurrentDirectory(), function (fileName) { return host.getCanonicalFileName(fileName); });
|
|
93241
|
-
return relativeFileName
|
|
93271
|
+
return "".concat(relativeFileName, "(").concat(line + 1, ",").concat(character + 1, "): ") + errorMessage;
|
|
93242
93272
|
}
|
|
93243
93273
|
return errorMessage;
|
|
93244
93274
|
}
|
|
@@ -93316,9 +93346,9 @@ var ts;
|
|
|
93316
93346
|
var output = "";
|
|
93317
93347
|
output += color(relativeFileName, ForegroundColorEscapeSequences.Cyan);
|
|
93318
93348
|
output += ":";
|
|
93319
|
-
output += color(""
|
|
93349
|
+
output += color("".concat(firstLine + 1), ForegroundColorEscapeSequences.Yellow);
|
|
93320
93350
|
output += ":";
|
|
93321
|
-
output += color(""
|
|
93351
|
+
output += color("".concat(firstLineChar + 1), ForegroundColorEscapeSequences.Yellow);
|
|
93322
93352
|
return output;
|
|
93323
93353
|
}
|
|
93324
93354
|
ts.formatLocation = formatLocation;
|
|
@@ -93332,7 +93362,7 @@ var ts;
|
|
|
93332
93362
|
output += " - ";
|
|
93333
93363
|
}
|
|
93334
93364
|
output += formatColorAndReset(ts.diagnosticCategoryName(diagnostic), getCategoryFormat(diagnostic.category));
|
|
93335
|
-
output += formatColorAndReset(" TS"
|
|
93365
|
+
output += formatColorAndReset(" TS".concat(diagnostic.code, ": "), ForegroundColorEscapeSequences.Grey);
|
|
93336
93366
|
output += flattenDiagnosticMessageText(diagnostic.messageText, host.getNewLine());
|
|
93337
93367
|
if (diagnostic.file) {
|
|
93338
93368
|
output += host.getNewLine();
|
|
@@ -93432,7 +93462,7 @@ var ts;
|
|
|
93432
93462
|
var result = void 0;
|
|
93433
93463
|
var mode = getModeForResolutionAtIndex(containingFile, i);
|
|
93434
93464
|
i++;
|
|
93435
|
-
var cacheKey = mode !== undefined ? mode
|
|
93465
|
+
var cacheKey = mode !== undefined ? "".concat(mode, "|").concat(name) : name;
|
|
93436
93466
|
if (cache.has(cacheKey)) {
|
|
93437
93467
|
result = cache.get(cacheKey);
|
|
93438
93468
|
}
|
|
@@ -95205,7 +95235,7 @@ var ts;
|
|
|
95205
95235
|
path += (i === 2 ? "/" : "-") + components[i];
|
|
95206
95236
|
i++;
|
|
95207
95237
|
}
|
|
95208
|
-
var resolveFrom = ts.combinePaths(currentDirectory, "__lib_node_modules_lookup_"
|
|
95238
|
+
var resolveFrom = ts.combinePaths(currentDirectory, "__lib_node_modules_lookup_".concat(libFileName, "__.ts"));
|
|
95209
95239
|
var localOverrideModuleResult = ts.resolveModuleName("@typescript/lib-" + path, resolveFrom, { moduleResolution: ts.ModuleResolutionKind.NodeJs }, host, moduleResolutionCache);
|
|
95210
95240
|
if (localOverrideModuleResult === null || localOverrideModuleResult === void 0 ? void 0 : localOverrideModuleResult.resolvedModule) {
|
|
95211
95241
|
return localOverrideModuleResult.resolvedModule.resolvedFileName;
|
|
@@ -95974,10 +96004,10 @@ var ts;
|
|
|
95974
96004
|
}
|
|
95975
96005
|
function directoryExistsIfProjectReferenceDeclDir(dir) {
|
|
95976
96006
|
var dirPath = host.toPath(dir);
|
|
95977
|
-
var dirPathWithTrailingDirectorySeparator = ""
|
|
96007
|
+
var dirPathWithTrailingDirectorySeparator = "".concat(dirPath).concat(ts.directorySeparator);
|
|
95978
96008
|
return ts.forEachKey(setOfDeclarationDirectories, function (declDirPath) { return dirPath === declDirPath ||
|
|
95979
96009
|
ts.startsWith(declDirPath, dirPathWithTrailingDirectorySeparator) ||
|
|
95980
|
-
ts.startsWith(dirPath, declDirPath
|
|
96010
|
+
ts.startsWith(dirPath, "".concat(declDirPath, "/")); });
|
|
95981
96011
|
}
|
|
95982
96012
|
function handleDirectoryCouldBeSymlink(directory) {
|
|
95983
96013
|
var _a;
|
|
@@ -96025,7 +96055,7 @@ var ts;
|
|
|
96025
96055
|
var result = fileOrDirectoryExistsUsingSource(fileOrDirectoryPath.replace(directoryPath, symlinkedDirectory.realPath));
|
|
96026
96056
|
if (isFile && result) {
|
|
96027
96057
|
var absolutePath = ts.getNormalizedAbsolutePath(fileOrDirectory, host.compilerHost.getCurrentDirectory());
|
|
96028
|
-
symlinkCache.setSymlinkedFile(fileOrDirectoryPath, ""
|
|
96058
|
+
symlinkCache.setSymlinkedFile(fileOrDirectoryPath, "".concat(symlinkedDirectory.real).concat(absolutePath.replace(new RegExp(directoryPath, "i"), "")));
|
|
96029
96059
|
}
|
|
96030
96060
|
return result;
|
|
96031
96061
|
}) || false;
|
|
@@ -96409,7 +96439,7 @@ var ts;
|
|
|
96409
96439
|
var emitOutput_1 = getFileEmitOutput(programOfThisState, sourceFile, true, cancellationToken, undefined, true);
|
|
96410
96440
|
var firstDts_1 = ts.firstOrUndefined(emitOutput_1.outputFiles);
|
|
96411
96441
|
if (firstDts_1) {
|
|
96412
|
-
ts.Debug.assert(ts.fileExtensionIsOneOf(firstDts_1.name, [".d.ts", ".d.mts", ".d.cts"]), "File extension for signature expected to be dts", function () { return "Found: "
|
|
96442
|
+
ts.Debug.assert(ts.fileExtensionIsOneOf(firstDts_1.name, [".d.ts", ".d.mts", ".d.cts"]), "File extension for signature expected to be dts", function () { return "Found: ".concat(ts.getAnyExtensionFromPath(firstDts_1.name), " for ").concat(firstDts_1.name, ":: All output files: ").concat(JSON.stringify(emitOutput_1.outputFiles.map(function (f) { return f.name; }))); });
|
|
96413
96443
|
latestSignature = (computeHash || ts.generateDjb2Hash)(firstDts_1.text);
|
|
96414
96444
|
if (exportedModulesMapCache && latestSignature !== prevSignature) {
|
|
96415
96445
|
updateExportedModules(sourceFile, emitOutput_1.exportedModulesFromDeclarationEmit, exportedModulesMapCache);
|
|
@@ -96805,7 +96835,7 @@ var ts;
|
|
|
96805
96835
|
return;
|
|
96806
96836
|
}
|
|
96807
96837
|
else {
|
|
96808
|
-
ts.Debug.assert(state.hasCalledUpdateShapeSignature.has(affectedFile.resolvedPath) || ((_a = state.currentAffectedFilesSignatures) === null || _a === void 0 ? void 0 : _a.has(affectedFile.resolvedPath)), "Signature not updated for affected file: "
|
|
96838
|
+
ts.Debug.assert(state.hasCalledUpdateShapeSignature.has(affectedFile.resolvedPath) || ((_a = state.currentAffectedFilesSignatures) === null || _a === void 0 ? void 0 : _a.has(affectedFile.resolvedPath)), "Signature not updated for affected file: ".concat(affectedFile.fileName));
|
|
96809
96839
|
}
|
|
96810
96840
|
if (!state.compilerOptions.assumeChangesOnlyAffectDirectDependencies) {
|
|
96811
96841
|
forEachReferencingModulesOfExportOfAffectedFile(state, affectedFile, function (state, path) { return handleDtsMayChangeOf(state, path, cancellationToken, computeHash); });
|
|
@@ -97777,7 +97807,7 @@ var ts;
|
|
|
97777
97807
|
failedLookupLocation = ts.isRootedDiskPath(failedLookupLocation) ? ts.normalizePath(failedLookupLocation) : ts.getNormalizedAbsolutePath(failedLookupLocation, getCurrentDirectory());
|
|
97778
97808
|
var failedLookupPathSplit = failedLookupLocationPath.split(ts.directorySeparator);
|
|
97779
97809
|
var failedLookupSplit = failedLookupLocation.split(ts.directorySeparator);
|
|
97780
|
-
ts.Debug.assert(failedLookupSplit.length === failedLookupPathSplit.length, "FailedLookup: "
|
|
97810
|
+
ts.Debug.assert(failedLookupSplit.length === failedLookupPathSplit.length, "FailedLookup: ".concat(failedLookupLocation, " failedLookupLocationPath: ").concat(failedLookupLocationPath));
|
|
97781
97811
|
if (failedLookupPathSplit.length > rootSplitLength + 1) {
|
|
97782
97812
|
return {
|
|
97783
97813
|
dir: failedLookupSplit.slice(0, rootSplitLength + 1).join(ts.directorySeparator),
|
|
@@ -98616,13 +98646,15 @@ var ts;
|
|
|
98616
98646
|
var moduleFileToTry = path;
|
|
98617
98647
|
if (host.fileExists(packageJsonPath)) {
|
|
98618
98648
|
var packageJsonContent = JSON.parse(host.readFile(packageJsonPath));
|
|
98619
|
-
|
|
98620
|
-
|
|
98621
|
-
|
|
98622
|
-
|
|
98623
|
-
|
|
98624
|
-
|
|
98625
|
-
|
|
98649
|
+
if (ts.getEmitModuleResolutionKind(options) === ts.ModuleResolutionKind.Node12 || ts.getEmitModuleResolutionKind(options) === ts.ModuleResolutionKind.NodeNext) {
|
|
98650
|
+
var fromExports = packageJsonContent.exports && typeof packageJsonContent.name === "string" ? tryGetModuleNameFromExports(options, path, packageRootPath, packageJsonContent.name, packageJsonContent.exports, ["node", "types"]) : undefined;
|
|
98651
|
+
if (fromExports) {
|
|
98652
|
+
var withJsExtension = !ts.hasTSFileExtension(fromExports.moduleFileToTry) ? fromExports : { moduleFileToTry: ts.removeFileExtension(fromExports.moduleFileToTry) + tryGetJSExtensionForFile(fromExports.moduleFileToTry, options) };
|
|
98653
|
+
return __assign(__assign({}, withJsExtension), { verbatimFromExports: true });
|
|
98654
|
+
}
|
|
98655
|
+
if (packageJsonContent.exports) {
|
|
98656
|
+
return { moduleFileToTry: path, blockedByExports: true };
|
|
98657
|
+
}
|
|
98626
98658
|
}
|
|
98627
98659
|
var versionPaths = packageJsonContent.typesVersions
|
|
98628
98660
|
? ts.getPackageJsonTypesVersionsPaths(packageJsonContent.typesVersions)
|
|
@@ -98731,7 +98763,7 @@ var ts;
|
|
|
98731
98763
|
}
|
|
98732
98764
|
function getJSExtensionForFile(fileName, options) {
|
|
98733
98765
|
var _a;
|
|
98734
|
-
return (_a = tryGetJSExtensionForFile(fileName, options)) !== null && _a !== void 0 ? _a : ts.Debug.fail("Extension "
|
|
98766
|
+
return (_a = tryGetJSExtensionForFile(fileName, options)) !== null && _a !== void 0 ? _a : ts.Debug.fail("Extension ".concat(ts.extensionFromPath(fileName), " is unsupported:: FileName:: ").concat(fileName));
|
|
98735
98767
|
}
|
|
98736
98768
|
function tryGetJSExtensionForFile(fileName, options) {
|
|
98737
98769
|
var ext = ts.tryGetExtensionFromPath(fileName);
|
|
@@ -98821,8 +98853,8 @@ var ts;
|
|
|
98821
98853
|
return pretty ?
|
|
98822
98854
|
function (diagnostic, newLine, options) {
|
|
98823
98855
|
clearScreenIfNotWatchingForFileChanges(system, diagnostic, options);
|
|
98824
|
-
var output = "["
|
|
98825
|
-
output += ""
|
|
98856
|
+
var output = "[".concat(ts.formatColorAndReset(getLocaleTimeString(system), ts.ForegroundColorEscapeSequences.Grey), "] ");
|
|
98857
|
+
output += "".concat(ts.flattenDiagnosticMessageText(diagnostic.messageText, system.newLine)).concat(newLine + newLine);
|
|
98826
98858
|
system.write(output);
|
|
98827
98859
|
} :
|
|
98828
98860
|
function (diagnostic, newLine, options) {
|
|
@@ -98830,8 +98862,8 @@ var ts;
|
|
|
98830
98862
|
if (!clearScreenIfNotWatchingForFileChanges(system, diagnostic, options)) {
|
|
98831
98863
|
output += newLine;
|
|
98832
98864
|
}
|
|
98833
|
-
output += getLocaleTimeString(system)
|
|
98834
|
-
output += ""
|
|
98865
|
+
output += "".concat(getLocaleTimeString(system), " - ");
|
|
98866
|
+
output += "".concat(ts.flattenDiagnosticMessageText(diagnostic.messageText, system.newLine)).concat(getPlainDiagnosticFollowingNewLines(diagnostic, newLine));
|
|
98835
98867
|
system.write(output);
|
|
98836
98868
|
};
|
|
98837
98869
|
}
|
|
@@ -98858,7 +98890,7 @@ var ts;
|
|
|
98858
98890
|
if (errorCount === 0)
|
|
98859
98891
|
return "";
|
|
98860
98892
|
var d = ts.createCompilerDiagnostic(errorCount === 1 ? ts.Diagnostics.Found_1_error : ts.Diagnostics.Found_0_errors, errorCount);
|
|
98861
|
-
return ""
|
|
98893
|
+
return "".concat(newLine).concat(ts.flattenDiagnosticMessageText(d.messageText, newLine)).concat(newLine).concat(newLine);
|
|
98862
98894
|
}
|
|
98863
98895
|
ts.getErrorSummaryText = getErrorSummaryText;
|
|
98864
98896
|
function isBuilderProgram(program) {
|
|
@@ -98884,9 +98916,9 @@ var ts;
|
|
|
98884
98916
|
var relativeFileName = function (fileName) { return ts.convertToRelativePath(fileName, program.getCurrentDirectory(), getCanonicalFileName); };
|
|
98885
98917
|
for (var _i = 0, _c = program.getSourceFiles(); _i < _c.length; _i++) {
|
|
98886
98918
|
var file = _c[_i];
|
|
98887
|
-
write(""
|
|
98888
|
-
(_a = reasons.get(file.path)) === null || _a === void 0 ? void 0 : _a.forEach(function (reason) { return write(" "
|
|
98889
|
-
(_b = explainIfFileIsRedirect(file, relativeFileName)) === null || _b === void 0 ? void 0 : _b.forEach(function (d) { return write(" "
|
|
98919
|
+
write("".concat(toFileName(file, relativeFileName)));
|
|
98920
|
+
(_a = reasons.get(file.path)) === null || _a === void 0 ? void 0 : _a.forEach(function (reason) { return write(" ".concat(fileIncludeReasonToDiagnostics(program, reason, relativeFileName).messageText)); });
|
|
98921
|
+
(_b = explainIfFileIsRedirect(file, relativeFileName)) === null || _b === void 0 ? void 0 : _b.forEach(function (d) { return write(" ".concat(d.messageText)); });
|
|
98890
98922
|
}
|
|
98891
98923
|
}
|
|
98892
98924
|
ts.explainFiles = explainFiles;
|
|
@@ -98924,7 +98956,7 @@ var ts;
|
|
|
98924
98956
|
if (isJsonFile && !ts.endsWith(includeSpec, ".json"))
|
|
98925
98957
|
return false;
|
|
98926
98958
|
var pattern = ts.getPatternFromSpec(includeSpec, basePath, "files");
|
|
98927
|
-
return !!pattern && ts.getRegexFromPattern("("
|
|
98959
|
+
return !!pattern && ts.getRegexFromPattern("(".concat(pattern, ")$"), useCaseSensitiveFileNames).test(fileName);
|
|
98928
98960
|
});
|
|
98929
98961
|
}
|
|
98930
98962
|
ts.getMatchedIncludeSpec = getMatchedIncludeSpec;
|
|
@@ -98933,7 +98965,7 @@ var ts;
|
|
|
98933
98965
|
var options = program.getCompilerOptions();
|
|
98934
98966
|
if (ts.isReferencedFile(reason)) {
|
|
98935
98967
|
var referenceLocation = ts.getReferencedFileLocation(function (path) { return program.getSourceFileByPath(path); }, reason);
|
|
98936
|
-
var referenceText = ts.isReferenceFileLocation(referenceLocation) ? referenceLocation.file.text.substring(referenceLocation.pos, referenceLocation.end) : "\""
|
|
98968
|
+
var referenceText = ts.isReferenceFileLocation(referenceLocation) ? referenceLocation.file.text.substring(referenceLocation.pos, referenceLocation.end) : "\"".concat(referenceLocation.text, "\"");
|
|
98937
98969
|
var message = void 0;
|
|
98938
98970
|
ts.Debug.assert(ts.isReferenceFileLocation(referenceLocation) || reason.kind === ts.FileIncludeKind.Import, "Only synthetic references are imports");
|
|
98939
98971
|
switch (reason.kind) {
|
|
@@ -99044,7 +99076,7 @@ var ts;
|
|
|
99044
99076
|
var currentDir_1 = program.getCurrentDirectory();
|
|
99045
99077
|
ts.forEach(emittedFiles, function (file) {
|
|
99046
99078
|
var filepath = ts.getNormalizedAbsolutePath(file, currentDir_1);
|
|
99047
|
-
write("TSFILE: "
|
|
99079
|
+
write("TSFILE: ".concat(filepath));
|
|
99048
99080
|
});
|
|
99049
99081
|
listFiles(program, write);
|
|
99050
99082
|
}
|
|
@@ -99350,7 +99382,7 @@ var ts;
|
|
|
99350
99382
|
}
|
|
99351
99383
|
var _b = ts.createWatchFactory(host, compilerOptions), watchFile = _b.watchFile, watchDirectory = _b.watchDirectory, writeLog = _b.writeLog;
|
|
99352
99384
|
var getCanonicalFileName = ts.createGetCanonicalFileName(useCaseSensitiveFileNames);
|
|
99353
|
-
writeLog("Current directory: "
|
|
99385
|
+
writeLog("Current directory: ".concat(currentDirectory, " CaseSensitiveFileNames: ").concat(useCaseSensitiveFileNames));
|
|
99354
99386
|
var configFileWatcher;
|
|
99355
99387
|
if (configFileName) {
|
|
99356
99388
|
configFileWatcher = watchFile(configFileName, scheduleProgramReload, ts.PollingInterval.High, watchOptions, ts.WatchType.ConfigFile);
|
|
@@ -99490,10 +99522,10 @@ var ts;
|
|
|
99490
99522
|
}
|
|
99491
99523
|
function createNewProgram(hasInvalidatedResolution) {
|
|
99492
99524
|
writeLog("CreatingProgramWith::");
|
|
99493
|
-
writeLog(" roots: "
|
|
99494
|
-
writeLog(" options: "
|
|
99525
|
+
writeLog(" roots: ".concat(JSON.stringify(rootFileNames)));
|
|
99526
|
+
writeLog(" options: ".concat(JSON.stringify(compilerOptions)));
|
|
99495
99527
|
if (projectReferences)
|
|
99496
|
-
writeLog(" projectReferences: "
|
|
99528
|
+
writeLog(" projectReferences: ".concat(JSON.stringify(projectReferences)));
|
|
99497
99529
|
var needsUpdateInTypeRootWatch = hasChangedCompilerOptions || !getCurrentProgram();
|
|
99498
99530
|
hasChangedCompilerOptions = false;
|
|
99499
99531
|
hasChangedConfigFileParsingErrors = false;
|
|
@@ -99635,7 +99667,7 @@ var ts;
|
|
|
99635
99667
|
return resolutionCache.invalidateResolutionsOfFailedLookupLocations();
|
|
99636
99668
|
}
|
|
99637
99669
|
var pending = clearInvalidateResolutionsOfFailedLookupLocations();
|
|
99638
|
-
writeLog("Scheduling invalidateFailedLookup"
|
|
99670
|
+
writeLog("Scheduling invalidateFailedLookup".concat(pending ? ", Cancelled earlier one" : ""));
|
|
99639
99671
|
timerToInvalidateFailedLookupResolutions = host.setTimeout(invalidateResolutionsOfFailedLookup, 250);
|
|
99640
99672
|
}
|
|
99641
99673
|
function invalidateResolutionsOfFailedLookup() {
|
|
@@ -99691,7 +99723,7 @@ var ts;
|
|
|
99691
99723
|
synchronizeProgram();
|
|
99692
99724
|
}
|
|
99693
99725
|
function reloadConfigFile() {
|
|
99694
|
-
writeLog("Reloading config file: "
|
|
99726
|
+
writeLog("Reloading config file: ".concat(configFileName));
|
|
99695
99727
|
reloadLevel = ts.ConfigFileProgramReloadLevel.None;
|
|
99696
99728
|
if (cachedDirectoryStructureHost) {
|
|
99697
99729
|
cachedDirectoryStructureHost.clearCache();
|
|
@@ -99729,7 +99761,7 @@ var ts;
|
|
|
99729
99761
|
return config.parsedCommandLine;
|
|
99730
99762
|
}
|
|
99731
99763
|
}
|
|
99732
|
-
writeLog("Loading config file: "
|
|
99764
|
+
writeLog("Loading config file: ".concat(configFileName));
|
|
99733
99765
|
var parsedCommandLine = host.getParsedCommandLine ?
|
|
99734
99766
|
host.getParsedCommandLine(configFileName) :
|
|
99735
99767
|
getParsedCommandLineFromConfigFileHost(configFileName);
|
|
@@ -99982,8 +100014,8 @@ var ts;
|
|
|
99982
100014
|
ts.getBuildOrderFromAnyBuildOrder = getBuildOrderFromAnyBuildOrder;
|
|
99983
100015
|
function createBuilderStatusReporter(system, pretty) {
|
|
99984
100016
|
return function (diagnostic) {
|
|
99985
|
-
var output = pretty ? "["
|
|
99986
|
-
output += ""
|
|
100017
|
+
var output = pretty ? "[".concat(ts.formatColorAndReset(ts.getLocaleTimeString(system), ts.ForegroundColorEscapeSequences.Grey), "] ") : "".concat(ts.getLocaleTimeString(system), " - ");
|
|
100018
|
+
output += "".concat(ts.flattenDiagnosticMessageText(diagnostic.messageText, system.newLine)).concat(system.newLine + system.newLine);
|
|
99987
100019
|
system.write(output);
|
|
99988
100020
|
};
|
|
99989
100021
|
}
|
|
@@ -100726,7 +100758,7 @@ var ts;
|
|
|
100726
100758
|
function listEmittedFile(_a, proj, file) {
|
|
100727
100759
|
var write = _a.write;
|
|
100728
100760
|
if (write && proj.options.listEmittedFiles) {
|
|
100729
|
-
write("TSFILE: "
|
|
100761
|
+
write("TSFILE: ".concat(file));
|
|
100730
100762
|
}
|
|
100731
100763
|
}
|
|
100732
100764
|
function getOldProgram(_a, proj, parsed) {
|
|
@@ -100755,7 +100787,7 @@ var ts;
|
|
|
100755
100787
|
function buildErrors(state, resolvedPath, program, config, diagnostics, buildResult, errorType) {
|
|
100756
100788
|
var canEmitBuildInfo = !(buildResult & BuildResultFlags.SyntaxErrors) && program && !ts.outFile(program.getCompilerOptions());
|
|
100757
100789
|
reportAndStoreErrors(state, resolvedPath, diagnostics);
|
|
100758
|
-
state.projectStatus.set(resolvedPath, { type: ts.UpToDateStatusType.Unbuildable, reason: errorType
|
|
100790
|
+
state.projectStatus.set(resolvedPath, { type: ts.UpToDateStatusType.Unbuildable, reason: "".concat(errorType, " errors") });
|
|
100759
100791
|
if (canEmitBuildInfo)
|
|
100760
100792
|
return { buildResult: buildResult, step: BuildStep.EmitBuildInfo };
|
|
100761
100793
|
afterProgramDone(state, program, config);
|
|
@@ -100781,7 +100813,7 @@ var ts;
|
|
|
100781
100813
|
if (!host.fileExists(inputFile)) {
|
|
100782
100814
|
return {
|
|
100783
100815
|
type: ts.UpToDateStatusType.Unbuildable,
|
|
100784
|
-
reason: inputFile
|
|
100816
|
+
reason: "".concat(inputFile, " does not exist")
|
|
100785
100817
|
};
|
|
100786
100818
|
}
|
|
100787
100819
|
if (!force) {
|
|
@@ -101106,7 +101138,7 @@ var ts;
|
|
|
101106
101138
|
}
|
|
101107
101139
|
}
|
|
101108
101140
|
if (filesToDelete) {
|
|
101109
|
-
reportStatus(state, ts.Diagnostics.A_non_dry_build_would_delete_the_following_files_Colon_0, filesToDelete.map(function (f) { return "\r\n * "
|
|
101141
|
+
reportStatus(state, ts.Diagnostics.A_non_dry_build_would_delete_the_following_files_Colon_0, filesToDelete.map(function (f) { return "\r\n * ".concat(f); }).join(""));
|
|
101110
101142
|
}
|
|
101111
101143
|
return ts.ExitStatus.Success;
|
|
101112
101144
|
}
|
|
@@ -101451,7 +101483,7 @@ var ts;
|
|
|
101451
101483
|
};
|
|
101452
101484
|
}
|
|
101453
101485
|
function bold(str) {
|
|
101454
|
-
return "\u001B[1m"
|
|
101486
|
+
return "\u001B[1m".concat(str, "\u001B[22m");
|
|
101455
101487
|
}
|
|
101456
101488
|
var isWindows = sys.getEnvironmentVariable("OS") && ts.stringContains(sys.getEnvironmentVariable("OS").toLowerCase(), "windows");
|
|
101457
101489
|
var isWindowsTerminal = sys.getEnvironmentVariable("WT_SESSION");
|
|
@@ -101460,19 +101492,19 @@ var ts;
|
|
|
101460
101492
|
if (isWindows && !isWindowsTerminal && !isVSCode) {
|
|
101461
101493
|
return brightWhite(str);
|
|
101462
101494
|
}
|
|
101463
|
-
return "\u001B[94m"
|
|
101495
|
+
return "\u001B[94m".concat(str, "\u001B[39m");
|
|
101464
101496
|
}
|
|
101465
101497
|
var supportsRicherColors = sys.getEnvironmentVariable("COLORTERM") === "truecolor" || sys.getEnvironmentVariable("TERM") === "xterm-256color";
|
|
101466
101498
|
function blueBackground(str) {
|
|
101467
101499
|
if (supportsRicherColors) {
|
|
101468
|
-
return "\u001B[48;5;68m"
|
|
101500
|
+
return "\u001B[48;5;68m".concat(str, "\u001B[39;49m");
|
|
101469
101501
|
}
|
|
101470
101502
|
else {
|
|
101471
|
-
return "\u001B[44m"
|
|
101503
|
+
return "\u001B[44m".concat(str, "\u001B[39;49m");
|
|
101472
101504
|
}
|
|
101473
101505
|
}
|
|
101474
101506
|
function brightWhite(str) {
|
|
101475
|
-
return "\u001B[97m"
|
|
101507
|
+
return "\u001B[97m".concat(str, "\u001B[39m");
|
|
101476
101508
|
}
|
|
101477
101509
|
return {
|
|
101478
101510
|
bold: bold,
|
|
@@ -101482,7 +101514,7 @@ var ts;
|
|
|
101482
101514
|
};
|
|
101483
101515
|
}
|
|
101484
101516
|
function getDisplayNameTextOfOption(option) {
|
|
101485
|
-
return "--"
|
|
101517
|
+
return "--".concat(option.name).concat(option.shortName ? ", -".concat(option.shortName) : "");
|
|
101486
101518
|
}
|
|
101487
101519
|
function generateOptionOutput(sys, option, rightAlignOfLeft, leftAlignOfRight) {
|
|
101488
101520
|
var _a, _b;
|
|
@@ -101517,13 +101549,13 @@ var ts;
|
|
|
101517
101549
|
text.push(sys.newLine);
|
|
101518
101550
|
if (showAdditionalInfoOutput(valueCandidates, option)) {
|
|
101519
101551
|
if (valueCandidates) {
|
|
101520
|
-
text.push(valueCandidates.valueType
|
|
101552
|
+
text.push("".concat(valueCandidates.valueType, " ").concat(valueCandidates.possibleValues));
|
|
101521
101553
|
}
|
|
101522
101554
|
if (defaultValueDescription) {
|
|
101523
101555
|
if (valueCandidates)
|
|
101524
101556
|
text.push(sys.newLine);
|
|
101525
101557
|
var diagType = ts.getDiagnosticText(ts.Diagnostics.default_Colon);
|
|
101526
|
-
text.push(diagType
|
|
101558
|
+
text.push("".concat(diagType, " ").concat(defaultValueDescription));
|
|
101527
101559
|
}
|
|
101528
101560
|
text.push(sys.newLine);
|
|
101529
101561
|
}
|
|
@@ -101558,7 +101590,7 @@ var ts;
|
|
|
101558
101590
|
}
|
|
101559
101591
|
var curRight = remainRight.substr(0, rightCharacterNumber);
|
|
101560
101592
|
remainRight = remainRight.slice(rightCharacterNumber);
|
|
101561
|
-
res.push(""
|
|
101593
|
+
res.push("".concat(curLeft).concat(curRight));
|
|
101562
101594
|
isFirstLine = false;
|
|
101563
101595
|
}
|
|
101564
101596
|
return res;
|
|
@@ -101651,7 +101683,7 @@ var ts;
|
|
|
101651
101683
|
categoryMap.set(curCategory, optionsOfCurCategory);
|
|
101652
101684
|
}
|
|
101653
101685
|
categoryMap.forEach(function (value, key) {
|
|
101654
|
-
res.push("### "
|
|
101686
|
+
res.push("### ".concat(key).concat(sys.newLine).concat(sys.newLine));
|
|
101655
101687
|
res = __spreadArray(__spreadArray([], res, true), generateGroupOptionOutput(sys, value), true);
|
|
101656
101688
|
});
|
|
101657
101689
|
if (afterOptionsDescription) {
|
|
@@ -101661,7 +101693,7 @@ var ts;
|
|
|
101661
101693
|
}
|
|
101662
101694
|
function printEasyHelp(sys, simpleOptions) {
|
|
101663
101695
|
var colors = createColors(sys);
|
|
101664
|
-
var output = __spreadArray([], getHeader(sys, ts.getDiagnosticText(ts.Diagnostics.tsc_Colon_The_TypeScript_Compiler)
|
|
101696
|
+
var output = __spreadArray([], getHeader(sys, "".concat(ts.getDiagnosticText(ts.Diagnostics.tsc_Colon_The_TypeScript_Compiler), " - ").concat(ts.getDiagnosticText(ts.Diagnostics.Version_0, ts.version))), true);
|
|
101665
101697
|
output.push(colors.bold(ts.getDiagnosticText(ts.Diagnostics.COMMON_COMMANDS)) + sys.newLine + sys.newLine);
|
|
101666
101698
|
example("tsc", ts.Diagnostics.Compiles_the_current_project_tsconfig_json_in_the_working_directory);
|
|
101667
101699
|
example("tsc app.ts util.ts", ts.Diagnostics.Ignoring_tsconfig_json_compiles_the_specified_files_with_default_compiler_options);
|
|
@@ -101687,7 +101719,7 @@ var ts;
|
|
|
101687
101719
|
}
|
|
101688
101720
|
}
|
|
101689
101721
|
function printAllHelp(sys, compilerOptions, buildOptions, watchOptions) {
|
|
101690
|
-
var output = __spreadArray([], getHeader(sys, ts.getDiagnosticText(ts.Diagnostics.tsc_Colon_The_TypeScript_Compiler)
|
|
101722
|
+
var output = __spreadArray([], getHeader(sys, "".concat(ts.getDiagnosticText(ts.Diagnostics.tsc_Colon_The_TypeScript_Compiler), " - ").concat(ts.getDiagnosticText(ts.Diagnostics.Version_0, ts.version))), true);
|
|
101691
101723
|
output = __spreadArray(__spreadArray([], output, true), generateSectionOptionsOutput(sys, ts.getDiagnosticText(ts.Diagnostics.ALL_COMPILER_OPTIONS), compilerOptions, true, undefined, ts.formatMessage(undefined, ts.Diagnostics.You_can_learn_about_all_of_the_compiler_options_at_0, "https://aka.ms/tsconfig-reference")), true);
|
|
101692
101724
|
output = __spreadArray(__spreadArray([], output, true), generateSectionOptionsOutput(sys, ts.getDiagnosticText(ts.Diagnostics.WATCH_OPTIONS), watchOptions, false, ts.getDiagnosticText(ts.Diagnostics.Including_watch_w_will_start_watching_the_current_project_for_the_file_changes_Once_set_you_can_config_watch_mode_with_Colon)), true);
|
|
101693
101725
|
output = __spreadArray(__spreadArray([], output, true), generateSectionOptionsOutput(sys, ts.getDiagnosticText(ts.Diagnostics.BUILD_OPTIONS), buildOptions, false, ts.formatMessage(undefined, ts.Diagnostics.Using_build_b_will_make_tsc_behave_more_like_a_build_orchestrator_than_a_compiler_This_is_used_to_trigger_building_composite_projects_which_you_can_learn_more_about_at_0, "https://aka.ms/tsc-composite-builds")), true);
|
|
@@ -101697,7 +101729,7 @@ var ts;
|
|
|
101697
101729
|
}
|
|
101698
101730
|
}
|
|
101699
101731
|
function printBuildHelp(sys, buildOptions) {
|
|
101700
|
-
var output = __spreadArray([], getHeader(sys, ts.getDiagnosticText(ts.Diagnostics.tsc_Colon_The_TypeScript_Compiler)
|
|
101732
|
+
var output = __spreadArray([], getHeader(sys, "".concat(ts.getDiagnosticText(ts.Diagnostics.tsc_Colon_The_TypeScript_Compiler), " - ").concat(ts.getDiagnosticText(ts.Diagnostics.Version_0, ts.version))), true);
|
|
101701
101733
|
output = __spreadArray(__spreadArray([], output, true), generateSectionOptionsOutput(sys, ts.getDiagnosticText(ts.Diagnostics.BUILD_OPTIONS), buildOptions, false, ts.formatMessage(undefined, ts.Diagnostics.Using_build_b_will_make_tsc_behave_more_like_a_build_orchestrator_than_a_compiler_This_is_used_to_trigger_building_composite_projects_which_you_can_learn_more_about_at_0, "https://aka.ms/tsc-composite-builds")), true);
|
|
101702
101734
|
for (var _i = 0, output_3 = output; _i < output_3.length; _i++) {
|
|
101703
101735
|
var line = output_3[_i];
|
|
@@ -102078,7 +102110,7 @@ var ts;
|
|
|
102078
102110
|
reportCountStatistic("Subtype cache size", caches.subtype);
|
|
102079
102111
|
reportCountStatistic("Strict subtype cache size", caches.strictSubtype);
|
|
102080
102112
|
if (isPerformanceEnabled) {
|
|
102081
|
-
ts.performance.forEachMeasure(function (name, duration) { return reportTimeStatistic(name
|
|
102113
|
+
ts.performance.forEachMeasure(function (name, duration) { return reportTimeStatistic("".concat(name, " time"), duration); });
|
|
102082
102114
|
}
|
|
102083
102115
|
}
|
|
102084
102116
|
else if (isPerformanceEnabled) {
|
|
@@ -102149,7 +102181,7 @@ var ts;
|
|
|
102149
102181
|
// This file actually uses arguments passed on commandline and executes it
|
|
102150
102182
|
ts.Debug.loggingHost = {
|
|
102151
102183
|
log: function (_level, s) {
|
|
102152
|
-
ts.sys.write(""
|
|
102184
|
+
ts.sys.write("".concat(s || "").concat(ts.sys.newLine));
|
|
102153
102185
|
}
|
|
102154
102186
|
};
|
|
102155
102187
|
if (ts.Debug.isDebugging) {
|