typescript 4.8.0-dev.20220722 → 4.8.0-dev.20220725
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/cs/diagnosticMessages.generated.json +2 -0
- package/lib/de/diagnosticMessages.generated.json +2 -0
- package/lib/es/diagnosticMessages.generated.json +2 -0
- package/lib/fr/diagnosticMessages.generated.json +2 -0
- package/lib/it/diagnosticMessages.generated.json +2 -0
- package/lib/ja/diagnosticMessages.generated.json +2 -0
- package/lib/ko/diagnosticMessages.generated.json +2 -0
- package/lib/pl/diagnosticMessages.generated.json +2 -0
- package/lib/pt-br/diagnosticMessages.generated.json +2 -0
- package/lib/ru/diagnosticMessages.generated.json +2 -0
- package/lib/tr/diagnosticMessages.generated.json +2 -0
- package/lib/tsc.js +28 -28
- package/lib/tsserver.js +101 -60
- package/lib/tsserverlibrary.js +101 -60
- package/lib/typescript.js +101 -60
- package/lib/typescriptServices.js +101 -60
- package/lib/typingsInstaller.js +33 -31
- package/lib/zh-cn/diagnosticMessages.generated.json +2 -0
- package/lib/zh-tw/diagnosticMessages.generated.json +2 -0
- package/package.json +1 -1
|
@@ -226,6 +226,7 @@
|
|
|
226
226
|
"An_index_signature_parameter_must_have_a_type_annotation_1022": "V parametru signatury indexu nemůže být anotace typu.",
|
|
227
227
|
"An_index_signature_parameter_type_cannot_be_a_literal_type_or_generic_type_Consider_using_a_mapped_o_1337": "Typ parametru signatury indexu nemůže být typ literálu nebo obecný typ. Místo toho zvažte použití namapovaného typu objektu.",
|
|
228
228
|
"An_index_signature_parameter_type_must_be_string_number_symbol_or_a_template_literal_type_1268": "Typ parametru signatury indexu musí být řetězec, číslo, symbol nebo typ literálu šablony.",
|
|
229
|
+
"An_instantiation_expression_cannot_be_followed_by_a_property_access_1477": "Po výrazu vytvoření instance nemůže následovat přístup k vlastnosti.",
|
|
229
230
|
"An_interface_can_only_extend_an_identifier_Slashqualified_name_with_optional_type_arguments_2499": "Rozhraní může rozšířit jenom identifikátor nebo kvalifikovaný název s volitelnými argumenty typu.",
|
|
230
231
|
"An_interface_can_only_extend_an_object_type_or_intersection_of_object_types_with_statically_known_me_2312": "Rozhraní může rozšiřovat jen typ objektu nebo průsečík typů objektů se staticky známými členy.",
|
|
231
232
|
"An_interface_cannot_extend_a_primitive_type_like_0_an_interface_can_only_extend_named_types_and_clas_2840": "Rozhraní nemůže rozšířit primitivní typ, jako je {0}; rozhraní může rozšířit jenom pojmenované typy a třídy.",
|
|
@@ -1561,6 +1562,7 @@
|
|
|
1561
1562
|
"Type_library_referenced_via_0_from_file_1_with_packageId_2_1403": "Knihovna typů, na kterou se odkazuje přes {0} ze souboru {1} s packageId {2}",
|
|
1562
1563
|
"Type_of_await_operand_must_either_be_a_valid_promise_or_must_not_contain_a_callable_then_member_1320": "Typ operandu await musí být buď platný příslib, nebo nesmí obsahovat člen then, který se dá volat.",
|
|
1563
1564
|
"Type_of_computed_property_s_value_is_0_which_is_not_assignable_to_type_1_2418": "Typ hodnoty počítané vlastnosti je {0} a nedá se přiřadit do typu {1}.",
|
|
1565
|
+
"Type_of_instance_member_variable_0_cannot_reference_identifier_1_declared_in_the_constructor_2844": "Typ instance členské proměnné {0} nemůže odkazovat na identifikátor {1} deklarovaný v konstruktoru.",
|
|
1564
1566
|
"Type_of_iterated_elements_of_a_yield_Asterisk_operand_must_either_be_a_valid_promise_or_must_not_con_1322": "Typ iterovaných elementů yield* musí být buď platný příslib, nebo nesmí obsahovat člen then, který se dá volat.",
|
|
1565
1567
|
"Type_of_property_0_circularly_references_itself_in_mapped_type_1_2615": "Typ vlastnosti {0} cyklicky odkazuje sám na sebe v mapovaném typu {1}.",
|
|
1566
1568
|
"Type_of_yield_operand_in_an_async_generator_must_either_be_a_valid_promise_or_must_not_contain_a_cal_1321": "Typ operandu yield v asynchronním generátoru musí být buď platný příslib, nebo nesmí obsahovat člen then, který se dá volat.",
|
|
@@ -226,6 +226,7 @@
|
|
|
226
226
|
"An_index_signature_parameter_must_have_a_type_annotation_1022": "Ein Indexsignaturparameter muss eine Typanmerkung besitzen.",
|
|
227
227
|
"An_index_signature_parameter_type_cannot_be_a_literal_type_or_generic_type_Consider_using_a_mapped_o_1337": "Ein Indexsignaturparametertyp darf kein Literaltyp oder generischer Typ sein. Erwägen Sie stattdessen die Verwendung eines zugeordneten Objekttyps.",
|
|
228
228
|
"An_index_signature_parameter_type_must_be_string_number_symbol_or_a_template_literal_type_1268": "Ein Parametertyp für die Indexsignatur muss \"string\", \"number\", \"symbol\" oder ein Vorlagenliteraltyp sein.",
|
|
229
|
+
"An_instantiation_expression_cannot_be_followed_by_a_property_access_1477": "Auf einen Instanziierungsausdruck kann kein Eigenschaftenzugriff folgen.",
|
|
229
230
|
"An_interface_can_only_extend_an_identifier_Slashqualified_name_with_optional_type_arguments_2499": "Eine Schnittstelle kann nur einen Bezeichner/\"qualified-name\" mit optionalen Typargumenten erweitern.",
|
|
230
231
|
"An_interface_can_only_extend_an_object_type_or_intersection_of_object_types_with_statically_known_me_2312": "Eine Schnittstelle kann nur einen Objekttyp oder eine Schnittmenge von Objekttypen mit statisch bekannten Membern erweitern.",
|
|
231
232
|
"An_interface_cannot_extend_a_primitive_type_like_0_an_interface_can_only_extend_named_types_and_clas_2840": "Eine Schnittstelle kann einen primitiven Typ wie „{0}“ nicht erweitern; eine Schnittstelle kann nur benannte Typen und Klassen erweitern",
|
|
@@ -1561,6 +1562,7 @@
|
|
|
1561
1562
|
"Type_library_referenced_via_0_from_file_1_with_packageId_2_1403": "Typbibliothek, die über \"{0}\" aus der Datei \"{1}\" mit packageId \"{2}\" referenziert wird",
|
|
1562
1563
|
"Type_of_await_operand_must_either_be_a_valid_promise_or_must_not_contain_a_callable_then_member_1320": "Der Typ des \"await\"-Operanden muss entweder eine gültige Zusage sein oder darf keinen aufrufbaren \"then\"-Member enthalten.",
|
|
1563
1564
|
"Type_of_computed_property_s_value_is_0_which_is_not_assignable_to_type_1_2418": "Der Typ des Werts der berechneten Eigenschaft lautet \"{0}\" und kann dem Typ \"{1}\" nicht zugewiesen werden.",
|
|
1565
|
+
"Type_of_instance_member_variable_0_cannot_reference_identifier_1_declared_in_the_constructor_2844": "Der Typ der Instanzmembervariablen „{0}“ darf nicht auf den im Konstruktor deklarierten Bezeichner „{1}“ verweisen.",
|
|
1564
1566
|
"Type_of_iterated_elements_of_a_yield_Asterisk_operand_must_either_be_a_valid_promise_or_must_not_con_1322": "Der Typ iterierter Elemente eines \"yield*\"-Operanden muss entweder eine gültige Zusage sein oder darf keinen aufrufbaren \"then\"-Member enthalten.",
|
|
1565
1567
|
"Type_of_property_0_circularly_references_itself_in_mapped_type_1_2615": "Der Typ der Eigenschaft \"{0}\" verweist im zugeordneten Typ \"{1}\" auf sich selbst.",
|
|
1566
1568
|
"Type_of_yield_operand_in_an_async_generator_must_either_be_a_valid_promise_or_must_not_contain_a_cal_1321": "Der Typ eines \"yield\"-Operanden in einem asynchronen Generator muss entweder eine gültige Zusage sein oder darf keinen aufrufbaren \"then\"-Member enthalten.",
|
|
@@ -226,6 +226,7 @@
|
|
|
226
226
|
"An_index_signature_parameter_must_have_a_type_annotation_1022": "Un parámetro de signatura de índice debe tener una anotación de tipo.",
|
|
227
227
|
"An_index_signature_parameter_type_cannot_be_a_literal_type_or_generic_type_Consider_using_a_mapped_o_1337": "Un tipo de parámetro de signatura de índice no puede ser un tipo literal o un tipo genérico. Considere la posibilidad de usar, en su lugar, uno de los tipos de objeto asignados.",
|
|
228
228
|
"An_index_signature_parameter_type_must_be_string_number_symbol_or_a_template_literal_type_1268": "El tipo de parámetro de la signatura de índice debe ser \"string\", \"number\", \"symbol\" o un tipo literal de plantilla.",
|
|
229
|
+
"An_instantiation_expression_cannot_be_followed_by_a_property_access_1477": "Una expresión de creación de una instancia no puede ir seguida de un acceso a una propiedad.",
|
|
229
230
|
"An_interface_can_only_extend_an_identifier_Slashqualified_name_with_optional_type_arguments_2499": "Una interfaz solo puede extender un identificador o nombre completo con argumentos de tipo opcional.",
|
|
230
231
|
"An_interface_can_only_extend_an_object_type_or_intersection_of_object_types_with_statically_known_me_2312": "Una interfaz solo puede extender un tipo de objeto o una intersección de tipos de objeto con miembros conocidos estáticamente.",
|
|
231
232
|
"An_interface_cannot_extend_a_primitive_type_like_0_an_interface_can_only_extend_named_types_and_clas_2840": "Una interfaz no puede extender un tipo primitivo como \"{0}\"; una interfaz solo puede extender tipos y clases con nombre",
|
|
@@ -1561,6 +1562,7 @@
|
|
|
1561
1562
|
"Type_library_referenced_via_0_from_file_1_with_packageId_2_1403": "Biblioteca de tipos a la que se hace referencia mediante \"{0}\" desde el archivo \"{1}\" con el valor packageId \"{2}\"",
|
|
1562
1563
|
"Type_of_await_operand_must_either_be_a_valid_promise_or_must_not_contain_a_callable_then_member_1320": "El tipo de operando \"await\" debe ser una promesa válida o no debe contener un miembro \"then\" invocable.",
|
|
1563
1564
|
"Type_of_computed_property_s_value_is_0_which_is_not_assignable_to_type_1_2418": "El tipo de valor de la propiedad calculada es \"{0}\", que no se puede asignar al tipo \"{1}\".",
|
|
1565
|
+
"Type_of_instance_member_variable_0_cannot_reference_identifier_1_declared_in_the_constructor_2844": "El tipo de variable miembro de instancia \"{0}\" no puede hacer referencia al identificador \"{1}\" declarado en el constructor.",
|
|
1564
1566
|
"Type_of_iterated_elements_of_a_yield_Asterisk_operand_must_either_be_a_valid_promise_or_must_not_con_1322": "El tipo de elementos iterados de un operando \"yield*\" debe ser una promesa válida o no debe contener un miembro \"then\" invocable.",
|
|
1565
1567
|
"Type_of_property_0_circularly_references_itself_in_mapped_type_1_2615": "El tipo de propiedad \"{0}\" hace referencia circular a sí misma en el tipo asignado \"{1}\".",
|
|
1566
1568
|
"Type_of_yield_operand_in_an_async_generator_must_either_be_a_valid_promise_or_must_not_contain_a_cal_1321": "El tipo de operando \"yield\" en un generador asincrónico debe ser una promesa válida o no debe contener un miembro \"then\" invocable.",
|
|
@@ -226,6 +226,7 @@
|
|
|
226
226
|
"An_index_signature_parameter_must_have_a_type_annotation_1022": "Un paramètre de signature d'index doit avoir une annotation de type.",
|
|
227
227
|
"An_index_signature_parameter_type_cannot_be_a_literal_type_or_generic_type_Consider_using_a_mapped_o_1337": "Un type de paramètre de signature d’index ne peut pas être un type littéral ni générique. Envisagez plutôt d’utiliser un type d’objet mappé.",
|
|
228
228
|
"An_index_signature_parameter_type_must_be_string_number_symbol_or_a_template_literal_type_1268": "Un type de paramètre de signature d’index doit être « string », « number », « symbol » ou un type littéral de modèle.",
|
|
229
|
+
"An_instantiation_expression_cannot_be_followed_by_a_property_access_1477": "Une expression d’instanciation ne peut pas être suivie d’un accès à la propriété.",
|
|
229
230
|
"An_interface_can_only_extend_an_identifier_Slashqualified_name_with_optional_type_arguments_2499": "Une interface peut uniquement étendre un identificateur/nom qualifié avec des arguments de type facultatifs.",
|
|
230
231
|
"An_interface_can_only_extend_an_object_type_or_intersection_of_object_types_with_statically_known_me_2312": "Une interface peut étendre uniquement un type d'objet ou une intersection de types d'objet avec des membres connus de manière statique.",
|
|
231
232
|
"An_interface_cannot_extend_a_primitive_type_like_0_an_interface_can_only_extend_named_types_and_clas_2840": "Une interface ne peut pas étendre un type primitif comme « {0} » ; une interface peut uniquement étendre des types nommés et des classes.",
|
|
@@ -1561,6 +1562,7 @@
|
|
|
1561
1562
|
"Type_library_referenced_via_0_from_file_1_with_packageId_2_1403": "Bibliothèque de types référencée via '{0}' à partir du fichier '{1}' ayant le packageId '{2}'",
|
|
1562
1563
|
"Type_of_await_operand_must_either_be_a_valid_promise_or_must_not_contain_a_callable_then_member_1320": "Le type d'un opérande 'await' doit être une promesse valide ou ne doit contenir aucun membre 'then' pouvant être appelé.",
|
|
1563
1564
|
"Type_of_computed_property_s_value_is_0_which_is_not_assignable_to_type_1_2418": "Le type de la valeur de la propriété calculée est '{0}'. Il ne peut pas être assigné au type '{1}'.",
|
|
1565
|
+
"Type_of_instance_member_variable_0_cannot_reference_identifier_1_declared_in_the_constructor_2844": "Le type de variable membre d’instance '{0}' ne peut pas référencer l’identificateur '{1}' déclaré dans le constructeur.",
|
|
1564
1566
|
"Type_of_iterated_elements_of_a_yield_Asterisk_operand_must_either_be_a_valid_promise_or_must_not_con_1322": "Le type des éléments itérés d'un opérande 'yield*' doit être une promesse valide ou ne doit contenir aucun membre 'then' pouvant être appelé.",
|
|
1565
1567
|
"Type_of_property_0_circularly_references_itself_in_mapped_type_1_2615": "Le type de la propriété '{0}' se référence de façon circulaire dans le type mappé '{1}'.",
|
|
1566
1568
|
"Type_of_yield_operand_in_an_async_generator_must_either_be_a_valid_promise_or_must_not_contain_a_cal_1321": "Le type d'un opérande 'yield' dans un générateur asynchrone doit être une promesse valide ou ne doit contenir aucun membre 'then' pouvant être appelé.",
|
|
@@ -226,6 +226,7 @@
|
|
|
226
226
|
"An_index_signature_parameter_must_have_a_type_annotation_1022": "Un parametro della firma dell'indice deve contenere un'annotazione di tipo.",
|
|
227
227
|
"An_index_signature_parameter_type_cannot_be_a_literal_type_or_generic_type_Consider_using_a_mapped_o_1337": "Un tipo di parametro della firma dell'indice non può essere un tipo di valore letterale o un tipo generico. Considerare l'utilizzo di un tipo di oggetto con mapping.",
|
|
228
228
|
"An_index_signature_parameter_type_must_be_string_number_symbol_or_a_template_literal_type_1268": "Un tipo di parametro della firma dell'indice deve essere 'stringa', 'numero', 'simbolo' o un tipo di valore letterale del modello.",
|
|
229
|
+
"An_instantiation_expression_cannot_be_followed_by_a_property_access_1477": "Un'espressione di creazione di un'istanza non può essere seguita da un accesso a proprietà.",
|
|
229
230
|
"An_interface_can_only_extend_an_identifier_Slashqualified_name_with_optional_type_arguments_2499": "Un'interfaccia può estendere solo un identificatore/nome qualificato con argomenti tipo facoltativi.",
|
|
230
231
|
"An_interface_can_only_extend_an_object_type_or_intersection_of_object_types_with_statically_known_me_2312": "Un'interfaccia può estendere solo un tipo di oggetto o un'intersezione di tipi di oggetto con membri noti in modo statico.",
|
|
231
232
|
"An_interface_cannot_extend_a_primitive_type_like_0_an_interface_can_only_extend_named_types_and_clas_2840": "Un'interfaccia non può estendere un tipo primitivo come '{0}'; un'interfaccia può estendere solo tipi e classi denominati",
|
|
@@ -1561,6 +1562,7 @@
|
|
|
1561
1562
|
"Type_library_referenced_via_0_from_file_1_with_packageId_2_1403": "Libreria dei tipi a cui viene fatto riferimento tramite '{0}' dal file '{1}' con packageId '{2}'",
|
|
1562
1563
|
"Type_of_await_operand_must_either_be_a_valid_promise_or_must_not_contain_a_callable_then_member_1320": "Il tipo dell'operando 'await' deve essere una promessa valida oppure non deve contenere un membro 'then' chiamabile.",
|
|
1563
1564
|
"Type_of_computed_property_s_value_is_0_which_is_not_assignable_to_type_1_2418": "Il tipo del valore della proprietà calcolata è '{0}', che non è assegnabile al tipo '{1}'.",
|
|
1565
|
+
"Type_of_instance_member_variable_0_cannot_reference_identifier_1_declared_in_the_constructor_2844": "Il tipo di variabile del membro di istanza '{0}' non può fare riferimento all'identificatore '{1}' dichiarato nel costruttore.",
|
|
1564
1566
|
"Type_of_iterated_elements_of_a_yield_Asterisk_operand_must_either_be_a_valid_promise_or_must_not_con_1322": "Il tipo di elementi iterati di un operando 'yield*' deve essere una promessa valida oppure non deve contenere un membro 'then' chiamabile.",
|
|
1565
1567
|
"Type_of_property_0_circularly_references_itself_in_mapped_type_1_2615": "Il tipo di proprietà '{0}' contiene un riferimento circolare a se stesso nel tipo con mapping '{1}'.",
|
|
1566
1568
|
"Type_of_yield_operand_in_an_async_generator_must_either_be_a_valid_promise_or_must_not_contain_a_cal_1321": "Il tipo dell'operando 'yield' in un generatore asincrono deve essere una promessa valida oppure non deve contenere un membro 'then' chiamabile.",
|
|
@@ -226,6 +226,7 @@
|
|
|
226
226
|
"An_index_signature_parameter_must_have_a_type_annotation_1022": "インデックス シグネチャのパラメーターには型の注釈が必要です。",
|
|
227
227
|
"An_index_signature_parameter_type_cannot_be_a_literal_type_or_generic_type_Consider_using_a_mapped_o_1337": "インデックス シグネチャ パラメーターの型をリテラル型またはジェネリック型にすることはできません。代わりに、マップされたオブジェクト型の使用を検討してください。",
|
|
228
228
|
"An_index_signature_parameter_type_must_be_string_number_symbol_or_a_template_literal_type_1268": "インデックス シグネチャ パラメーター型は、'string'、'number'、'symbol'、またはテンプレート リテラルの型である必要があります。",
|
|
229
|
+
"An_instantiation_expression_cannot_be_followed_by_a_property_access_1477": "インスタンス化式の後にプロパティ アクセスを続けることはできません。",
|
|
229
230
|
"An_interface_can_only_extend_an_identifier_Slashqualified_name_with_optional_type_arguments_2499": "インターフェイスが拡張するのは、オプションの型引数が指定された識別子/完全修飾名のみです。",
|
|
230
231
|
"An_interface_can_only_extend_an_object_type_or_intersection_of_object_types_with_statically_known_me_2312": "インターフェイスが拡張できるのは、オブジェクト型または静的な既知のメンバーを持つオブジェクト型の積集合のみです。",
|
|
231
232
|
"An_interface_cannot_extend_a_primitive_type_like_0_an_interface_can_only_extend_named_types_and_clas_2840": "インターフェイスは、'{0}' のようなプリミティブ型を拡張できません。インターフェイスは名前付きの型とクラスのみを拡張できます",
|
|
@@ -1561,6 +1562,7 @@
|
|
|
1561
1562
|
"Type_library_referenced_via_0_from_file_1_with_packageId_2_1403": "packageId が '{2}' のファイル '{1}' から '{0}' を介して参照されたタイプ ライブラリ",
|
|
1562
1563
|
"Type_of_await_operand_must_either_be_a_valid_promise_or_must_not_contain_a_callable_then_member_1320": "'await' オペランドの型は、有効な Promise であるか、呼び出し可能な 'then' メンバーを含んでいないかのどちらかであることが必要です。",
|
|
1563
1564
|
"Type_of_computed_property_s_value_is_0_which_is_not_assignable_to_type_1_2418": "計算されたプロパティの値の型は '{0}' です。これは、型 '{1}' に代入することはできません。",
|
|
1565
|
+
"Type_of_instance_member_variable_0_cannot_reference_identifier_1_declared_in_the_constructor_2844": "インスタンス メンバー変数 '{0}' の型は、コンストラクターで宣言された識別子 '{1}' を参照できません。",
|
|
1564
1566
|
"Type_of_iterated_elements_of_a_yield_Asterisk_operand_must_either_be_a_valid_promise_or_must_not_con_1322": "'yield*' オペランドの反復要素の型は、有効な Promise であるか、呼び出し可能な 'then' メンバーを含んでいないかのどちらかであることが必要です。",
|
|
1565
1567
|
"Type_of_property_0_circularly_references_itself_in_mapped_type_1_2615": "マップされた型 '{1}' で、プロパティ '{0}' の型によってそれ自体が循環参照されています。",
|
|
1566
1568
|
"Type_of_yield_operand_in_an_async_generator_must_either_be_a_valid_promise_or_must_not_contain_a_cal_1321": "非同期ジェネレーター内の 'yield' オペランドの型は、有効な Promise であるか、呼び出し可能な 'then' メンバーを含んでいないかのどちらかであることが必要です。",
|
|
@@ -226,6 +226,7 @@
|
|
|
226
226
|
"An_index_signature_parameter_must_have_a_type_annotation_1022": "인덱스 시그니처 매개 변수에는 형식 주석을 사용할 수 없습니다.",
|
|
227
227
|
"An_index_signature_parameter_type_cannot_be_a_literal_type_or_generic_type_Consider_using_a_mapped_o_1337": "인덱스 시그니처 매개 변수 형식은 리터럴 유형이나 제네릭 형식일 수 없습니다. 대신 매핑된 개체 형식을 사용하세요.",
|
|
228
228
|
"An_index_signature_parameter_type_must_be_string_number_symbol_or_a_template_literal_type_1268": "인덱스 시그니처 매개 변수 형식은 'string', 'number', 'symbol' 또는 템플릿 리터럴 형식이어야 합니다.",
|
|
229
|
+
"An_instantiation_expression_cannot_be_followed_by_a_property_access_1477": "인스턴스화 식 뒤에 속성 액세스가 있을 수 없습니다.",
|
|
229
230
|
"An_interface_can_only_extend_an_identifier_Slashqualified_name_with_optional_type_arguments_2499": "인터페이스는 선택적 형식 인수가 포함된 식별자/정규화된 이름만 확장할 수 있습니다.",
|
|
230
231
|
"An_interface_can_only_extend_an_object_type_or_intersection_of_object_types_with_statically_known_me_2312": "인터페이스는 개체 형식 또는 정적으로 알려진 멤버가 포함된 개체 형식의 교집합만 확장할 수 있습니다.",
|
|
231
232
|
"An_interface_cannot_extend_a_primitive_type_like_0_an_interface_can_only_extend_named_types_and_clas_2840": "인터페이스는 '{0}' 같은 기본 형식을 확장할 수 없습니다. 인터페이스는 명명된 형식 및 클래스만 확장할 수 있습니다.",
|
|
@@ -1561,6 +1562,7 @@
|
|
|
1561
1562
|
"Type_library_referenced_via_0_from_file_1_with_packageId_2_1403": "packageId가 '{2}'인 '{1}' 파일에서 '{0}'을(를) 통해 형식 라이브러리가 참조되었습니다.",
|
|
1562
1563
|
"Type_of_await_operand_must_either_be_a_valid_promise_or_must_not_contain_a_callable_then_member_1320": "'await' 형식의 피연산자는 유효한 프라미스여야 하거나 호출 가능 'then' 멤버를 포함하지 않아야 합니다.",
|
|
1563
1564
|
"Type_of_computed_property_s_value_is_0_which_is_not_assignable_to_type_1_2418": "계산된 속성 값의 형식은 '{1}' 형식에 할당할 수 없는 '{0}'입니다.",
|
|
1565
|
+
"Type_of_instance_member_variable_0_cannot_reference_identifier_1_declared_in_the_constructor_2844": "인스턴스 멤버 변수 '{0}'의 형식은 생성자에 선언된 식별자 '{1}'을(를) 참조할 수 없습니다.",
|
|
1564
1566
|
"Type_of_iterated_elements_of_a_yield_Asterisk_operand_must_either_be_a_valid_promise_or_must_not_con_1322": "'yield*'의 반복되는 요소 형식의 피연산자는 유효한 프라미스여야 하거나 호출 가능 'then' 멤버를 포함하지 않아야 합니다.",
|
|
1565
1567
|
"Type_of_property_0_circularly_references_itself_in_mapped_type_1_2615": "'{0}' 속성의 형식은 매핑된 형식 '{1}'에서 순환적으로 자신을 참조합니다.",
|
|
1566
1568
|
"Type_of_yield_operand_in_an_async_generator_must_either_be_a_valid_promise_or_must_not_contain_a_cal_1321": "비동기 생성기에 있는 'yield' 형식의 피연산자는 유효한 프라미스여야 하거나 호출 가능 'then' 멤버를 포함하지 않아야 합니다.",
|
|
@@ -226,6 +226,7 @@
|
|
|
226
226
|
"An_index_signature_parameter_must_have_a_type_annotation_1022": "Parametr sygnatury indeksu musi mieć adnotację typu.",
|
|
227
227
|
"An_index_signature_parameter_type_cannot_be_a_literal_type_or_generic_type_Consider_using_a_mapped_o_1337": "Typ parametru sygnatury indeksu nie może być typem literału ani typem ogólnym. Rozważ użycie zamiast tego mapowanego typu obiektu.",
|
|
228
228
|
"An_index_signature_parameter_type_must_be_string_number_symbol_or_a_template_literal_type_1268": "Parametr sygnatury indeksu musi mieć typ „string”, „number” lub „symbol” albo typ literału szablonu.",
|
|
229
|
+
"An_instantiation_expression_cannot_be_followed_by_a_property_access_1477": "Po wyrażeniu tworzenia wystąpienia nie może następować dostęp do właściwości.",
|
|
229
230
|
"An_interface_can_only_extend_an_identifier_Slashqualified_name_with_optional_type_arguments_2499": "Interfejs może rozszerzać tylko identyfikator/nazwę kwalifikowaną z opcjonalnymi argumentami typu.",
|
|
230
231
|
"An_interface_can_only_extend_an_object_type_or_intersection_of_object_types_with_statically_known_me_2312": "Interfejs może rozszerzać tylko typ obiektu lub część wspólną typów obiektów ze statycznie znanymi elementami członkowskimi.",
|
|
231
232
|
"An_interface_cannot_extend_a_primitive_type_like_0_an_interface_can_only_extend_named_types_and_clas_2840": "Interfejs nie może rozszerzyć typu pierwotnego, takiego jak „{0}”; interfejs może rozszerzać tylko nazwane typy i klasy",
|
|
@@ -1561,6 +1562,7 @@
|
|
|
1561
1562
|
"Type_library_referenced_via_0_from_file_1_with_packageId_2_1403": "Biblioteka typów jest przywoływana za pośrednictwem elementu „{0}” z pliku „{1}” o identyfikatorze packageId „{2}”",
|
|
1562
1563
|
"Type_of_await_operand_must_either_be_a_valid_promise_or_must_not_contain_a_callable_then_member_1320": "Typ operandu „await” musi być prawidłową obietnicą lub nie może zawierać wywoływalnej składowej „then”.",
|
|
1563
1564
|
"Type_of_computed_property_s_value_is_0_which_is_not_assignable_to_type_1_2418": "Typ wartości właściwości obliczanej to „{0}”, którego nie można przypisać do typu „{1}”.",
|
|
1565
|
+
"Type_of_instance_member_variable_0_cannot_reference_identifier_1_declared_in_the_constructor_2844": "Typ zmiennej składowej wystąpienia „{0}” nie może odwoływać się do identyfikatora „{1}” zadeklarowanego w konstruktorze.",
|
|
1564
1566
|
"Type_of_iterated_elements_of_a_yield_Asterisk_operand_must_either_be_a_valid_promise_or_must_not_con_1322": "Typ iterowanych elementów operandu „yield*” musi być prawidłową obietnicą lub nie może zawierać wywoływalnej składowej „then”.",
|
|
1565
1567
|
"Type_of_property_0_circularly_references_itself_in_mapped_type_1_2615": "Typ właściwości „{0}” cyklicznie odwołuje się do siebie w zamapowanym typie „{1}”.",
|
|
1566
1568
|
"Type_of_yield_operand_in_an_async_generator_must_either_be_a_valid_promise_or_must_not_contain_a_cal_1321": "Typ operandu „yield” w generatorze asynchronicznym musi być prawidłową obietnicą lub nie może zawierać wywoływalnej składowej „then”.",
|
|
@@ -226,6 +226,7 @@
|
|
|
226
226
|
"An_index_signature_parameter_must_have_a_type_annotation_1022": "Um parâmetro de assinatura de índice deve ter uma anotação de tipo.",
|
|
227
227
|
"An_index_signature_parameter_type_cannot_be_a_literal_type_or_generic_type_Consider_using_a_mapped_o_1337": "Um tipo de parâmetro de assinatura de índice não pode ser um tipo literal ou genérico. Considere usar um tipo de objeto mapeado.",
|
|
228
228
|
"An_index_signature_parameter_type_must_be_string_number_symbol_or_a_template_literal_type_1268": "Um tipo de parâmetro de assinatura de índice deve ser 'cadeia de caracteres', 'número', 'símbolo' ou um tipo literal de modelo.",
|
|
229
|
+
"An_instantiation_expression_cannot_be_followed_by_a_property_access_1477": "Uma expressão de instanciação não pode ser seguida por um acesso de propriedade.",
|
|
229
230
|
"An_interface_can_only_extend_an_identifier_Slashqualified_name_with_optional_type_arguments_2499": "Uma interface só pode estender um identificador/nome qualificado com argumentos de tipo opcionais.",
|
|
230
231
|
"An_interface_can_only_extend_an_object_type_or_intersection_of_object_types_with_statically_known_me_2312": "Uma interface só pode estender um tipo de objeto ou interseção de tipos de objeto com membros estaticamente conhecidos.",
|
|
231
232
|
"An_interface_cannot_extend_a_primitive_type_like_0_an_interface_can_only_extend_named_types_and_clas_2840": "Uma interface não pode estender um tipo primitivo como '{0}'; uma interface só pode estender tipos e classes nomeados",
|
|
@@ -1561,6 +1562,7 @@
|
|
|
1561
1562
|
"Type_library_referenced_via_0_from_file_1_with_packageId_2_1403": "Biblioteca de tipos referenciada via '{0}' do arquivo '{1}' com packageId '{2}'",
|
|
1562
1563
|
"Type_of_await_operand_must_either_be_a_valid_promise_or_must_not_contain_a_callable_then_member_1320": "O tipo de operando \"await\" deve ser uma promessa válida ou não deve conter um membro \"then\" que pode ser chamado.",
|
|
1563
1564
|
"Type_of_computed_property_s_value_is_0_which_is_not_assignable_to_type_1_2418": "O tipo de valor da propriedade computada é '{0}', que não pode ser atribuído ao tipo '{1}'.",
|
|
1565
|
+
"Type_of_instance_member_variable_0_cannot_reference_identifier_1_declared_in_the_constructor_2844": "O tipo de variável '{0}' de membro de instância não pode referenciar o identificador '{1}' declarado no construtor.",
|
|
1564
1566
|
"Type_of_iterated_elements_of_a_yield_Asterisk_operand_must_either_be_a_valid_promise_or_must_not_con_1322": "O tipo de elementos iterados de um operando \"yield*\" deve ser uma promessa válida ou não deve conter um membro \"then\" que pode ser chamado.",
|
|
1565
1567
|
"Type_of_property_0_circularly_references_itself_in_mapped_type_1_2615": "O tipo de propriedade '{0}' faz referência circular a si mesmo no tipo mapeado '{1}'.",
|
|
1566
1568
|
"Type_of_yield_operand_in_an_async_generator_must_either_be_a_valid_promise_or_must_not_contain_a_cal_1321": "O tipo do operando \"yield\" em um gerador assíncrono deve ser uma promessa válida ou não deve conter um membro \"then\" que pode ser chamado.",
|
|
@@ -226,6 +226,7 @@
|
|
|
226
226
|
"An_index_signature_parameter_must_have_a_type_annotation_1022": "У параметра сигнатуры индекса должна быть аннотация типа.",
|
|
227
227
|
"An_index_signature_parameter_type_cannot_be_a_literal_type_or_generic_type_Consider_using_a_mapped_o_1337": "Тип параметра сигнатуры индекса не может быть типом литерала или универсальным типом. Рекомендуется использовать тип сопоставляемого объекта.",
|
|
228
228
|
"An_index_signature_parameter_type_must_be_string_number_symbol_or_a_template_literal_type_1268": "Тип параметра сигнатуры индекса должен быть строкой, числом, символом или типом литерала шаблона.",
|
|
229
|
+
"An_instantiation_expression_cannot_be_followed_by_a_property_access_1477": "За выражением создания экземпляра не может следовать доступ к свойству.",
|
|
229
230
|
"An_interface_can_only_extend_an_identifier_Slashqualified_name_with_optional_type_arguments_2499": "Интерфейс может расширить только идентификатор или полное имя с дополнительными аргументами типа.",
|
|
230
231
|
"An_interface_can_only_extend_an_object_type_or_intersection_of_object_types_with_statically_known_me_2312": "Интерфейс может расширять только тип объекта или пересечение типов объектов со статическими известными членами.",
|
|
231
232
|
"An_interface_cannot_extend_a_primitive_type_like_0_an_interface_can_only_extend_named_types_and_clas_2840": "Интерфейс не может расширять примитивный тип, например \"{0}\". Интерфейс может расширять только именованные типы и классы",
|
|
@@ -1561,6 +1562,7 @@
|
|
|
1561
1562
|
"Type_library_referenced_via_0_from_file_1_with_packageId_2_1403": "Библиотека типов, на которую осуществляется ссылка с помощью \"{0}\" из файла \"{1}\" с идентификатором пакета \"{2}\"",
|
|
1562
1563
|
"Type_of_await_operand_must_either_be_a_valid_promise_or_must_not_contain_a_callable_then_member_1320": "Тип операнда \"await\" должен быть допустимым обещанием либо не должен содержать вызываемый элемент \"then\".",
|
|
1563
1564
|
"Type_of_computed_property_s_value_is_0_which_is_not_assignable_to_type_1_2418": "Типом значения вычисляемого свойства является \"{0}\", который не может быть назначен типу \"{1}\".",
|
|
1565
|
+
"Type_of_instance_member_variable_0_cannot_reference_identifier_1_declared_in_the_constructor_2844": "Инициализатор переменной-элемента экземпляра \"{0}\" не может ссылаться на идентификатор \"{1}\", объявленный в конструкторе.",
|
|
1564
1566
|
"Type_of_iterated_elements_of_a_yield_Asterisk_operand_must_either_be_a_valid_promise_or_must_not_con_1322": "Тип элементов итерации для операнда \"yield*\" должен быть допустимым обещанием либо не должен содержать вызываемый элемент \"then\".",
|
|
1565
1567
|
"Type_of_property_0_circularly_references_itself_in_mapped_type_1_2615": "Тип свойства \"{0}\" циклически ссылается на самого себя в сопоставленном типе \"{1}\".",
|
|
1566
1568
|
"Type_of_yield_operand_in_an_async_generator_must_either_be_a_valid_promise_or_must_not_contain_a_cal_1321": "Тип операнда \"yield\" в асинхронном генераторе должен быть допустимым обещанием либо не должен содержать вызываемый элемент \"then\".",
|
|
@@ -226,6 +226,7 @@
|
|
|
226
226
|
"An_index_signature_parameter_must_have_a_type_annotation_1022": "Dizin imzası parametresi, bir tür ek açıklamasına sahip olmalıdır.",
|
|
227
227
|
"An_index_signature_parameter_type_cannot_be_a_literal_type_or_generic_type_Consider_using_a_mapped_o_1337": "Dizin imzası parametre türü sabit değer veya genel tür olamaz. Bunun yerine eşlenen nesne türü kullanabilirsiniz.",
|
|
228
228
|
"An_index_signature_parameter_type_must_be_string_number_symbol_or_a_template_literal_type_1268": "Dizin imzası parametre türü 'dize', 'sayı', 'sembol' veya şablon sabit değeri olmalıdır.",
|
|
229
|
+
"An_instantiation_expression_cannot_be_followed_by_a_property_access_1477": "Bir örnek oluşturma ifadesinin ardından özellik erişimi gelemez.",
|
|
229
230
|
"An_interface_can_only_extend_an_identifier_Slashqualified_name_with_optional_type_arguments_2499": "Bir arabirim, isteğe bağlı tür bağımsız değişkenleri ile yalnızca bir tanımlayıcıyı/tam adı genişletebilir.",
|
|
230
231
|
"An_interface_can_only_extend_an_object_type_or_intersection_of_object_types_with_statically_known_me_2312": "Arabirim, yalnızca statik olarak bilinen üyelere sahip bir nesne türünü veya nesne türlerinin bir kesişimini genişletebilir.",
|
|
231
232
|
"An_interface_cannot_extend_a_primitive_type_like_0_an_interface_can_only_extend_named_types_and_clas_2840": "Arabirim, '{0}' gibi temel bir türü genişletemez; arabirim yalnızca adlandırılmış türleri ve sınıfları genişletilebilir",
|
|
@@ -1561,6 +1562,7 @@
|
|
|
1561
1562
|
"Type_library_referenced_via_0_from_file_1_with_packageId_2_1403": "'{2}' paket kimliğine sahip '{1}' dosyasından '{0}' aracılığıyla başvurulan tür kitaplığı",
|
|
1562
1563
|
"Type_of_await_operand_must_either_be_a_valid_promise_or_must_not_contain_a_callable_then_member_1320": "'await' işleneninin türü, geçerli bir promise olmalı veya çağrılabilir 'then' üyesi içermemelidir.",
|
|
1563
1564
|
"Type_of_computed_property_s_value_is_0_which_is_not_assignable_to_type_1_2418": "Hesaplanan özellik değerinin '{0}' türü, '{1}' türüne atanamıyor.",
|
|
1565
|
+
"Type_of_instance_member_variable_0_cannot_reference_identifier_1_declared_in_the_constructor_2844": "'{0}' örnek üyesi değişkeninin türü, oluşturucuda bildirilen '{1}' tanımlayıcısına başvuramaz.",
|
|
1564
1566
|
"Type_of_iterated_elements_of_a_yield_Asterisk_operand_must_either_be_a_valid_promise_or_must_not_con_1322": "Bir 'yield*' işleneninin yinelenen öğelerinin türü, geçerli bir promise olmalı veya çağrılabilir 'then' üyesi içermemelidir.",
|
|
1565
1567
|
"Type_of_property_0_circularly_references_itself_in_mapped_type_1_2615": "'{0}' özelliğinin türü, '{1}' eşlenmiş türünde döngüsel olarak kendine başvuruyor.",
|
|
1566
1568
|
"Type_of_yield_operand_in_an_async_generator_must_either_be_a_valid_promise_or_must_not_contain_a_cal_1321": "Zaman uyumsuz bir oluşturucudaki 'yield' işleneninin türü, geçerli bir promise olmalı veya çağrılabilir 'then' üyesi içermemelidir.",
|
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.8";
|
|
72
|
-
ts.version = ts.versionMajorMinor + ".0-dev.
|
|
72
|
+
ts.version = ts.versionMajorMinor + ".0-dev.20220725";
|
|
73
73
|
var NativeCollections;
|
|
74
74
|
(function (NativeCollections) {
|
|
75
75
|
var globals = typeof globalThis !== "undefined" ? globalThis :
|
|
@@ -4317,8 +4317,10 @@ var ts;
|
|
|
4317
4317
|
watchPresentFileSystemEntry();
|
|
4318
4318
|
return {
|
|
4319
4319
|
close: function () {
|
|
4320
|
-
watcher
|
|
4321
|
-
|
|
4320
|
+
if (watcher) {
|
|
4321
|
+
watcher.close();
|
|
4322
|
+
watcher = undefined;
|
|
4323
|
+
}
|
|
4322
4324
|
}
|
|
4323
4325
|
};
|
|
4324
4326
|
function updateWatcher(createWatcher) {
|
|
@@ -56677,34 +56679,28 @@ var ts;
|
|
|
56677
56679
|
var commonBaseType;
|
|
56678
56680
|
for (var _i = 0, types_13 = types; _i < types_13.length; _i++) {
|
|
56679
56681
|
var t = types_13[_i];
|
|
56680
|
-
|
|
56681
|
-
|
|
56682
|
-
commonBaseType = baseType;
|
|
56683
|
-
|
|
56684
|
-
|
|
56685
|
-
|
|
56682
|
+
if (!(t.flags & 131072)) {
|
|
56683
|
+
var baseType = getBaseTypeOfLiteralType(t);
|
|
56684
|
+
commonBaseType !== null && commonBaseType !== void 0 ? commonBaseType : (commonBaseType = baseType);
|
|
56685
|
+
if (baseType === t || baseType !== commonBaseType) {
|
|
56686
|
+
return false;
|
|
56687
|
+
}
|
|
56686
56688
|
}
|
|
56687
56689
|
}
|
|
56688
56690
|
return true;
|
|
56689
56691
|
}
|
|
56690
|
-
function
|
|
56691
|
-
|
|
56692
|
-
return types[0];
|
|
56693
|
-
}
|
|
56694
|
-
return literalTypesWithSameBaseType(types) ?
|
|
56695
|
-
getUnionType(types) :
|
|
56696
|
-
ts.reduceLeft(types, function (s, t) { return isTypeSubtypeOf(s, t) ? t : s; });
|
|
56692
|
+
function getCombinedTypeFlags(types) {
|
|
56693
|
+
return ts.reduceLeft(types, function (flags, t) { return flags | (t.flags & 1048576 ? getCombinedTypeFlags(t.types) : t.flags); }, 0);
|
|
56697
56694
|
}
|
|
56698
56695
|
function getCommonSupertype(types) {
|
|
56699
|
-
if (
|
|
56700
|
-
return
|
|
56701
|
-
}
|
|
56702
|
-
var primaryTypes = ts.filter(types, function (t) { return !(t.flags & 98304); });
|
|
56703
|
-
if (primaryTypes.length) {
|
|
56704
|
-
var supertypeOrUnion = getSupertypeOrUnion(primaryTypes);
|
|
56705
|
-
return primaryTypes === types ? supertypeOrUnion : getUnionType(__spreadArray([supertypeOrUnion], ts.filter(types, function (t) { return !!(t.flags & 98304); }), true));
|
|
56696
|
+
if (types.length === 1) {
|
|
56697
|
+
return types[0];
|
|
56706
56698
|
}
|
|
56707
|
-
|
|
56699
|
+
var primaryTypes = strictNullChecks ? ts.sameMap(types, function (t) { return filterType(t, function (u) { return !(u.flags & 98304); }); }) : types;
|
|
56700
|
+
var superTypeOrUnion = literalTypesWithSameBaseType(primaryTypes) ?
|
|
56701
|
+
getUnionType(primaryTypes) :
|
|
56702
|
+
ts.reduceLeft(primaryTypes, function (s, t) { return isTypeSubtypeOf(s, t) ? t : s; });
|
|
56703
|
+
return primaryTypes === types ? superTypeOrUnion : getNullableType(superTypeOrUnion, getCombinedTypeFlags(types) & 98304);
|
|
56708
56704
|
}
|
|
56709
56705
|
function getCommonSubtype(types) {
|
|
56710
56706
|
return ts.reduceLeft(types, function (s, t) { return isTypeSubtypeOf(t, s) ? t : s; });
|
|
@@ -66741,7 +66737,11 @@ var ts;
|
|
|
66741
66737
|
var operator = operatorToken.kind;
|
|
66742
66738
|
if (operator === 55 || operator === 56 || operator === 60) {
|
|
66743
66739
|
if (operator === 55) {
|
|
66744
|
-
var parent =
|
|
66740
|
+
var parent = node.parent;
|
|
66741
|
+
while (parent.kind === 212
|
|
66742
|
+
|| ts.isBinaryExpression(parent) && (parent.operatorToken.kind === 55 || parent.operatorToken.kind === 56)) {
|
|
66743
|
+
parent = parent.parent;
|
|
66744
|
+
}
|
|
66745
66745
|
checkTestingKnownTruthyCallableOrAwaitableType(node.left, ts.isIfStatement(parent) ? parent.thenStatement : undefined);
|
|
66746
66746
|
}
|
|
66747
66747
|
checkTruthinessOfType(leftType, node.left);
|
|
@@ -76304,13 +76304,13 @@ var ts;
|
|
|
76304
76304
|
return factory.updateInferTypeNode(node, nodeVisitor(node.typeParameter, visitor, ts.isTypeParameterDeclaration));
|
|
76305
76305
|
case 200:
|
|
76306
76306
|
ts.Debug.type(node);
|
|
76307
|
-
return factory.updateImportTypeNode(node, nodeVisitor(node.argument, visitor, ts.isTypeNode), nodeVisitor(node.assertions, visitor, ts.isNode), nodeVisitor(node.qualifier, visitor, ts.isEntityName),
|
|
76307
|
+
return factory.updateImportTypeNode(node, nodeVisitor(node.argument, visitor, ts.isTypeNode), nodeVisitor(node.assertions, visitor, ts.isNode), nodeVisitor(node.qualifier, visitor, ts.isEntityName), nodesVisitor(node.typeArguments, visitor, ts.isTypeNode), node.isTypeOf);
|
|
76308
76308
|
case 295:
|
|
76309
76309
|
ts.Debug.type(node);
|
|
76310
76310
|
return factory.updateImportTypeAssertionContainer(node, nodeVisitor(node.assertClause, visitor, ts.isNode), node.multiLine);
|
|
76311
76311
|
case 197:
|
|
76312
76312
|
ts.Debug.type(node);
|
|
76313
|
-
return factory.updateNamedTupleMember(node,
|
|
76313
|
+
return factory.updateNamedTupleMember(node, nodeVisitor(node.dotDotDotToken, visitor, ts.isDotDotDotToken), nodeVisitor(node.name, visitor, ts.isIdentifier), nodeVisitor(node.questionToken, visitor, ts.isQuestionToken), nodeVisitor(node.type, visitor, ts.isTypeNode));
|
|
76314
76314
|
case 191:
|
|
76315
76315
|
ts.Debug.type(node);
|
|
76316
76316
|
return factory.updateParenthesizedType(node, nodeVisitor(node.type, visitor, ts.isTypeNode));
|
|
@@ -76373,7 +76373,7 @@ var ts;
|
|
|
76373
76373
|
return factory.updateNewExpression(node, nodeVisitor(node.expression, visitor, ts.isExpression), nodesVisitor(node.typeArguments, visitor, ts.isTypeNode), nodesVisitor(node.arguments, visitor, ts.isExpression));
|
|
76374
76374
|
case 210:
|
|
76375
76375
|
ts.Debug.type(node);
|
|
76376
|
-
return factory.updateTaggedTemplateExpression(node, nodeVisitor(node.tag, visitor, ts.isExpression),
|
|
76376
|
+
return factory.updateTaggedTemplateExpression(node, nodeVisitor(node.tag, visitor, ts.isExpression), nodesVisitor(node.typeArguments, visitor, ts.isTypeNode), nodeVisitor(node.template, visitor, ts.isTemplateLiteral));
|
|
76377
76377
|
case 211:
|
|
76378
76378
|
ts.Debug.type(node);
|
|
76379
76379
|
return factory.updateTypeAssertion(node, nodeVisitor(node.type, visitor, ts.isTypeNode), nodeVisitor(node.expression, visitor, ts.isExpression));
|
package/lib/tsserver.js
CHANGED
|
@@ -109,7 +109,7 @@ var ts;
|
|
|
109
109
|
// The following is baselined as a literal template type without intervention
|
|
110
110
|
/** The version of the TypeScript compiler release */
|
|
111
111
|
// eslint-disable-next-line @typescript-eslint/no-inferrable-types
|
|
112
|
-
ts.version = ts.versionMajorMinor + ".0-dev.
|
|
112
|
+
ts.version = ts.versionMajorMinor + ".0-dev.20220725";
|
|
113
113
|
/* @internal */
|
|
114
114
|
var Comparison;
|
|
115
115
|
(function (Comparison) {
|
|
@@ -6857,8 +6857,10 @@ var ts;
|
|
|
6857
6857
|
return {
|
|
6858
6858
|
close: function () {
|
|
6859
6859
|
// Close the watcher (either existing file system entry watcher or missing file system entry watcher)
|
|
6860
|
-
watcher
|
|
6861
|
-
|
|
6860
|
+
if (watcher) {
|
|
6861
|
+
watcher.close();
|
|
6862
|
+
watcher = undefined;
|
|
6863
|
+
}
|
|
6862
6864
|
}
|
|
6863
6865
|
};
|
|
6864
6866
|
function updateWatcher(createWatcher) {
|
|
@@ -67946,37 +67948,33 @@ var ts;
|
|
|
67946
67948
|
var commonBaseType;
|
|
67947
67949
|
for (var _i = 0, types_13 = types; _i < types_13.length; _i++) {
|
|
67948
67950
|
var t = types_13[_i];
|
|
67949
|
-
|
|
67950
|
-
|
|
67951
|
-
commonBaseType = baseType;
|
|
67952
|
-
|
|
67953
|
-
|
|
67954
|
-
|
|
67951
|
+
if (!(t.flags & 131072 /* Never */)) {
|
|
67952
|
+
var baseType = getBaseTypeOfLiteralType(t);
|
|
67953
|
+
commonBaseType !== null && commonBaseType !== void 0 ? commonBaseType : (commonBaseType = baseType);
|
|
67954
|
+
if (baseType === t || baseType !== commonBaseType) {
|
|
67955
|
+
return false;
|
|
67956
|
+
}
|
|
67955
67957
|
}
|
|
67956
67958
|
}
|
|
67957
67959
|
return true;
|
|
67958
67960
|
}
|
|
67959
|
-
|
|
67960
|
-
|
|
67961
|
-
// right is a supertype.
|
|
67962
|
-
function getSupertypeOrUnion(types) {
|
|
67963
|
-
if (types.length === 1) {
|
|
67964
|
-
return types[0];
|
|
67965
|
-
}
|
|
67966
|
-
return literalTypesWithSameBaseType(types) ?
|
|
67967
|
-
getUnionType(types) :
|
|
67968
|
-
ts.reduceLeft(types, function (s, t) { return isTypeSubtypeOf(s, t) ? t : s; });
|
|
67961
|
+
function getCombinedTypeFlags(types) {
|
|
67962
|
+
return ts.reduceLeft(types, function (flags, t) { return flags | (t.flags & 1048576 /* Union */ ? getCombinedTypeFlags(t.types) : t.flags); }, 0);
|
|
67969
67963
|
}
|
|
67970
67964
|
function getCommonSupertype(types) {
|
|
67971
|
-
if (
|
|
67972
|
-
return
|
|
67973
|
-
}
|
|
67974
|
-
var primaryTypes = ts.filter(types, function (t) { return !(t.flags & 98304 /* Nullable */); });
|
|
67975
|
-
if (primaryTypes.length) {
|
|
67976
|
-
var supertypeOrUnion = getSupertypeOrUnion(primaryTypes);
|
|
67977
|
-
return primaryTypes === types ? supertypeOrUnion : getUnionType(__spreadArray([supertypeOrUnion], ts.filter(types, function (t) { return !!(t.flags & 98304 /* Nullable */); }), true));
|
|
67965
|
+
if (types.length === 1) {
|
|
67966
|
+
return types[0];
|
|
67978
67967
|
}
|
|
67979
|
-
|
|
67968
|
+
// Remove nullable types from each of the candidates.
|
|
67969
|
+
var primaryTypes = strictNullChecks ? ts.sameMap(types, function (t) { return filterType(t, function (u) { return !(u.flags & 98304 /* Nullable */); }); }) : types;
|
|
67970
|
+
// When the candidate types are all literal types with the same base type, return a union
|
|
67971
|
+
// of those literal types. Otherwise, return the leftmost type for which no type to the
|
|
67972
|
+
// right is a supertype.
|
|
67973
|
+
var superTypeOrUnion = literalTypesWithSameBaseType(primaryTypes) ?
|
|
67974
|
+
getUnionType(primaryTypes) :
|
|
67975
|
+
ts.reduceLeft(primaryTypes, function (s, t) { return isTypeSubtypeOf(s, t) ? t : s; });
|
|
67976
|
+
// Add any nullable types that occurred in the candidates back to the result.
|
|
67977
|
+
return primaryTypes === types ? superTypeOrUnion : getNullableType(superTypeOrUnion, getCombinedTypeFlags(types) & 98304 /* Nullable */);
|
|
67980
67978
|
}
|
|
67981
67979
|
// Return the leftmost type for which no type to the right is a subtype.
|
|
67982
67980
|
function getCommonSubtype(types) {
|
|
@@ -79638,7 +79636,11 @@ var ts;
|
|
|
79638
79636
|
var operator = operatorToken.kind;
|
|
79639
79637
|
if (operator === 55 /* AmpersandAmpersandToken */ || operator === 56 /* BarBarToken */ || operator === 60 /* QuestionQuestionToken */) {
|
|
79640
79638
|
if (operator === 55 /* AmpersandAmpersandToken */) {
|
|
79641
|
-
var parent =
|
|
79639
|
+
var parent = node.parent;
|
|
79640
|
+
while (parent.kind === 212 /* ParenthesizedExpression */
|
|
79641
|
+
|| ts.isBinaryExpression(parent) && (parent.operatorToken.kind === 55 /* AmpersandAmpersandToken */ || parent.operatorToken.kind === 56 /* BarBarToken */)) {
|
|
79642
|
+
parent = parent.parent;
|
|
79643
|
+
}
|
|
79642
79644
|
checkTestingKnownTruthyCallableOrAwaitableType(node.left, ts.isIfStatement(parent) ? parent.thenStatement : undefined);
|
|
79643
79645
|
}
|
|
79644
79646
|
checkTruthinessOfType(leftType, node.left);
|
|
@@ -90560,13 +90562,13 @@ var ts;
|
|
|
90560
90562
|
return factory.updateInferTypeNode(node, nodeVisitor(node.typeParameter, visitor, ts.isTypeParameterDeclaration));
|
|
90561
90563
|
case 200 /* ImportType */:
|
|
90562
90564
|
ts.Debug.type(node);
|
|
90563
|
-
return factory.updateImportTypeNode(node, nodeVisitor(node.argument, visitor, ts.isTypeNode), nodeVisitor(node.assertions, visitor, ts.isNode), nodeVisitor(node.qualifier, visitor, ts.isEntityName),
|
|
90565
|
+
return factory.updateImportTypeNode(node, nodeVisitor(node.argument, visitor, ts.isTypeNode), nodeVisitor(node.assertions, visitor, ts.isNode), nodeVisitor(node.qualifier, visitor, ts.isEntityName), nodesVisitor(node.typeArguments, visitor, ts.isTypeNode), node.isTypeOf);
|
|
90564
90566
|
case 295 /* ImportTypeAssertionContainer */:
|
|
90565
90567
|
ts.Debug.type(node);
|
|
90566
90568
|
return factory.updateImportTypeAssertionContainer(node, nodeVisitor(node.assertClause, visitor, ts.isNode), node.multiLine);
|
|
90567
90569
|
case 197 /* NamedTupleMember */:
|
|
90568
90570
|
ts.Debug.type(node);
|
|
90569
|
-
return factory.updateNamedTupleMember(node,
|
|
90571
|
+
return factory.updateNamedTupleMember(node, nodeVisitor(node.dotDotDotToken, visitor, ts.isDotDotDotToken), nodeVisitor(node.name, visitor, ts.isIdentifier), nodeVisitor(node.questionToken, visitor, ts.isQuestionToken), nodeVisitor(node.type, visitor, ts.isTypeNode));
|
|
90570
90572
|
case 191 /* ParenthesizedType */:
|
|
90571
90573
|
ts.Debug.type(node);
|
|
90572
90574
|
return factory.updateParenthesizedType(node, nodeVisitor(node.type, visitor, ts.isTypeNode));
|
|
@@ -90631,7 +90633,7 @@ var ts;
|
|
|
90631
90633
|
return factory.updateNewExpression(node, nodeVisitor(node.expression, visitor, ts.isExpression), nodesVisitor(node.typeArguments, visitor, ts.isTypeNode), nodesVisitor(node.arguments, visitor, ts.isExpression));
|
|
90632
90634
|
case 210 /* TaggedTemplateExpression */:
|
|
90633
90635
|
ts.Debug.type(node);
|
|
90634
|
-
return factory.updateTaggedTemplateExpression(node, nodeVisitor(node.tag, visitor, ts.isExpression),
|
|
90636
|
+
return factory.updateTaggedTemplateExpression(node, nodeVisitor(node.tag, visitor, ts.isExpression), nodesVisitor(node.typeArguments, visitor, ts.isTypeNode), nodeVisitor(node.template, visitor, ts.isTemplateLiteral));
|
|
90635
90637
|
case 211 /* TypeAssertionExpression */:
|
|
90636
90638
|
ts.Debug.type(node);
|
|
90637
90639
|
return factory.updateTypeAssertion(node, nodeVisitor(node.type, visitor, ts.isTypeNode), nodeVisitor(node.expression, visitor, ts.isExpression));
|
|
@@ -148845,6 +148847,7 @@ var ts;
|
|
|
148845
148847
|
consumeTokenAndAdvanceScanner(tokenInfo, node, nodeDynamicIndentation, node);
|
|
148846
148848
|
}
|
|
148847
148849
|
function processChildNode(child, inheritedIndentation, parent, parentDynamicIndentation, parentStartLine, undecoratedParentStartLine, isListItem, isFirstListItem) {
|
|
148850
|
+
ts.Debug.assert(!ts.nodeIsSynthesized(child));
|
|
148848
148851
|
if (ts.nodeIsMissing(child)) {
|
|
148849
148852
|
return inheritedIndentation;
|
|
148850
148853
|
}
|
|
@@ -148911,6 +148914,7 @@ var ts;
|
|
|
148911
148914
|
}
|
|
148912
148915
|
function processChildNodes(nodes, parent, parentStartLine, parentDynamicIndentation) {
|
|
148913
148916
|
ts.Debug.assert(ts.isNodeArray(nodes));
|
|
148917
|
+
ts.Debug.assert(!ts.nodeIsSynthesized(nodes));
|
|
148914
148918
|
var listStartToken = getOpenTokenForList(parent, nodes);
|
|
148915
148919
|
var listDynamicIndentation = parentDynamicIndentation;
|
|
148916
148920
|
var startLine = parentStartLine;
|
|
@@ -155370,54 +155374,91 @@ var ts;
|
|
|
155370
155374
|
codefix.registerCodeFix({
|
|
155371
155375
|
errorCodes: errorCodes,
|
|
155372
155376
|
getCodeActions: function (context) {
|
|
155373
|
-
var sourceFile = context.sourceFile, span = context.span, program = context.program;
|
|
155374
|
-
var
|
|
155375
|
-
if (
|
|
155377
|
+
var sourceFile = context.sourceFile, span = context.span, program = context.program, preferences = context.preferences, host = context.host;
|
|
155378
|
+
var info = getInfo(program, sourceFile, span);
|
|
155379
|
+
if (info === undefined)
|
|
155376
155380
|
return;
|
|
155377
|
-
}
|
|
155378
|
-
var changes = ts.textChanges.ChangeTracker.with(context, function (t) { return addMissingConstraint(t, related); });
|
|
155381
|
+
var changes = ts.textChanges.ChangeTracker.with(context, function (t) { return addMissingConstraint(t, program, preferences, host, sourceFile, info); });
|
|
155379
155382
|
return [codefix.createCodeFixAction(fixId, changes, ts.Diagnostics.Add_extends_constraint, fixId, ts.Diagnostics.Add_extends_constraint_to_all_type_parameters)];
|
|
155380
155383
|
},
|
|
155381
155384
|
fixIds: [fixId],
|
|
155382
|
-
getAllCodeActions: function (context) {
|
|
155383
|
-
var
|
|
155384
|
-
|
|
155385
|
-
|
|
155386
|
-
|
|
155387
|
-
|
|
155385
|
+
getAllCodeActions: function (context) {
|
|
155386
|
+
var program = context.program, preferences = context.preferences, host = context.host;
|
|
155387
|
+
var seen = new ts.Map();
|
|
155388
|
+
return codefix.createCombinedCodeActions(ts.textChanges.ChangeTracker.with(context, function (changes) {
|
|
155389
|
+
codefix.eachDiagnostic(context, errorCodes, function (diag) {
|
|
155390
|
+
var info = getInfo(program, diag.file, ts.createTextSpan(diag.start, diag.length));
|
|
155391
|
+
if (info) {
|
|
155392
|
+
var id = ts.getNodeId(info.declaration) + "#" + info.token.getText();
|
|
155393
|
+
if (ts.addToSeen(seen, id)) {
|
|
155394
|
+
return addMissingConstraint(changes, program, preferences, host, diag.file, info);
|
|
155395
|
+
}
|
|
155396
|
+
}
|
|
155397
|
+
return undefined;
|
|
155398
|
+
});
|
|
155399
|
+
}));
|
|
155400
|
+
}
|
|
155388
155401
|
});
|
|
155389
|
-
function
|
|
155402
|
+
function getInfo(program, sourceFile, span) {
|
|
155390
155403
|
var diag = ts.find(program.getSemanticDiagnostics(sourceFile), function (diag) { return diag.start === span.start && diag.length === span.length; });
|
|
155391
|
-
if (
|
|
155404
|
+
if (diag === undefined || diag.relatedInformation === undefined)
|
|
155392
155405
|
return;
|
|
155393
155406
|
var related = ts.find(diag.relatedInformation, function (related) { return related.code === ts.Diagnostics.This_type_parameter_might_need_an_extends_0_constraint.code; });
|
|
155394
|
-
if (
|
|
155407
|
+
if (related === undefined || related.file === undefined || related.start === undefined || related.length === undefined)
|
|
155395
155408
|
return;
|
|
155396
|
-
|
|
155397
|
-
|
|
155398
|
-
function addMissingConstraint(changes, related) {
|
|
155399
|
-
var decl = findAncestorMatchingSpan(related.file, related);
|
|
155400
|
-
if (!decl)
|
|
155409
|
+
var declaration = findAncestorMatchingSpan(related.file, ts.createTextSpan(related.start, related.length));
|
|
155410
|
+
if (declaration === undefined)
|
|
155401
155411
|
return;
|
|
155402
|
-
if (ts.isIdentifier(
|
|
155403
|
-
|
|
155412
|
+
if (ts.isIdentifier(declaration) && ts.isTypeParameterDeclaration(declaration.parent)) {
|
|
155413
|
+
declaration = declaration.parent;
|
|
155414
|
+
}
|
|
155415
|
+
if (ts.isTypeParameterDeclaration(declaration)) {
|
|
155416
|
+
// should only issue fix on type parameters written using `extends`
|
|
155417
|
+
if (ts.isMappedTypeNode(declaration.parent))
|
|
155418
|
+
return;
|
|
155419
|
+
var token = ts.getTokenAtPosition(sourceFile, span.start);
|
|
155420
|
+
var checker = program.getTypeChecker();
|
|
155421
|
+
var constraint = tryGetConstraintType(checker, token) || tryGetConstraintFromDiagnosticMessage(related.messageText);
|
|
155422
|
+
return { constraint: constraint, declaration: declaration, token: token };
|
|
155423
|
+
}
|
|
155424
|
+
return undefined;
|
|
155425
|
+
}
|
|
155426
|
+
function addMissingConstraint(changes, program, preferences, host, sourceFile, info) {
|
|
155427
|
+
var declaration = info.declaration, constraint = info.constraint;
|
|
155428
|
+
var checker = program.getTypeChecker();
|
|
155429
|
+
if (ts.isString(constraint)) {
|
|
155430
|
+
changes.insertText(sourceFile, declaration.name.end, " extends " + constraint);
|
|
155431
|
+
}
|
|
155432
|
+
else {
|
|
155433
|
+
var scriptTarget = ts.getEmitScriptTarget(program.getCompilerOptions());
|
|
155434
|
+
var tracker = codefix.getNoopSymbolTrackerWithResolver({ program: program, host: host });
|
|
155435
|
+
var importAdder = codefix.createImportAdder(sourceFile, program, preferences, host);
|
|
155436
|
+
var typeNode = codefix.typeToAutoImportableTypeNode(checker, importAdder, constraint, /*contextNode*/ undefined, scriptTarget, /*flags*/ undefined, tracker);
|
|
155437
|
+
if (typeNode) {
|
|
155438
|
+
changes.replaceNode(sourceFile, declaration, ts.factory.updateTypeParameterDeclaration(declaration, /*modifiers*/ undefined, declaration.name, typeNode, declaration.default));
|
|
155439
|
+
importAdder.writeFixes(changes);
|
|
155440
|
+
}
|
|
155404
155441
|
}
|
|
155405
|
-
if (!ts.isTypeParameterDeclaration(decl) || ts.isMappedTypeNode(decl.parent))
|
|
155406
|
-
return; // should only issue fix on type parameters written using `extends`
|
|
155407
|
-
var newConstraint = ts.flattenDiagnosticMessageText(related.messageText, "\n", 0).match(/`extends (.*)`/);
|
|
155408
|
-
if (!newConstraint)
|
|
155409
|
-
return;
|
|
155410
|
-
var newConstraintText = newConstraint[1];
|
|
155411
|
-
changes.insertText(related.file, decl.name.end, " extends " + newConstraintText);
|
|
155412
155442
|
}
|
|
155413
155443
|
function findAncestorMatchingSpan(sourceFile, span) {
|
|
155414
|
-
var token = ts.getTokenAtPosition(sourceFile, span.start);
|
|
155415
155444
|
var end = ts.textSpanEnd(span);
|
|
155445
|
+
var token = ts.getTokenAtPosition(sourceFile, span.start);
|
|
155416
155446
|
while (token.end < end) {
|
|
155417
155447
|
token = token.parent;
|
|
155418
155448
|
}
|
|
155419
155449
|
return token;
|
|
155420
155450
|
}
|
|
155451
|
+
function tryGetConstraintFromDiagnosticMessage(messageText) {
|
|
155452
|
+
var _a = ts.flattenDiagnosticMessageText(messageText, "\n", 0).match(/`extends (.*)`/) || [], _ = _a[0], constraint = _a[1];
|
|
155453
|
+
return constraint;
|
|
155454
|
+
}
|
|
155455
|
+
function tryGetConstraintType(checker, node) {
|
|
155456
|
+
if (ts.isTypeNode(node.parent)) {
|
|
155457
|
+
return checker.getTypeArgumentConstraint(node.parent);
|
|
155458
|
+
}
|
|
155459
|
+
var contextualType = ts.isExpression(node) ? checker.getContextualType(node) : undefined;
|
|
155460
|
+
return contextualType || checker.getTypeAtLocation(node);
|
|
155461
|
+
}
|
|
155421
155462
|
})(codefix = ts.codefix || (ts.codefix = {}));
|
|
155422
155463
|
})(ts || (ts = {}));
|
|
155423
155464
|
/* @internal */
|