typescript 4.5.0-dev.20211029 → 4.5.0-dev.20211030

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.
@@ -839,6 +839,7 @@
839
839
  "JSDoc_typedef_tag_should_either_have_a_type_annotation_or_be_followed_by_property_or_member_tags_8021": "Značka JSDoc @typedef by měla mít poznámku k typu nebo by za ní měly následovat značky @property nebo @member.",
840
840
  "JSDoc_types_can_only_be_used_inside_documentation_comments_8020": "Typy JSDoc se můžou používat jenom v dokumentačních komentářích.",
841
841
  "JSDoc_types_may_be_moved_to_TypeScript_types_80004": "Typy JSDoc se můžou přesunout na typy TypeScript.",
842
+ "JSON_imports_are_experimental_in_ES_module_mode_imports_7062": "Importy JSON jsou v importech režimu modulu ES experimentální.",
842
843
  "JSX_attributes_must_only_be_assigned_a_non_empty_expression_17000": "Atributy JSX musí mít přiřazený neprázdný výraz.",
843
844
  "JSX_element_0_has_no_corresponding_closing_tag_17008": "Element JSX {0} nemá odpovídající uzavírací značku.",
844
845
  "JSX_element_class_does_not_support_attributes_because_it_does_not_have_a_0_property_2607": "Třída elementu JSX nepodporuje atributy, protože nemá vlastnost {0}.",
@@ -839,6 +839,7 @@
839
839
  "JSDoc_typedef_tag_should_either_have_a_type_annotation_or_be_followed_by_property_or_member_tags_8021": "Das JSDoc-Tag \"@typedef\" muss entweder eine Typanmerkung aufweisen, oder die Tags \"@property\" oder \"@member\" müssen darauf folgen.",
840
840
  "JSDoc_types_can_only_be_used_inside_documentation_comments_8020": "JSDoc-Typen können nur innerhalb von Dokumentationskommentaren verwendet werden.",
841
841
  "JSDoc_types_may_be_moved_to_TypeScript_types_80004": "JSDoc-Typen können in TypeScript-Typen verschoben werden.",
842
+ "JSON_imports_are_experimental_in_ES_module_mode_imports_7062": "JSON-Importe sind experimentell in Importen im ES-Modulmodus.",
842
843
  "JSX_attributes_must_only_be_assigned_a_non_empty_expression_17000": "JSX-Attributen darf nur ein nicht leeres expression-Objekt zugewiesen werden.",
843
844
  "JSX_element_0_has_no_corresponding_closing_tag_17008": "Das JSX-Element \"{0}\" weist kein entsprechendes schließendes Tag auf.",
844
845
  "JSX_element_class_does_not_support_attributes_because_it_does_not_have_a_0_property_2607": "Die JSX-Elementklasse unterstützt keine Attribute, weil sie keine Eigenschaft \"{0}\" aufweist.",
@@ -839,6 +839,7 @@
839
839
  "JSDoc_typedef_tag_should_either_have_a_type_annotation_or_be_followed_by_property_or_member_tags_8021": "La balise JSDoc '@typedef' doit avoir une annotation de type ou être suivie des balises '@property' ou '@member'.",
840
840
  "JSDoc_types_can_only_be_used_inside_documentation_comments_8020": "Les types JSDoc peuvent uniquement être utilisés dans les commentaires de la documentation.",
841
841
  "JSDoc_types_may_be_moved_to_TypeScript_types_80004": "Les types JSDoc peuvent être déplacés vers les types TypeScript.",
842
+ "JSON_imports_are_experimental_in_ES_module_mode_imports_7062": "Les importations JSON sont expérimentales dans les importations en mode module ES.",
842
843
  "JSX_attributes_must_only_be_assigned_a_non_empty_expression_17000": "Les attributs JSX doivent uniquement être attribués à une 'expression' non vide.",
843
844
  "JSX_element_0_has_no_corresponding_closing_tag_17008": "L'élément JSX '{0}' n'a pas de balise de fermeture correspondante.",
844
845
  "JSX_element_class_does_not_support_attributes_because_it_does_not_have_a_0_property_2607": "La classe de l'élément JSX ne prend pas en charge les attributs, car elle n'a pas de propriété '{0}'.",
