typescript 6.0.0-dev.20260401 → 6.0.0-dev.20260416
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/_tsc.js +2 -2
- package/lib/lib.es5.d.ts +2 -2
- package/lib/typescript.js +24 -7
- package/package.json +2 -2
package/lib/_tsc.js
CHANGED
|
@@ -18,7 +18,7 @@ and limitations under the License.
|
|
|
18
18
|
|
|
19
19
|
// src/compiler/corePublic.ts
|
|
20
20
|
var versionMajorMinor = "6.0";
|
|
21
|
-
var version = `${versionMajorMinor}.0-dev.
|
|
21
|
+
var version = `${versionMajorMinor}.0-dev.20260416`;
|
|
22
22
|
|
|
23
23
|
// src/compiler/core.ts
|
|
24
24
|
var emptyArray = [];
|
|
@@ -6045,7 +6045,7 @@ var Diagnostics = {
|
|
|
6045
6045
|
Module_0_does_not_refer_to_a_type_but_is_used_as_a_type_here_Did_you_mean_typeof_import_0: diag(1340, 1 /* Error */, "Module_0_does_not_refer_to_a_type_but_is_used_as_a_type_here_Did_you_mean_typeof_import_0_1340", "Module '{0}' does not refer to a type, but is used as a type here. Did you mean 'typeof import('{0}')'?"),
|
|
6046
6046
|
Class_constructor_may_not_be_an_accessor: diag(1341, 1 /* Error */, "Class_constructor_may_not_be_an_accessor_1341", "Class constructor may not be an accessor."),
|
|
6047
6047
|
The_import_meta_meta_property_is_only_allowed_when_the_module_option_is_es2020_es2022_esnext_system_node16_node18_node20_or_nodenext: diag(1343, 1 /* Error */, "The_import_meta_meta_property_is_only_allowed_when_the_module_option_is_es2020_es2022_esnext_system__1343", "The 'import.meta' meta-property is only allowed when the '--module' option is 'es2020', 'es2022', 'esnext', 'system', 'node16', 'node18', 'node20', or 'nodenext'."),
|
|
6048
|
-
A_label_is_not_allowed_here: diag(1344, 1 /* Error */, "A_label_is_not_allowed_here_1344", "
|
|
6048
|
+
A_label_is_not_allowed_here: diag(1344, 1 /* Error */, "A_label_is_not_allowed_here_1344", "A label is not allowed here."),
|
|
6049
6049
|
An_expression_of_type_void_cannot_be_tested_for_truthiness: diag(1345, 1 /* Error */, "An_expression_of_type_void_cannot_be_tested_for_truthiness_1345", "An expression of type 'void' cannot be tested for truthiness."),
|
|
6050
6050
|
This_parameter_is_not_allowed_with_use_strict_directive: diag(1346, 1 /* Error */, "This_parameter_is_not_allowed_with_use_strict_directive_1346", "This parameter is not allowed with 'use strict' directive."),
|
|
6051
6051
|
use_strict_directive_cannot_be_used_with_non_simple_parameter_list: diag(1347, 1 /* Error */, "use_strict_directive_cannot_be_used_with_non_simple_parameter_list_1347", "'use strict' directive cannot be used with non-simple parameter list."),
|
package/lib/lib.es5.d.ts
CHANGED
|
@@ -416,8 +416,8 @@ interface String {
|
|
|
416
416
|
charAt(pos: number): string;
|
|
417
417
|
|
|
418
418
|
/**
|
|
419
|
-
* Returns the Unicode value of the character at the specified location.
|
|
420
|
-
* @param index The zero-based index of the desired character.
|
|
419
|
+
* Returns the Unicode value of the character at the specified location, or NaN if the index is out of bounds.
|
|
420
|
+
* @param index The zero-based index of the desired character.
|
|
421
421
|
*/
|
|
422
422
|
charCodeAt(index: number): number;
|
|
423
423
|
|
package/lib/typescript.js
CHANGED
|
@@ -2289,7 +2289,7 @@ module.exports = __toCommonJS(typescript_exports);
|
|
|
2289
2289
|
|
|
2290
2290
|
// src/compiler/corePublic.ts
|
|
2291
2291
|
var versionMajorMinor = "6.0";
|
|
2292
|
-
var version = `${versionMajorMinor}.0-dev.
|
|
2292
|
+
var version = `${versionMajorMinor}.0-dev.20260416`;
|
|
2293
2293
|
var Comparison = /* @__PURE__ */ ((Comparison3) => {
|
|
2294
2294
|
Comparison3[Comparison3["LessThan"] = -1] = "LessThan";
|
|
2295
2295
|
Comparison3[Comparison3["EqualTo"] = 0] = "EqualTo";
|
|
@@ -9451,7 +9451,7 @@ var Diagnostics = {
|
|
|
9451
9451
|
Module_0_does_not_refer_to_a_type_but_is_used_as_a_type_here_Did_you_mean_typeof_import_0: diag(1340, 1 /* Error */, "Module_0_does_not_refer_to_a_type_but_is_used_as_a_type_here_Did_you_mean_typeof_import_0_1340", "Module '{0}' does not refer to a type, but is used as a type here. Did you mean 'typeof import('{0}')'?"),
|
|
9452
9452
|
Class_constructor_may_not_be_an_accessor: diag(1341, 1 /* Error */, "Class_constructor_may_not_be_an_accessor_1341", "Class constructor may not be an accessor."),
|
|
9453
9453
|
The_import_meta_meta_property_is_only_allowed_when_the_module_option_is_es2020_es2022_esnext_system_node16_node18_node20_or_nodenext: diag(1343, 1 /* Error */, "The_import_meta_meta_property_is_only_allowed_when_the_module_option_is_es2020_es2022_esnext_system__1343", "The 'import.meta' meta-property is only allowed when the '--module' option is 'es2020', 'es2022', 'esnext', 'system', 'node16', 'node18', 'node20', or 'nodenext'."),
|
|
9454
|
-
A_label_is_not_allowed_here: diag(1344, 1 /* Error */, "A_label_is_not_allowed_here_1344", "
|
|
9454
|
+
A_label_is_not_allowed_here: diag(1344, 1 /* Error */, "A_label_is_not_allowed_here_1344", "A label is not allowed here."),
|
|
9455
9455
|
An_expression_of_type_void_cannot_be_tested_for_truthiness: diag(1345, 1 /* Error */, "An_expression_of_type_void_cannot_be_tested_for_truthiness_1345", "An expression of type 'void' cannot be tested for truthiness."),
|
|
9456
9456
|
This_parameter_is_not_allowed_with_use_strict_directive: diag(1346, 1 /* Error */, "This_parameter_is_not_allowed_with_use_strict_directive_1346", "This parameter is not allowed with 'use strict' directive."),
|
|
9457
9457
|
use_strict_directive_cannot_be_used_with_non_simple_parameter_list: diag(1347, 1 /* Error */, "use_strict_directive_cannot_be_used_with_non_simple_parameter_list_1347", "'use strict' directive cannot be used with non-simple parameter list."),
|
|
@@ -139653,7 +139653,8 @@ var NameValidationResult = /* @__PURE__ */ ((NameValidationResult2) => {
|
|
|
139653
139653
|
NameValidationResult2[NameValidationResult2["NameTooLong"] = 2] = "NameTooLong";
|
|
139654
139654
|
NameValidationResult2[NameValidationResult2["NameStartsWithDot"] = 3] = "NameStartsWithDot";
|
|
139655
139655
|
NameValidationResult2[NameValidationResult2["NameStartsWithUnderscore"] = 4] = "NameStartsWithUnderscore";
|
|
139656
|
-
NameValidationResult2[NameValidationResult2["
|
|
139656
|
+
NameValidationResult2[NameValidationResult2["NameContainsInvalidCharacters"] = 5] = "NameContainsInvalidCharacters";
|
|
139657
|
+
NameValidationResult2[NameValidationResult2["NameContainsNonURISafeCharacters"] = 5 /* NameContainsInvalidCharacters */] = "NameContainsNonURISafeCharacters";
|
|
139657
139658
|
return NameValidationResult2;
|
|
139658
139659
|
})(NameValidationResult || {});
|
|
139659
139660
|
var maxPackageNameLength = 214;
|
|
@@ -139699,8 +139700,8 @@ function validatePackageNameWorker(packageName, supportScopedPackage) {
|
|
|
139699
139700
|
return 0 /* Ok */;
|
|
139700
139701
|
}
|
|
139701
139702
|
}
|
|
139702
|
-
if (
|
|
139703
|
-
return 5 /*
|
|
139703
|
+
if (!/^[\w.-]+$/.test(packageName)) {
|
|
139704
|
+
return 5 /* NameContainsInvalidCharacters */;
|
|
139704
139705
|
}
|
|
139705
139706
|
return 0 /* Ok */;
|
|
139706
139707
|
}
|
|
@@ -139724,8 +139725,8 @@ function renderPackageNameValidationFailureWorker(typing, result, name, isScopeN
|
|
|
139724
139725
|
return `'${typing}':: ${kind} name '${name}' cannot start with '.'`;
|
|
139725
139726
|
case 4 /* NameStartsWithUnderscore */:
|
|
139726
139727
|
return `'${typing}':: ${kind} name '${name}' cannot start with '_'`;
|
|
139727
|
-
case 5 /*
|
|
139728
|
-
return `'${typing}':: ${kind} name '${name}' contains
|
|
139728
|
+
case 5 /* NameContainsInvalidCharacters */:
|
|
139729
|
+
return `'${typing}':: ${kind} name '${name}' contains invalid characters`;
|
|
139729
139730
|
case 0 /* Ok */:
|
|
139730
139731
|
return Debug.fail();
|
|
139731
139732
|
// Shouldn't have called this.
|
|
@@ -186598,6 +186599,22 @@ var TypingsInstaller = class {
|
|
|
186598
186599
|
/** @internal */
|
|
186599
186600
|
installPackage(req) {
|
|
186600
186601
|
const { fileName, packageName, projectName, projectRootPath, id } = req;
|
|
186602
|
+
const validationResult = ts_JsTyping_exports.validatePackageName(packageName);
|
|
186603
|
+
if (validationResult !== ts_JsTyping_exports.NameValidationResult.Ok) {
|
|
186604
|
+
const message = ts_JsTyping_exports.renderPackageNameValidationFailure(validationResult, packageName);
|
|
186605
|
+
if (this.log.isEnabled()) {
|
|
186606
|
+
this.log.writeLine(message);
|
|
186607
|
+
}
|
|
186608
|
+
const response = {
|
|
186609
|
+
kind: ActionPackageInstalled,
|
|
186610
|
+
projectName,
|
|
186611
|
+
id,
|
|
186612
|
+
success: false,
|
|
186613
|
+
message
|
|
186614
|
+
};
|
|
186615
|
+
this.sendResponse(response);
|
|
186616
|
+
return;
|
|
186617
|
+
}
|
|
186601
186618
|
const cwd = forEachAncestorDirectory(getDirectoryPath(fileName), (directory) => {
|
|
186602
186619
|
if (this.installTypingHost.fileExists(combinePaths(directory, "package.json"))) {
|
|
186603
186620
|
return directory;
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "typescript",
|
|
3
3
|
"author": "Microsoft Corp.",
|
|
4
4
|
"homepage": "https://www.typescriptlang.org/",
|
|
5
|
-
"version": "6.0.0-dev.
|
|
5
|
+
"version": "6.0.0-dev.20260416",
|
|
6
6
|
"license": "Apache-2.0",
|
|
7
7
|
"description": "TypeScript is a language for application scale JavaScript development",
|
|
8
8
|
"keywords": [
|
|
@@ -114,5 +114,5 @@
|
|
|
114
114
|
"node": "22.22.0",
|
|
115
115
|
"npm": "8.19.4"
|
|
116
116
|
},
|
|
117
|
-
"gitHead": "
|
|
117
|
+
"gitHead": "f1a9288c23c04e785bbfb092077a7b70747c5b76"
|
|
118
118
|
}
|