@@ -839,6 +839,7 @@
839
839
  "JSDoc_typedef_tag_should_either_have_a_type_annotation_or_be_followed_by_property_or_member_tags_8021": "Il tag '@typedef' di JSDoc deve contenere un'annotazione di tipo o essere seguito dal tag '@property' o '@member'.",
840
840
  "JSDoc_types_can_only_be_used_inside_documentation_comments_8020": "I tipi JSDoc possono essere usati solo nei commenti della documentazione.",
841
841
  "JSDoc_types_may_be_moved_to_TypeScript_types_80004": "I tipi JSDoc possono essere convertiti in tipi TypeScript.",
842
+ "JSON_imports_are_experimental_in_ES_module_mode_imports_7062": "Le importazioni JSON sono sperimentali nelle importazioni in modalità modulo ES.",
842
843
  "JSX_attributes_must_only_be_assigned_a_non_empty_expression_17000": "Agli attributi JSX deve essere assegnato solo un elemento 'expression' non vuoto.",
843
844
  "JSX_element_0_has_no_corresponding_closing_tag_17008": "Per l'elemento JSX '{0}' non esiste alcun tag di chiusura corrispondente.",
844
845
  "JSX_element_class_does_not_support_attributes_because_it_does_not_have_a_0_property_2607": "La classe dell'elemento JSX non supporta gli attributi perché non contiene una proprietà '{0}'.",
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 = ts.versionMajorMinor + ".0-dev.20211029";
72
+ ts.version = ts.versionMajorMinor + ".0-dev.20211030";
73
73
  var NativeCollections;
74
74
  (function (NativeCollections) {
75
75
  function tryGetNativeMap() {
@@ -5910,6 +5910,8 @@ var ts;
5910
5910
  Import_assertions_are_only_supported_when_the_module_option_is_set_to_esnext: diag(2821, ts.DiagnosticCategory.Error, "Import_assertions_are_only_supported_when_the_module_option_is_set_to_esnext_2821", "Import assertions are only supported when the '--module' option is set to 'esnext'."),
5911
5911
  Import_assertions_cannot_be_used_with_type_only_imports_or_exports: diag(2822, ts.DiagnosticCategory.Error, "Import_assertions_cannot_be_used_with_type_only_imports_or_exports_2822", "Import assertions cannot be used with type-only imports or exports."),
5912
5912
  Cannot_find_namespace_0_Did_you_mean_1: diag(2833, ts.DiagnosticCategory.Error, "Cannot_find_namespace_0_Did_you_mean_1_2833", "Cannot find namespace '{0}'. Did you mean '{1}'?"),
5913
+ Relative_import_paths_need_explicit_file_extensions_in_EcmaScript_imports_when_moduleResolution_is_node12_or_nodenext_Consider_adding_an_extension_to_the_import_path: diag(2834, ts.DiagnosticCategory.Error, "Relative_import_paths_need_explicit_file_extensions_in_EcmaScript_imports_when_moduleResolution_is_n_2834", "Relative import paths need explicit file extensions in EcmaScript imports when '--moduleResolution' is 'node12' or 'nodenext'. Consider adding an extension to the import path."),
5914
+ Relative_import_paths_need_explicit_file_extensions_in_EcmaScript_imports_when_moduleResolution_is_node12_or_nodenext_Did_you_mean_0: diag(2835, ts.DiagnosticCategory.Error, "Relative_import_paths_need_explicit_file_extensions_in_EcmaScript_imports_when_moduleResolution_is_n_2835", "Relative import paths need explicit file extensions in EcmaScript imports when '--moduleResolution' is 'node12' or 'nodenext'. Did you mean '{0}'?"),
5913
5915
  Import_declaration_0_is_using_private_name_1: diag(4000, ts.DiagnosticCategory.Error, "Import_declaration_0_is_using_private_name_1_4000", "Import declaration '{0}' is using private name '{1}'."),
5914
5916
  Type_parameter_0_of_exported_class_has_or_is_using_private_name_1: diag(4002, ts.DiagnosticCategory.Error, "Type_parameter_0_of_exported_class_has_or_is_using_private_name_1_4002", "Type parameter '{0}' of exported class has or is using private name '{1}'."),
5915
5917
  Type_parameter_0_of_exported_interface_has_or_is_using_private_name_1: diag(4004, ts.DiagnosticCategory.Error, "Type_parameter_0_of_exported_interface_has_or_is_using_private_name_1_4004", "Type parameter '{0}' of exported interface has or is using private name '{1}'."),
@@ -6016,6 +6018,7 @@ var ts;
6016
6018
  This_member_cannot_have_a_JSDoc_comment_with_an_override_tag_because_its_containing_class_0_does_not_extend_another_class: diag(4121, ts.DiagnosticCategory.Error, "This_member_cannot_have_a_JSDoc_comment_with_an_override_tag_because_its_containing_class_0_does_not_4121", "This member cannot have a JSDoc comment with an '@override' tag because its containing class '{0}' does not extend another class."),
6017
6019
  This_member_cannot_have_a_JSDoc_comment_with_an_override_tag_because_it_is_not_declared_in_the_base_class_0: diag(4122, ts.DiagnosticCategory.Error, "This_member_cannot_have_a_JSDoc_comment_with_an_override_tag_because_it_is_not_declared_in_the_base__4122", "This member cannot have a JSDoc comment with an '@override' tag because it is not declared in the base class '{0}'."),
6018
6020
  This_member_cannot_have_a_JSDoc_comment_with_an_override_tag_because_it_is_not_declared_in_the_base_class_0_Did_you_mean_1: diag(4123, ts.DiagnosticCategory.Error, "This_member_cannot_have_a_JSDoc_comment_with_an_override_tag_because_it_is_not_declared_in_the_base__4123", "This member cannot have a JSDoc comment with an 'override' tag because it is not declared in the base class '{0}'. Did you mean '{1}'?"),
6021
+ Compiler_option_0_of_value_1_is_unstable_Use_nightly_TypeScript_to_silence_this_error_Try_updating_with_npm_install_D_typescript_next: diag(4124, ts.DiagnosticCategory.Error, "Compiler_option_0_of_value_1_is_unstable_Use_nightly_TypeScript_to_silence_this_error_Try_updating_w_4124", "Compiler option '{0}' of value '{1}' is unstable. Use nightly TypeScript to silence this error. Try updating with 'npm install -D typescript@next'."),
6019
6022
  The_current_host_does_not_support_the_0_option: diag(5001, ts.DiagnosticCategory.Error, "The_current_host_does_not_support_the_0_option_5001", "The current host does not support the '{0}' option."),
6020
6023
  Cannot_find_the_common_subdirectory_path_for_the_input_files: diag(5009, ts.DiagnosticCategory.Error, "Cannot_find_the_common_subdirectory_path_for_the_input_files_5009", "Cannot find the common subdirectory path for the input files."),
6021
6024
  File_specification_cannot_end_in_a_recursive_directory_wildcard_Asterisk_Asterisk_Colon_0: diag(5010, ts.DiagnosticCategory.Error, "File_specification_cannot_end_in_a_recursive_directory_wildcard_Asterisk_Asterisk_Colon_0_5010", "File specification cannot end in a recursive directory wildcard ('**'): '{0}'."),
@@ -6673,6 +6676,7 @@ var ts;
6673
6676
  Remove_unused_destructuring_declaration: diag(90039, ts.DiagnosticCategory.Message, "Remove_unused_destructuring_declaration_90039", "Remove unused destructuring declaration"),
6674
6677
  Remove_unused_declarations_for_Colon_0: diag(90041, ts.DiagnosticCategory.Message, "Remove_unused_declarations_for_Colon_0_90041", "Remove unused declarations for: '{0}'"),
6675
6678
  Declare_a_private_field_named_0: diag(90053, ts.DiagnosticCategory.Message, "Declare_a_private_field_named_0_90053", "Declare a private field named '{0}'."),
6679
+ Includes_imports_of_types_referenced_by_0: diag(90054, ts.DiagnosticCategory.Message, "Includes_imports_of_types_referenced_by_0_90054", "Includes imports of types referenced by '{0}'"),
6676
6680
  Convert_function_to_an_ES2015_class: diag(95001, ts.DiagnosticCategory.Message, "Convert_function_to_an_ES2015_class_95001", "Convert function to an ES2015 class"),
6677
6681
  Convert_0_to_1_in_0: diag(95003, ts.DiagnosticCategory.Message, "Convert_0_to_1_in_0_95003", "Convert '{0}' to '{1} in {0}'"),
6678
6682
  Extract_to_0_in_1: diag(95004, ts.DiagnosticCategory.Message, "Extract_to_0_in_1_95004", "Extract to {0} in {1}"),
@@ -38792,6 +38796,17 @@ var ts;
38792
38796
  var enumRelation = new ts.Map();
38793
38797
  var builtinGlobals = ts.createSymbolTable();
38794
38798
  builtinGlobals.set(undefinedSymbol.escapedName, undefinedSymbol);
38799
+ var suggestedExtensions = [
38800
+ [".mts", ".mjs"],
38801
+ [".ts", ".js"],
38802
+ [".cts", ".cjs"],
38803
+ [".mjs", ".mjs"],
38804
+ [".js", ".js"],
38805
+ [".cjs", ".cjs"],
38806
+ [".tsx", compilerOptions.jsx === 1 ? ".jsx" : ".js"],
38807
+ [".jsx", ".jsx"],
38808
+ [".json", ".json"],
38809
+ ];
38795
38810
  initializeTypeChecker();
38796
38811
  return checker;
38797
38812
  function getJsxNamespace(location) {
@@ -40694,7 +40709,7 @@ var ts;
40694
40709
  : undefined;
40695
40710
  }
40696
40711
  function resolveExternalModule(location, moduleReference, moduleNotFoundError, errorNode, isForAugmentation) {
40697
- var _a, _b, _c, _d, _e, _f;
40712
+ var _a, _b, _c, _d, _e, _f, _g;
40698
40713
  if (isForAugmentation === void 0) { isForAugmentation = false; }
40699
40714
  if (ts.startsWith(moduleReference, "@types/")) {
40700
40715
  var diag = ts.Diagnostics.Cannot_import_type_declaration_files_Consider_importing_0_instead_of_1;
@@ -40772,6 +40787,10 @@ var ts;
40772
40787
  }
40773
40788
  else {
40774
40789
  var tsExtension = ts.tryExtractTSExtension(moduleReference);
40790
+ var isExtensionlessRelativePathImport = ts.pathIsRelative(moduleReference) && !ts.hasExtension(moduleReference);
40791
+ var moduleResolutionKind = ts.getEmitModuleResolutionKind(compilerOptions);
40792
+ var resolutionIsNode12OrNext = moduleResolutionKind === ts.ModuleResolutionKind.Node12 ||
40793
+ moduleResolutionKind === ts.ModuleResolutionKind.NodeNext;
40775
40794
  if (tsExtension) {
40776
40795
  var diag = ts.Diagnostics.An_import_path_cannot_end_with_a_0_extension_Consider_importing_1_instead;
40777
40796
  var importSourceWithoutExtension = ts.removeExtension(moduleReference, tsExtension);
@@ -40787,6 +40806,19 @@ var ts;
40787
40806
  ts.hasJsonModuleEmitEnabled(compilerOptions)) {
40788
40807
  error(errorNode, ts.Diagnostics.Cannot_find_module_0_Consider_using_resolveJsonModule_to_import_module_with_json_extension, moduleReference);
40789
40808
  }
40809
+ else if (mode === ts.ModuleKind.ESNext && resolutionIsNode12OrNext && isExtensionlessRelativePathImport) {
40810
+ var absoluteRef_1 = ts.getNormalizedAbsolutePath(moduleReference, ts.getDirectoryPath(currentSourceFile.path));
40811
+ var suggestedExt = (_g = suggestedExtensions.find(function (_a) {
40812
+ var actualExt = _a[0], _importExt = _a[1];
40813
+ return host.fileExists(absoluteRef_1 + actualExt);
40814
+ })) === null || _g === void 0 ? void 0 : _g[1];
40815
+ if (suggestedExt) {
40816
+ error(errorNode, ts.Diagnostics.Relative_import_paths_need_explicit_file_extensions_in_EcmaScript_imports_when_moduleResolution_is_node12_or_nodenext_Did_you_mean_0, moduleReference + suggestedExt);
40817
+ }
40818
+ else {
40819
+ error(errorNode, ts.Diagnostics.Relative_import_paths_need_explicit_file_extensions_in_EcmaScript_imports_when_moduleResolution_is_node12_or_nodenext_Consider_adding_an_extension_to_the_import_path);
40820
+ }
40821
+ }
40790
40822
  else {
40791
40823
  error(errorNode, moduleNotFoundError, moduleReference);
40792
40824
  }
@@ -51225,7 +51257,8 @@ var ts;
51225
51257
  if (t.flags & (3 | 58982400 | 524288 | 2097152) && t !== wildcardType && !isErrorType(t)) {
51226
51258
  if (!type.declaration.nameType) {
51227
51259
  var constraint = void 0;
51228
- if (isArrayType(t) || (t.flags & 1) && (constraint = getConstraintOfTypeParameter(typeVariable)) && everyType(constraint, ts.or(isArrayType, isTupleType))) {
51260
+ if (isArrayType(t) || t.flags & 1 && findResolutionCycleStartIndex(typeVariable, 4) < 0 &&
51261
+ (constraint = getConstraintOfTypeParameter(typeVariable)) && everyType(constraint, ts.or(isArrayType, isTupleType))) {
51229
51262
  return instantiateMappedArrayType(t, type, prependTypeMapping(typeVariable, t, mapper));
51230
51263
  }
51231
51264
  if (isGenericTupleType(t)) {
@@ -79255,11 +79288,11 @@ var ts;
79255
79288
  currentFileState.filenameDeclaration = declaration;
79256
79289
  return currentFileState.filenameDeclaration.name;
79257
79290
  }
79258
- function getJsxFactoryCalleePrimitive(childrenLength) {
79259
- return compilerOptions.jsx === 5 ? "jsxDEV" : childrenLength > 1 ? "jsxs" : "jsx";
79291
+ function getJsxFactoryCalleePrimitive(isStaticChildren) {
79292
+ return compilerOptions.jsx === 5 ? "jsxDEV" : isStaticChildren ? "jsxs" : "jsx";
79260
79293
  }
79261
- function getJsxFactoryCallee(childrenLength) {
79262
- var type = getJsxFactoryCalleePrimitive(childrenLength);
79294
+ function getJsxFactoryCallee(isStaticChildren) {
79295
+ var type = getJsxFactoryCalleePrimitive(isStaticChildren);
79263
79296
  return getImplicitImportForName(type);
79264
79297
  }
79265
79298
  function getImplicitJsxFragmentReference() {
@@ -79398,7 +79431,7 @@ var ts;
79398
79431
  }
79399
79432
  function convertJsxChildrenToChildrenPropAssignment(children) {
79400
79433
  var nonWhitespaceChildren = ts.getSemanticJsxChildren(children);
79401
- if (ts.length(nonWhitespaceChildren) === 1) {
79434
+ if (ts.length(nonWhitespaceChildren) === 1 && !nonWhitespaceChildren[0].dotDotDotToken) {
79402
79435
  var result_12 = transformJsxChildToExpression(nonWhitespaceChildren[0]);
79403
79436
  return result_12 && factory.createPropertyAssignment("children", result_12);
79404
79437
  }
@@ -79412,14 +79445,17 @@ var ts;
79412
79445
  var attrs = keyAttr ? ts.filter(node.attributes.properties, function (p) { return p !== keyAttr; }) : node.attributes.properties;
79413
79446
  var objectProperties = ts.length(attrs) ? transformJsxAttributesToObjectProps(attrs, childrenProp) :
79414
79447
  factory.createObjectLiteralExpression(childrenProp ? [childrenProp] : ts.emptyArray);
79415
- return visitJsxOpeningLikeElementOrFragmentJSX(tagName, objectProperties, keyAttr, ts.length(ts.getSemanticJsxChildren(children || ts.emptyArray)), isChild, location);
79448
+ return visitJsxOpeningLikeElementOrFragmentJSX(tagName, objectProperties, keyAttr, children || ts.emptyArray, isChild, location);
79416
79449
  }
79417
- function visitJsxOpeningLikeElementOrFragmentJSX(tagName, objectProperties, keyAttr, childrenLength, isChild, location) {
79450
+ function visitJsxOpeningLikeElementOrFragmentJSX(tagName, objectProperties, keyAttr, children, isChild, location) {
79451
+ var _a;
79452
+ var nonWhitespaceChildren = ts.getSemanticJsxChildren(children);
79453
+ var isStaticChildren = ts.length(nonWhitespaceChildren) > 1 || !!((_a = nonWhitespaceChildren[0]) === null || _a === void 0 ? void 0 : _a.dotDotDotToken);
79418
79454
  var args = [tagName, objectProperties, !keyAttr ? factory.createVoidZero() : transformJsxAttributeInitializer(keyAttr.initializer)];
79419
79455
  if (compilerOptions.jsx === 5) {
79420
79456
  var originalFile = ts.getOriginalNode(currentSourceFile);
79421
79457
  if (originalFile && ts.isSourceFile(originalFile)) {
79422
- args.push(childrenLength > 1 ? factory.createTrue() : factory.createFalse());
79458
+ args.push(isStaticChildren ? factory.createTrue() : factory.createFalse());
79423
79459
  var lineCol = ts.getLineAndCharacterOfPosition(originalFile, location.pos);
79424
79460
  args.push(factory.createObjectLiteralExpression([
79425
79461
  factory.createPropertyAssignment("fileName", getCurrentFileNameExpression()),
@@ -79429,7 +79465,7 @@ var ts;
79429
79465
  args.push(factory.createThis());
79430
79466
  }
79431
79467
  }
79432
- var element = ts.setTextRange(factory.createCallExpression(getJsxFactoryCallee(childrenLength), undefined, args), location);
79468
+ var element = ts.setTextRange(factory.createCallExpression(getJsxFactoryCallee(isStaticChildren), undefined, args), location);
79433
79469
  if (isChild) {
79434
79470
  ts.startOnNewLine(element);
79435
79471
  }
@@ -79457,7 +79493,7 @@ var ts;
79457
79493
  childrenProps = result;
79458
79494
  }
79459
79495
  }
79460
- return visitJsxOpeningLikeElementOrFragmentJSX(getImplicitJsxFragmentReference(), childrenProps || factory.createObjectLiteralExpression([]), undefined, ts.length(ts.getSemanticJsxChildren(children)), isChild, location);
79496
+ return visitJsxOpeningLikeElementOrFragmentJSX(getImplicitJsxFragmentReference(), childrenProps || factory.createObjectLiteralExpression([]), undefined, children, isChild, location);
79461
79497
  }
79462
79498
  function visitJsxOpeningFragmentCreateElement(node, children, isChild, location) {
79463
79499
  var element = ts.createExpressionForJsxFragment(factory, context.getEmitResolver().getJsxFactoryEntity(currentSourceFile), context.getEmitResolver().getJsxFragmentFactoryEntity(currentSourceFile), compilerOptions.reactNamespace, ts.mapDefined(children, transformJsxChildToExpression), node, location);
@@ -94163,8 +94199,8 @@ var ts;
94163
94199
  }
94164
94200
  var typesReferenceDirectives = ts.map(newSourceFile.typeReferenceDirectives, function (ref) { return ts.toFileNameLowerCase(ref.fileName); });
94165
94201
  var typeReferenceResolutions = resolveTypeReferenceDirectiveNamesWorker(typesReferenceDirectives, newSourceFile);
94166
- var typeReferenceEesolutionsChanged = ts.hasChangesInResolutions(typesReferenceDirectives, typeReferenceResolutions, oldSourceFile.resolvedTypeReferenceDirectiveNames, oldSourceFile, ts.typeDirectiveIsEqualTo);
94167
- if (typeReferenceEesolutionsChanged) {
94202
+ var typeReferenceResolutionsChanged = ts.hasChangesInResolutions(typesReferenceDirectives, typeReferenceResolutions, oldSourceFile.resolvedTypeReferenceDirectiveNames, oldSourceFile, ts.typeDirectiveIsEqualTo);
94203
+ if (typeReferenceResolutionsChanged) {
94168
94204
  structureIsReused = 1;
94169
94205
  newSourceFile.resolvedTypeReferenceDirectiveNames = ts.zipToModeAwareCache(newSourceFile, typesReferenceDirectives, typeReferenceResolutions);
94170
94206
  }
@@ -95303,6 +95339,21 @@ var ts;
95303
95339
  return resolvedRef;
95304
95340
  }
95305
95341
  function verifyCompilerOptions() {
95342
+ var isNightly = ts.stringContains(ts.version, "-dev");
95343
+ if (!isNightly) {
95344
+ if (ts.getEmitModuleKind(options) === ts.ModuleKind.Node12) {
95345
+ createOptionValueDiagnostic("module", ts.Diagnostics.Compiler_option_0_of_value_1_is_unstable_Use_nightly_TypeScript_to_silence_this_error_Try_updating_with_npm_install_D_typescript_next, "module", "node12");
95346
+ }
95347
+ else if (ts.getEmitModuleKind(options) === ts.ModuleKind.NodeNext) {
95348
+ createOptionValueDiagnostic("module", ts.Diagnostics.Compiler_option_0_of_value_1_is_unstable_Use_nightly_TypeScript_to_silence_this_error_Try_updating_with_npm_install_D_typescript_next, "module", "nodenext");
95349
+ }
95350
+ else if (ts.getEmitModuleResolutionKind(options) === ts.ModuleResolutionKind.Node12) {
95351
+ createOptionValueDiagnostic("moduleResolution", ts.Diagnostics.Compiler_option_0_of_value_1_is_unstable_Use_nightly_TypeScript_to_silence_this_error_Try_updating_with_npm_install_D_typescript_next, "moduleResolution", "node12");
95352
+ }
95353
+ else if (ts.getEmitModuleResolutionKind(options) === ts.ModuleResolutionKind.NodeNext) {
95354
+ createOptionValueDiagnostic("moduleResolution", ts.Diagnostics.Compiler_option_0_of_value_1_is_unstable_Use_nightly_TypeScript_to_silence_this_error_Try_updating_with_npm_install_D_typescript_next, "moduleResolution", "nodenext");
95355
+ }
95356
+ }
95306
95357
  if (options.strictPropertyInitialization && !ts.getStrictOptionValue(options, "strictNullChecks")) {
95307
95358
  createDiagnosticForOptionName(ts.Diagnostics.Option_0_cannot_be_specified_without_specifying_option_1, "strictPropertyInitialization", "strictNullChecks");
95308
95359
  }
@@ -95760,8 +95811,8 @@ var ts;
95760
95811
  function createDiagnosticForOptionName(message, option1, option2, option3) {
95761
95812
  createDiagnosticForOption(true, option1, option2, message, option1, option2, option3);
95762
95813
  }
95763
- function createOptionValueDiagnostic(option1, message, arg0) {
95764
- createDiagnosticForOption(false, option1, undefined, message, arg0);
95814
+ function createOptionValueDiagnostic(option1, message, arg0, arg1) {
95815
+ createDiagnosticForOption(false, option1, undefined, message, arg0, arg1);
95765
95816
  }
95766
95817
  function createDiagnosticForReference(sourceFile, index, message, arg0, arg1) {
95767
95818
  var referencesSyntax = ts.firstDefined(ts.getTsConfigPropArray(sourceFile || options.configFile, "references"), function (property) { return ts.isArrayLiteralExpression(property.initializer) ? property.initializer : undefined; });
@@ -97625,6 +97676,9 @@ var ts;
97625
97676
  else {
97626
97677
  resolution = loader(name, containingFile, compilerOptions, ((_c = resolutionHost.getCompilerHost) === null || _c === void 0 ? void 0 : _c.call(resolutionHost)) || resolutionHost, redirectedReference, containingSourceFile);
97627
97678
  perDirectoryResolution.set(name, mode, resolution);
97679
+ if (resolutionHost.onDiscoveredSymlink && resolutionIsSymlink(resolution)) {
97680
+ resolutionHost.onDiscoveredSymlink();
97681
+ }
97628
97682
  }
97629
97683
  resolutionsInFile.set(name, mode, resolution);
97630
97684
  watchFailedLookupLocationsOfExternalModuleResolutions(name, resolution, path, getResolutionWithResolvedFileName);
@@ -98042,6 +98096,11 @@ var ts;
98042
98096
  }
98043
98097
  }
98044
98098
  ts.createResolutionCache = createResolutionCache;
98099
+ function resolutionIsSymlink(resolution) {
98100
+ var _a, _b;
98101
+ return !!(((_a = resolution.resolvedModule) === null || _a === void 0 ? void 0 : _a.originalPath) ||
98102
+ ((_b = resolution.resolvedTypeReferenceDirective) === null || _b === void 0 ? void 0 : _b.originalPath));
98103
+ }
98045
98104
  })(ts || (ts = {}));
98046
98105
  var ts;
98047
98106
  (function (ts) {