@typescript-deploys/pr-build 5.6.0-pr-59519-6 → 5.6.0-pr-59644-8
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/de/diagnosticMessages.generated.json +1 -0
- package/lib/es/diagnosticMessages.generated.json +1 -0
- package/lib/fr/diagnosticMessages.generated.json +1 -0
- package/lib/it/diagnosticMessages.generated.json +1 -0
- package/lib/ja/diagnosticMessages.generated.json +1 -0
- package/lib/ko/diagnosticMessages.generated.json +1 -0
- package/lib/pt-br/diagnosticMessages.generated.json +1 -0
- package/lib/ru/diagnosticMessages.generated.json +1 -0
- package/lib/tr/diagnosticMessages.generated.json +1 -0
- package/lib/tsc.js +26 -29
- package/lib/typescript.js +67 -105
- package/lib/zh-tw/diagnosticMessages.generated.json +1 -0
- package/package.json +1 -1
|
@@ -62,6 +62,7 @@
|
|
|
62
62
|
"A_namespace_declaration_cannot_be_in_a_different_file_from_a_class_or_function_with_which_it_is_merg_2433": "Eine Namespacedeklaration darf sich nicht in einer anderen Datei als die Klasse oder Funktion befinden, mit der sie zusammengeführt wird.",
|
|
63
63
|
"A_namespace_declaration_cannot_be_located_prior_to_a_class_or_function_with_which_it_is_merged_2434": "Eine Namespacedeklaration darf nicht vor der Klasse oder Funktion positioniert werden, mit der sie zusammengeführt wird.",
|
|
64
64
|
"A_namespace_declaration_is_only_allowed_at_the_top_level_of_a_namespace_or_module_1235": "Eine Namespacedeklaration ist nur auf der obersten Ebene eines Namespaces oder Moduls zulässig.",
|
|
65
|
+
"A_namespace_declaration_should_not_be_declared_using_the_module_keyword_Please_use_the_namespace_key_1540": "Eine Namespace-Deklaration darf nicht mit dem Schlüsselwort \"module\" deklariert werden. Verwenden Sie stattdessen das Schlüsselwort \"namespace\".",
|
|
65
66
|
"A_non_dry_build_would_build_project_0_6357": "Bei einem Build ohne das Flag \"-dry\" würde das Projekt \"{0}\" erstellt.",
|
|
66
67
|
"A_non_dry_build_would_delete_the_following_files_Colon_0_6356": "Bei einem Build ohne das Flag \"-dry\" würden die folgenden Dateien gelöscht: {0}",
|
|
67
68
|
"A_non_dry_build_would_update_timestamps_for_output_of_project_0_6374": "Ein Build ohne das Flag \"-dry\" würde die Zeitstempel der Ausgabe von Projekt \"{0}\" aktualisieren.",
|
|
@@ -62,6 +62,7 @@
|
|
|
62
62
|
"A_namespace_declaration_cannot_be_in_a_different_file_from_a_class_or_function_with_which_it_is_merg_2433": "Una declaración de espacio de nombres no puede estar en un archivo distinto de una clase o función con la que se combina.",
|
|
63
63
|
"A_namespace_declaration_cannot_be_located_prior_to_a_class_or_function_with_which_it_is_merged_2434": "Una declaración de espacio de nombres no se puede situar antes que una clase o función con la que se combina.",
|
|
64
64
|
"A_namespace_declaration_is_only_allowed_at_the_top_level_of_a_namespace_or_module_1235": "Una declaración de espacio de nombres solo se permite en el nivel superior de un espacio de nombres o módulo.",
|
|
65
|
+
"A_namespace_declaration_should_not_be_declared_using_the_module_keyword_Please_use_the_namespace_key_1540": "Una declaración \"namespace\" no debe declararse con la palabra clave \"module\". Use la palabra clave \"namespace\" en su lugar.",
|
|
65
66
|
"A_non_dry_build_would_build_project_0_6357": "Una compilación no -dry compilaría el proyecto \"{0}\"",
|
|
66
67
|
"A_non_dry_build_would_delete_the_following_files_Colon_0_6356": "Una compilación no -dry eliminaría los archivos siguientes: {0}",
|
|
67
68
|
"A_non_dry_build_would_update_timestamps_for_output_of_project_0_6374": "Una compilación no -dry actualizaría las marcas de tiempo para la salida del proyecto \"{0}\".",
|
|
@@ -62,6 +62,7 @@
|
|
|
62
62
|
"A_namespace_declaration_cannot_be_in_a_different_file_from_a_class_or_function_with_which_it_is_merg_2433": "Une déclaration d'espace de noms ne peut pas se trouver dans un autre fichier que celui d'une classe ou d'une fonction avec laquelle elle est fusionnée.",
|
|
63
63
|
"A_namespace_declaration_cannot_be_located_prior_to_a_class_or_function_with_which_it_is_merged_2434": "Une déclaration d'espace de noms ne peut pas se trouver avant une classe ou une fonction avec laquelle elle est fusionnée.",
|
|
64
64
|
"A_namespace_declaration_is_only_allowed_at_the_top_level_of_a_namespace_or_module_1235": "Une déclaration d’espace de noms n’est autorisée qu’au niveau supérieur d’un espace de noms ou d’un module.",
|
|
65
|
+
"A_namespace_declaration_should_not_be_declared_using_the_module_keyword_Please_use_the_namespace_key_1540": "Une déclaration d’« espace de noms » ne doit pas être déclarée à l’aide du mot clé « module ». Utilisez plutôt le mot clé « espace de noms ».",
|
|
65
66
|
"A_non_dry_build_would_build_project_0_6357": "Une build non-dry va générer le projet '{0}'",
|
|
66
67
|
"A_non_dry_build_would_delete_the_following_files_Colon_0_6356": "Une build non-dry va supprimer les fichiers suivants : {0}",
|
|
67
68
|
"A_non_dry_build_would_update_timestamps_for_output_of_project_0_6374": "Une build non-dry va mettre à jour les horodatages de la sortie du projet '{0}'",
|
|
@@ -62,6 +62,7 @@
|
|
|
62
62
|
"A_namespace_declaration_cannot_be_in_a_different_file_from_a_class_or_function_with_which_it_is_merg_2433": "Una dichiarazione di spazio dei nomi non può essere presente in un file diverso rispetto a una classe o funzione con cui è stato eseguito il merge.",
|
|
63
63
|
"A_namespace_declaration_cannot_be_located_prior_to_a_class_or_function_with_which_it_is_merged_2434": "Una dichiarazione di spazio dei nomi non può essere specificata prima di una classe o funzione con cui è stato eseguito il merge.",
|
|
64
64
|
"A_namespace_declaration_is_only_allowed_at_the_top_level_of_a_namespace_or_module_1235": "Una dichiarazione di spazio dei nomi è consentita solo al livello superiore di uno spazio dei nomi o di un modulo.",
|
|
65
|
+
"A_namespace_declaration_should_not_be_declared_using_the_module_keyword_Please_use_the_namespace_key_1540": "Una dichiarazione 'namespace' non deve essere dichiarata usando la parola chiave 'module'. Usare invece la parola chiave 'namespace'.",
|
|
65
66
|
"A_non_dry_build_would_build_project_0_6357": "Se si esegue una compilazione senza flag -dry, verrà compilato il progetto '{0}'",
|
|
66
67
|
"A_non_dry_build_would_delete_the_following_files_Colon_0_6356": "Se si esegue una compilazione senza flag -dry, i file seguenti verranno eliminati: {0}",
|
|
67
68
|
"A_non_dry_build_would_update_timestamps_for_output_of_project_0_6374": "Se si esegue una compilazione non di prova, i timestamp dell'output del progetto '{0}' verranno aggiornati",
|
|
@@ -62,6 +62,7 @@
|
|
|
62
62
|
"A_namespace_declaration_cannot_be_in_a_different_file_from_a_class_or_function_with_which_it_is_merg_2433": "名前空間宣言は、それとマージするクラスや関数と異なるファイルに配置できません。",
|
|
63
63
|
"A_namespace_declaration_cannot_be_located_prior_to_a_class_or_function_with_which_it_is_merged_2434": "名前空間宣言は、それとマージするクラスや関数より前に配置できません。",
|
|
64
64
|
"A_namespace_declaration_is_only_allowed_at_the_top_level_of_a_namespace_or_module_1235": "名前空間宣言は、名前空間またはモジュールの最上位レベルでのみ許可されます。",
|
|
65
|
+
"A_namespace_declaration_should_not_be_declared_using_the_module_keyword_Please_use_the_namespace_key_1540": "'namespace' 宣言を 'module' キーワードを使用して宣言することはできません。代わりに 'namespace' キーワードを使用してください。",
|
|
65
66
|
"A_non_dry_build_would_build_project_0_6357": "非 -dry ビルドを実行した場合、プロジェクト '{0}' がビルドされます",
|
|
66
67
|
"A_non_dry_build_would_delete_the_following_files_Colon_0_6356": "非 -dry ビルドを実行した場合、次のファイルが削除されます: {0}",
|
|
67
68
|
"A_non_dry_build_would_update_timestamps_for_output_of_project_0_6374": "non-dry build では、プロジェクト '{0}' の出力のタイムスタンプが更新されます",
|
|
@@ -62,6 +62,7 @@
|
|
|
62
62
|
"A_namespace_declaration_cannot_be_in_a_different_file_from_a_class_or_function_with_which_it_is_merg_2433": "네임스페이스 선언은 해당 선언이 병합된 클래스나 함수와 다른 파일에 있을 수 없습니다,",
|
|
63
63
|
"A_namespace_declaration_cannot_be_located_prior_to_a_class_or_function_with_which_it_is_merged_2434": "네임스페이스 선언은 해당 선언이 병합된 클래스나 함수 앞에 있을 수 없습니다.",
|
|
64
64
|
"A_namespace_declaration_is_only_allowed_at_the_top_level_of_a_namespace_or_module_1235": "네임스페이스 선언은 네임스페이스 또는 모듈의 최상위 수준에서만 허용됩니다.",
|
|
65
|
+
"A_namespace_declaration_should_not_be_declared_using_the_module_keyword_Please_use_the_namespace_key_1540": "'module' 키워드를 사용하여 'namespace' 선언을 선언하면 안 됩니다. 대신 'namespace' 키워드를 사용하세요.",
|
|
65
66
|
"A_non_dry_build_would_build_project_0_6357": "-dry가 아닌 빌드는 프로젝트 '{0}'을(를) 빌드합니다.",
|
|
66
67
|
"A_non_dry_build_would_delete_the_following_files_Colon_0_6356": "-dry가 아닌 빌드는 다음 파일을 삭제합니다. {0}",
|
|
67
68
|
"A_non_dry_build_would_update_timestamps_for_output_of_project_0_6374": "DRY가 아닌 빌드는 '{0}' 프로젝트의 출력 타임스탬프를 업데이트합니다.",
|
|
@@ -62,6 +62,7 @@
|
|
|
62
62
|
"A_namespace_declaration_cannot_be_in_a_different_file_from_a_class_or_function_with_which_it_is_merg_2433": "Uma declaração de namespace não pode estar em um arquivo diferente de uma classe ou função com a qual ela é mesclada.",
|
|
63
63
|
"A_namespace_declaration_cannot_be_located_prior_to_a_class_or_function_with_which_it_is_merged_2434": "Uma declaração de namespace não pode estar localizada antes de uma classe ou função com a qual ela é mesclada.",
|
|
64
64
|
"A_namespace_declaration_is_only_allowed_at_the_top_level_of_a_namespace_or_module_1235": "Uma declaração de namespace só é permitida no nível superior de um namespace ou módulo.",
|
|
65
|
+
"A_namespace_declaration_should_not_be_declared_using_the_module_keyword_Please_use_the_namespace_key_1540": "Uma declaração \"namespace\" não deve ser declarada usando a palavra-chave \"module\". Use a palavra-chave \"namespace\".",
|
|
65
66
|
"A_non_dry_build_would_build_project_0_6357": "Um build não -dry criaria o projeto '{0}'",
|
|
66
67
|
"A_non_dry_build_would_delete_the_following_files_Colon_0_6356": "Um build não -dry excluiria os seguintes arquivos: {0}",
|
|
67
68
|
"A_non_dry_build_would_update_timestamps_for_output_of_project_0_6374": "Um build não -dry atualizaria carimbos de data/hora para a saída do projeto '{0}'",
|
|
@@ -62,6 +62,7 @@
|
|
|
62
62
|
"A_namespace_declaration_cannot_be_in_a_different_file_from_a_class_or_function_with_which_it_is_merg_2433": "Объявление пространства имен и класс или функция, с которыми оно объединено, не могут находится в разных файлах.",
|
|
63
63
|
"A_namespace_declaration_cannot_be_located_prior_to_a_class_or_function_with_which_it_is_merged_2434": "Объявление пространства имен не может располагаться раньше класса или функции, с которыми оно объединено.",
|
|
64
64
|
"A_namespace_declaration_is_only_allowed_at_the_top_level_of_a_namespace_or_module_1235": "Объявление пространства имен разрешено только на верхнем уровне пространства имен или модуля.",
|
|
65
|
+
"A_namespace_declaration_should_not_be_declared_using_the_module_keyword_Please_use_the_namespace_key_1540": "Объявление \"namespace\" с использованием ключевого слова \"module\" недопустимо. Вместо него используйте ключевое слово \"namespace\".",
|
|
65
66
|
"A_non_dry_build_would_build_project_0_6357": "При сборке без флага -dry будет собран проект \"{0}\"",
|
|
66
67
|
"A_non_dry_build_would_delete_the_following_files_Colon_0_6356": "При сборке без флага -dry будут удалены следующие файлы: {0}",
|
|
67
68
|
"A_non_dry_build_would_update_timestamps_for_output_of_project_0_6374": "Сборка без флага -dry обновит метки времени для выходных данных проекта \"{0}\"",
|
|
@@ -62,6 +62,7 @@
|
|
|
62
62
|
"A_namespace_declaration_cannot_be_in_a_different_file_from_a_class_or_function_with_which_it_is_merg_2433": "Bir ad alanı bildirimi, birleştirildiği sınıf veya işlevden farklı bir dosyada olamaz.",
|
|
63
63
|
"A_namespace_declaration_cannot_be_located_prior_to_a_class_or_function_with_which_it_is_merged_2434": "Bir ad alanı bildirimi, birleştirildiği sınıf veya işlevden önce gelemez.",
|
|
64
64
|
"A_namespace_declaration_is_only_allowed_at_the_top_level_of_a_namespace_or_module_1235": "Ad alanı bildirimine yalnızca bir ad alanının veya modülün en üst düzeyinde izin verilir.",
|
|
65
|
+
"A_namespace_declaration_should_not_be_declared_using_the_module_keyword_Please_use_the_namespace_key_1540": "'module' anahtar sözcüğü kullanılarak 'namespace' bildirimi bildirilmez. Lütfen bunun yerine 'namespace' anahtar sözcüğünü kullanın.",
|
|
65
66
|
"A_non_dry_build_would_build_project_0_6357": "-dry bayrağı kullanılmayan bir derleme '{0}' projesini derler",
|
|
66
67
|
"A_non_dry_build_would_delete_the_following_files_Colon_0_6356": "-dry bayrağı kullanılmayan bir derleme şu dosyaları siler: {0}",
|
|
67
68
|
"A_non_dry_build_would_update_timestamps_for_output_of_project_0_6374": "DRY dışı bir derleme, '{0}' projesinin çıkışı için zaman damgalarını güncelleştirir",
|
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 = "5.6";
|
|
21
|
-
var version = `${versionMajorMinor}.0-insiders.
|
|
21
|
+
var version = `${versionMajorMinor}.0-insiders.20240815`;
|
|
22
22
|
|
|
23
23
|
// src/compiler/core.ts
|
|
24
24
|
var emptyArray = [];
|
|
@@ -35840,7 +35840,6 @@ var commonOptionsWithBuild = [
|
|
|
35840
35840
|
name: "generateTrace",
|
|
35841
35841
|
type: "string",
|
|
35842
35842
|
isFilePath: true,
|
|
35843
|
-
isCommandLineOnly: true,
|
|
35844
35843
|
paramType: Diagnostics.DIRECTORY,
|
|
35845
35844
|
category: Diagnostics.Compiler_Diagnostics,
|
|
35846
35845
|
description: Diagnostics.Generates_an_event_trace_and_a_list_of_types
|
|
@@ -44068,21 +44067,25 @@ function createBinder() {
|
|
|
44068
44067
|
const reportError = (
|
|
44069
44068
|
// report error on all statements except empty ones
|
|
44070
44069
|
isStatementButNotDeclaration(node) && node.kind !== 242 /* EmptyStatement */ || // report error on class declarations
|
|
44071
|
-
node.kind === 263 /* ClassDeclaration */ || // report
|
|
44070
|
+
node.kind === 263 /* ClassDeclaration */ || // report errors on enums with preserved emit
|
|
44071
|
+
isEnumDeclarationWithPreservedEmit(node, options) || // report error on instantiated modules
|
|
44072
44072
|
node.kind === 267 /* ModuleDeclaration */ && shouldReportErrorOnModuleDeclaration(node)
|
|
44073
44073
|
);
|
|
44074
44074
|
if (reportError) {
|
|
44075
44075
|
currentFlow = reportedUnreachableFlow;
|
|
44076
44076
|
if (!options.allowUnreachableCode) {
|
|
44077
44077
|
const isError = unreachableCodeIsError(options) && !(node.flags & 33554432 /* Ambient */) && (!isVariableStatement(node) || !!(getCombinedNodeFlags(node.declarationList) & 7 /* BlockScoped */) || node.declarationList.declarations.some((d) => !!d.initializer));
|
|
44078
|
-
eachUnreachableRange(node, (start, end) => errorOrSuggestionOnRange(isError, start, end, Diagnostics.Unreachable_code_detected));
|
|
44078
|
+
eachUnreachableRange(node, options, (start, end) => errorOrSuggestionOnRange(isError, start, end, Diagnostics.Unreachable_code_detected));
|
|
44079
44079
|
}
|
|
44080
44080
|
}
|
|
44081
44081
|
}
|
|
44082
44082
|
return true;
|
|
44083
44083
|
}
|
|
44084
44084
|
}
|
|
44085
|
-
function
|
|
44085
|
+
function isEnumDeclarationWithPreservedEmit(node, options) {
|
|
44086
|
+
return node.kind === 266 /* EnumDeclaration */ && (!isEnumConst(node) || shouldPreserveConstEnums(options));
|
|
44087
|
+
}
|
|
44088
|
+
function eachUnreachableRange(node, options, cb) {
|
|
44086
44089
|
if (isStatement(node) && isExecutableStatement(node) && isBlock(node.parent)) {
|
|
44087
44090
|
const { statements } = node.parent;
|
|
44088
44091
|
const slice = sliceAfter(statements, node);
|
|
@@ -44090,22 +44093,22 @@ function eachUnreachableRange(node, cb) {
|
|
|
44090
44093
|
} else {
|
|
44091
44094
|
cb(node, node);
|
|
44092
44095
|
}
|
|
44093
|
-
|
|
44094
|
-
|
|
44095
|
-
|
|
44096
|
-
|
|
44097
|
-
|
|
44098
|
-
|
|
44099
|
-
|
|
44100
|
-
|
|
44101
|
-
|
|
44102
|
-
|
|
44103
|
-
|
|
44104
|
-
|
|
44105
|
-
|
|
44106
|
-
|
|
44107
|
-
|
|
44108
|
-
|
|
44096
|
+
function isExecutableStatement(s) {
|
|
44097
|
+
return !isFunctionDeclaration(s) && !isPurelyTypeDeclaration(s) && // `var x;` may declare a variable used above
|
|
44098
|
+
!(isVariableStatement(s) && !(getCombinedNodeFlags(s) & 7 /* BlockScoped */) && s.declarationList.declarations.some((d) => !d.initializer));
|
|
44099
|
+
}
|
|
44100
|
+
function isPurelyTypeDeclaration(s) {
|
|
44101
|
+
switch (s.kind) {
|
|
44102
|
+
case 264 /* InterfaceDeclaration */:
|
|
44103
|
+
case 265 /* TypeAliasDeclaration */:
|
|
44104
|
+
return true;
|
|
44105
|
+
case 267 /* ModuleDeclaration */:
|
|
44106
|
+
return getModuleInstanceState(s) !== 1 /* Instantiated */;
|
|
44107
|
+
case 266 /* EnumDeclaration */:
|
|
44108
|
+
return !isEnumDeclarationWithPreservedEmit(s, options);
|
|
44109
|
+
default:
|
|
44110
|
+
return false;
|
|
44111
|
+
}
|
|
44109
44112
|
}
|
|
44110
44113
|
}
|
|
44111
44114
|
function isExportsOrModuleExportsOrAlias(sourceFile, node) {
|
|
@@ -60240,7 +60243,7 @@ function createTypeChecker(host) {
|
|
|
60240
60243
|
} else if (every(typeSet, (t) => !!(t.flags & 1048576 /* Union */ && (t.types[0].flags & 65536 /* Null */ || t.types[1].flags & 65536 /* Null */)))) {
|
|
60241
60244
|
removeFromEach(typeSet, 65536 /* Null */);
|
|
60242
60245
|
result = getUnionType([getIntersectionType(typeSet, flags), nullType], 1 /* Literal */, aliasSymbol, aliasTypeArguments);
|
|
60243
|
-
} else if (typeSet.length >=
|
|
60246
|
+
} else if (typeSet.length >= 3 && types.length > 2) {
|
|
60244
60247
|
const middle = Math.floor(typeSet.length / 2);
|
|
60245
60248
|
result = getIntersectionType([getIntersectionType(typeSet.slice(0, middle), flags), getIntersectionType(typeSet.slice(middle), flags)], flags, aliasSymbol, aliasTypeArguments);
|
|
60246
60249
|
} else {
|
|
@@ -76909,11 +76912,6 @@ function createTypeChecker(host) {
|
|
|
76909
76912
|
/*errorNode*/
|
|
76910
76913
|
void 0
|
|
76911
76914
|
) || unknownType;
|
|
76912
|
-
nextType = resolver.resolveIterationType(
|
|
76913
|
-
nextType,
|
|
76914
|
-
/*errorNode*/
|
|
76915
|
-
void 0
|
|
76916
|
-
) || unknownType;
|
|
76917
76915
|
if (globalGeneratorType === emptyGenericType) {
|
|
76918
76916
|
const globalIterableIteratorType = resolver.getGlobalIterableIteratorType(
|
|
76919
76917
|
/*reportErrors*/
|
|
@@ -78518,9 +78516,8 @@ function createTypeChecker(host) {
|
|
|
78518
78516
|
const iterationTypes = returnType && getIterationTypesOfGeneratorFunctionReturnType(returnType, isAsync);
|
|
78519
78517
|
const signatureYieldType = iterationTypes && iterationTypes.yieldType || anyType;
|
|
78520
78518
|
const signatureNextType = iterationTypes && iterationTypes.nextType || anyType;
|
|
78521
|
-
const resolvedSignatureNextType = isAsync ? getAwaitedType(signatureNextType) || anyType : signatureNextType;
|
|
78522
78519
|
const yieldExpressionType = node.expression ? checkExpression(node.expression) : undefinedWideningType;
|
|
78523
|
-
const yieldedType = getYieldedTypeOfYieldExpression(node, yieldExpressionType,
|
|
78520
|
+
const yieldedType = getYieldedTypeOfYieldExpression(node, yieldExpressionType, signatureNextType, isAsync);
|
|
78524
78521
|
if (returnType && yieldedType) {
|
|
78525
78522
|
checkTypeAssignableToAndOptionallyElaborate(yieldedType, signatureYieldType, node.expression || node, node.expression);
|
|
78526
78523
|
}
|
package/lib/typescript.js
CHANGED
|
@@ -2262,7 +2262,7 @@ module.exports = __toCommonJS(typescript_exports);
|
|
|
2262
2262
|
|
|
2263
2263
|
// src/compiler/corePublic.ts
|
|
2264
2264
|
var versionMajorMinor = "5.6";
|
|
2265
|
-
var version = `${versionMajorMinor}.0-insiders.
|
|
2265
|
+
var version = `${versionMajorMinor}.0-insiders.20240815`;
|
|
2266
2266
|
var Comparison = /* @__PURE__ */ ((Comparison3) => {
|
|
2267
2267
|
Comparison3[Comparison3["LessThan"] = -1] = "LessThan";
|
|
2268
2268
|
Comparison3[Comparison3["EqualTo"] = 0] = "EqualTo";
|
|
@@ -40110,7 +40110,6 @@ var commonOptionsWithBuild = [
|
|
|
40110
40110
|
name: "generateTrace",
|
|
40111
40111
|
type: "string",
|
|
40112
40112
|
isFilePath: true,
|
|
40113
|
-
isCommandLineOnly: true,
|
|
40114
40113
|
paramType: Diagnostics.DIRECTORY,
|
|
40115
40114
|
category: Diagnostics.Compiler_Diagnostics,
|
|
40116
40115
|
description: Diagnostics.Generates_an_event_trace_and_a_list_of_types
|
|
@@ -48587,21 +48586,25 @@ function createBinder() {
|
|
|
48587
48586
|
const reportError = (
|
|
48588
48587
|
// report error on all statements except empty ones
|
|
48589
48588
|
isStatementButNotDeclaration(node) && node.kind !== 242 /* EmptyStatement */ || // report error on class declarations
|
|
48590
|
-
node.kind === 263 /* ClassDeclaration */ || // report
|
|
48589
|
+
node.kind === 263 /* ClassDeclaration */ || // report errors on enums with preserved emit
|
|
48590
|
+
isEnumDeclarationWithPreservedEmit(node, options) || // report error on instantiated modules
|
|
48591
48591
|
node.kind === 267 /* ModuleDeclaration */ && shouldReportErrorOnModuleDeclaration(node)
|
|
48592
48592
|
);
|
|
48593
48593
|
if (reportError) {
|
|
48594
48594
|
currentFlow = reportedUnreachableFlow;
|
|
48595
48595
|
if (!options.allowUnreachableCode) {
|
|
48596
48596
|
const isError = unreachableCodeIsError(options) && !(node.flags & 33554432 /* Ambient */) && (!isVariableStatement(node) || !!(getCombinedNodeFlags(node.declarationList) & 7 /* BlockScoped */) || node.declarationList.declarations.some((d) => !!d.initializer));
|
|
48597
|
-
eachUnreachableRange(node, (start, end) => errorOrSuggestionOnRange(isError, start, end, Diagnostics.Unreachable_code_detected));
|
|
48597
|
+
eachUnreachableRange(node, options, (start, end) => errorOrSuggestionOnRange(isError, start, end, Diagnostics.Unreachable_code_detected));
|
|
48598
48598
|
}
|
|
48599
48599
|
}
|
|
48600
48600
|
}
|
|
48601
48601
|
return true;
|
|
48602
48602
|
}
|
|
48603
48603
|
}
|
|
48604
|
-
function
|
|
48604
|
+
function isEnumDeclarationWithPreservedEmit(node, options) {
|
|
48605
|
+
return node.kind === 266 /* EnumDeclaration */ && (!isEnumConst(node) || shouldPreserveConstEnums(options));
|
|
48606
|
+
}
|
|
48607
|
+
function eachUnreachableRange(node, options, cb) {
|
|
48605
48608
|
if (isStatement(node) && isExecutableStatement(node) && isBlock(node.parent)) {
|
|
48606
48609
|
const { statements } = node.parent;
|
|
48607
48610
|
const slice = sliceAfter(statements, node);
|
|
@@ -48609,22 +48612,22 @@ function eachUnreachableRange(node, cb) {
|
|
|
48609
48612
|
} else {
|
|
48610
48613
|
cb(node, node);
|
|
48611
48614
|
}
|
|
48612
|
-
|
|
48613
|
-
|
|
48614
|
-
|
|
48615
|
-
|
|
48616
|
-
|
|
48617
|
-
|
|
48618
|
-
|
|
48619
|
-
|
|
48620
|
-
|
|
48621
|
-
|
|
48622
|
-
|
|
48623
|
-
|
|
48624
|
-
|
|
48625
|
-
|
|
48626
|
-
|
|
48627
|
-
|
|
48615
|
+
function isExecutableStatement(s) {
|
|
48616
|
+
return !isFunctionDeclaration(s) && !isPurelyTypeDeclaration(s) && // `var x;` may declare a variable used above
|
|
48617
|
+
!(isVariableStatement(s) && !(getCombinedNodeFlags(s) & 7 /* BlockScoped */) && s.declarationList.declarations.some((d) => !d.initializer));
|
|
48618
|
+
}
|
|
48619
|
+
function isPurelyTypeDeclaration(s) {
|
|
48620
|
+
switch (s.kind) {
|
|
48621
|
+
case 264 /* InterfaceDeclaration */:
|
|
48622
|
+
case 265 /* TypeAliasDeclaration */:
|
|
48623
|
+
return true;
|
|
48624
|
+
case 267 /* ModuleDeclaration */:
|
|
48625
|
+
return getModuleInstanceState(s) !== 1 /* Instantiated */;
|
|
48626
|
+
case 266 /* EnumDeclaration */:
|
|
48627
|
+
return !isEnumDeclarationWithPreservedEmit(s, options);
|
|
48628
|
+
default:
|
|
48629
|
+
return false;
|
|
48630
|
+
}
|
|
48628
48631
|
}
|
|
48629
48632
|
}
|
|
48630
48633
|
function isExportsOrModuleExportsOrAlias(sourceFile, node) {
|
|
@@ -64859,7 +64862,7 @@ function createTypeChecker(host) {
|
|
|
64859
64862
|
} else if (every(typeSet, (t) => !!(t.flags & 1048576 /* Union */ && (t.types[0].flags & 65536 /* Null */ || t.types[1].flags & 65536 /* Null */)))) {
|
|
64860
64863
|
removeFromEach(typeSet, 65536 /* Null */);
|
|
64861
64864
|
result = getUnionType([getIntersectionType(typeSet, flags), nullType], 1 /* Literal */, aliasSymbol, aliasTypeArguments);
|
|
64862
|
-
} else if (typeSet.length >=
|
|
64865
|
+
} else if (typeSet.length >= 3 && types.length > 2) {
|
|
64863
64866
|
const middle = Math.floor(typeSet.length / 2);
|
|
64864
64867
|
result = getIntersectionType([getIntersectionType(typeSet.slice(0, middle), flags), getIntersectionType(typeSet.slice(middle), flags)], flags, aliasSymbol, aliasTypeArguments);
|
|
64865
64868
|
} else {
|
|
@@ -81528,11 +81531,6 @@ function createTypeChecker(host) {
|
|
|
81528
81531
|
/*errorNode*/
|
|
81529
81532
|
void 0
|
|
81530
81533
|
) || unknownType;
|
|
81531
|
-
nextType = resolver.resolveIterationType(
|
|
81532
|
-
nextType,
|
|
81533
|
-
/*errorNode*/
|
|
81534
|
-
void 0
|
|
81535
|
-
) || unknownType;
|
|
81536
81534
|
if (globalGeneratorType === emptyGenericType) {
|
|
81537
81535
|
const globalIterableIteratorType = resolver.getGlobalIterableIteratorType(
|
|
81538
81536
|
/*reportErrors*/
|
|
@@ -83137,9 +83135,8 @@ function createTypeChecker(host) {
|
|
|
83137
83135
|
const iterationTypes = returnType && getIterationTypesOfGeneratorFunctionReturnType(returnType, isAsync);
|
|
83138
83136
|
const signatureYieldType = iterationTypes && iterationTypes.yieldType || anyType;
|
|
83139
83137
|
const signatureNextType = iterationTypes && iterationTypes.nextType || anyType;
|
|
83140
|
-
const resolvedSignatureNextType = isAsync ? getAwaitedType(signatureNextType) || anyType : signatureNextType;
|
|
83141
83138
|
const yieldExpressionType = node.expression ? checkExpression(node.expression) : undefinedWideningType;
|
|
83142
|
-
const yieldedType = getYieldedTypeOfYieldExpression(node, yieldExpressionType,
|
|
83139
|
+
const yieldedType = getYieldedTypeOfYieldExpression(node, yieldExpressionType, signatureNextType, isAsync);
|
|
83143
83140
|
if (returnType && yieldedType) {
|
|
83144
83141
|
checkTypeAssignableToAndOptionallyElaborate(yieldedType, signatureYieldType, node.expression || node, node.expression);
|
|
83145
83142
|
}
|
|
@@ -145113,7 +145110,12 @@ registerRefactor(refactorName4, {
|
|
|
145113
145110
|
const { references, declaration, replacement } = info;
|
|
145114
145111
|
const edits = ts_textChanges_exports.ChangeTracker.with(context, (tracker) => {
|
|
145115
145112
|
for (const node of references) {
|
|
145116
|
-
|
|
145113
|
+
const closestStringIdentifierParent = isStringLiteral(replacement) && isIdentifier(node) && walkUpParenthesizedExpressions(node.parent);
|
|
145114
|
+
if (closestStringIdentifierParent && isTemplateSpan(closestStringIdentifierParent) && !isTaggedTemplateExpression(closestStringIdentifierParent.parent.parent)) {
|
|
145115
|
+
replaceTemplateStringVariableWithLiteral(tracker, file, closestStringIdentifierParent, replacement);
|
|
145116
|
+
} else {
|
|
145117
|
+
tracker.replaceNode(file, node, getReplacementExpression(node, replacement));
|
|
145118
|
+
}
|
|
145117
145119
|
}
|
|
145118
145120
|
tracker.delete(file, declaration);
|
|
145119
145121
|
});
|
|
@@ -145202,6 +145204,19 @@ function getReplacementExpression(reference, replacement) {
|
|
|
145202
145204
|
}
|
|
145203
145205
|
return replacement;
|
|
145204
145206
|
}
|
|
145207
|
+
function replaceTemplateStringVariableWithLiteral(tracker, sourceFile, reference, replacement) {
|
|
145208
|
+
const templateExpression = reference.parent;
|
|
145209
|
+
const index = templateExpression.templateSpans.indexOf(reference);
|
|
145210
|
+
const prevNode = index === 0 ? templateExpression.head : templateExpression.templateSpans[index - 1];
|
|
145211
|
+
tracker.replaceRangeWithText(
|
|
145212
|
+
sourceFile,
|
|
145213
|
+
{
|
|
145214
|
+
pos: prevNode.getEnd() - 2,
|
|
145215
|
+
end: reference.literal.getStart() + 1
|
|
145216
|
+
},
|
|
145217
|
+
replacement.text.replace(/\\/g, "\\\\").replace(/`/g, "\\`")
|
|
145218
|
+
);
|
|
145219
|
+
}
|
|
145205
145220
|
|
|
145206
145221
|
// src/services/refactors/moveToNewFile.ts
|
|
145207
145222
|
var refactorName5 = "Move to a new file";
|
|
@@ -185663,23 +185678,8 @@ var nullTypingsInstaller = {
|
|
|
185663
185678
|
};
|
|
185664
185679
|
var noopConfigFileWatcher = { close: noop };
|
|
185665
185680
|
function getConfigFileNameFromCache(info, cache) {
|
|
185666
|
-
if (!cache) return void 0;
|
|
185667
|
-
|
|
185668
|
-
if (configFileForOpenFile === void 0) return void 0;
|
|
185669
|
-
if (!isAncestorConfigFileInfo(info)) {
|
|
185670
|
-
return isString(configFileForOpenFile) || !configFileForOpenFile ? configFileForOpenFile : (
|
|
185671
|
-
// direct result
|
|
185672
|
-
configFileForOpenFile.get(
|
|
185673
|
-
/*key*/
|
|
185674
|
-
false
|
|
185675
|
-
)
|
|
185676
|
-
);
|
|
185677
|
-
} else {
|
|
185678
|
-
return configFileForOpenFile && !isString(configFileForOpenFile) ? (
|
|
185679
|
-
// Map with fileName as key
|
|
185680
|
-
configFileForOpenFile.get(info.fileName)
|
|
185681
|
-
) : void 0;
|
|
185682
|
-
}
|
|
185681
|
+
if (!cache || isAncestorConfigFileInfo(info)) return void 0;
|
|
185682
|
+
return cache.get(info.path);
|
|
185683
185683
|
}
|
|
185684
185684
|
function isOpenScriptInfo(infoOrFileNameOrConfig) {
|
|
185685
185685
|
return !!infoOrFileNameOrConfig.containingProjects;
|
|
@@ -185693,17 +185693,13 @@ var ConfiguredProjectLoadKind = /* @__PURE__ */ ((ConfiguredProjectLoadKind2) =>
|
|
|
185693
185693
|
ConfiguredProjectLoadKind2[ConfiguredProjectLoadKind2["Reload"] = 2] = "Reload";
|
|
185694
185694
|
return ConfiguredProjectLoadKind2;
|
|
185695
185695
|
})(ConfiguredProjectLoadKind || {});
|
|
185696
|
-
function forEachAncestorProject(info, project, cb, kind, reason, allowDeferredClosed, reloadedProjects,
|
|
185696
|
+
function forEachAncestorProject(info, project, cb, kind, reason, allowDeferredClosed, reloadedProjects, delayReloadedConfiguredProjects) {
|
|
185697
185697
|
while (true) {
|
|
185698
|
-
if (!project.isInitialLoadPending() && (
|
|
185699
|
-
// - loading solution for find all references
|
|
185700
|
-
// - trying to find default project
|
|
185701
|
-
project.getCompilerOptions().disableSolutionSearching)) return;
|
|
185698
|
+
if (!project.isInitialLoadPending() && (!project.getCompilerOptions().composite || project.getCompilerOptions().disableSolutionSearching)) return;
|
|
185702
185699
|
const configFileName = project.projectService.getConfigFileNameForFile({
|
|
185703
185700
|
fileName: project.getConfigFilePath(),
|
|
185704
185701
|
path: info.path,
|
|
185705
|
-
configFileInfo: true
|
|
185706
|
-
isForDefaultProject: !searchOnlyPotentialSolution
|
|
185702
|
+
configFileInfo: true
|
|
185707
185703
|
}, kind === 0 /* Find */);
|
|
185708
185704
|
if (!configFileName) return;
|
|
185709
185705
|
const ancestor = project.projectService.findCreateOrReloadConfiguredProject(
|
|
@@ -185711,11 +185707,11 @@ function forEachAncestorProject(info, project, cb, kind, reason, allowDeferredCl
|
|
|
185711
185707
|
kind,
|
|
185712
185708
|
reason,
|
|
185713
185709
|
allowDeferredClosed,
|
|
185714
|
-
|
|
185715
|
-
|
|
185710
|
+
/*triggerFile*/
|
|
185711
|
+
void 0,
|
|
185716
185712
|
reloadedProjects,
|
|
185717
|
-
|
|
185718
|
-
|
|
185713
|
+
/*delayLoad*/
|
|
185714
|
+
true,
|
|
185719
185715
|
delayReloadedConfiguredProjects
|
|
185720
185716
|
);
|
|
185721
185717
|
if (!ancestor) return;
|
|
@@ -186826,7 +186822,7 @@ var _ProjectService = class _ProjectService {
|
|
|
186826
186822
|
configFileExists(configFileName, canonicalConfigFilePath, info) {
|
|
186827
186823
|
const configFileExistenceInfo = this.configFileExistenceInfoCache.get(canonicalConfigFilePath);
|
|
186828
186824
|
let openFilesImpactedByConfigFile;
|
|
186829
|
-
if (this.openFiles.has(info.path) &&
|
|
186825
|
+
if (this.openFiles.has(info.path) && !isAncestorConfigFileInfo(info)) {
|
|
186830
186826
|
if (configFileExistenceInfo) (configFileExistenceInfo.openFilesImpactedByConfigFile ?? (configFileExistenceInfo.openFilesImpactedByConfigFile = /* @__PURE__ */ new Set())).add(info.path);
|
|
186831
186827
|
else (openFilesImpactedByConfigFile = /* @__PURE__ */ new Set()).add(info.path);
|
|
186832
186828
|
}
|
|
@@ -186953,31 +186949,24 @@ var _ProjectService = class _ProjectService {
|
|
|
186953
186949
|
let searchPath = asNormalizedPath(getDirectoryPath(info.fileName));
|
|
186954
186950
|
const isSearchPathInProjectRoot = () => containsPath(projectRootPath, searchPath, this.currentDirectory, !this.host.useCaseSensitiveFileNames);
|
|
186955
186951
|
const anySearchPathOk = !projectRootPath || !isSearchPathInProjectRoot();
|
|
186956
|
-
let
|
|
186957
|
-
let searchJsconfig = true;
|
|
186958
|
-
if (isAncestorConfigFileInfo(info)) {
|
|
186959
|
-
if (endsWith(info.fileName, "tsconfig.json")) searchTsconfig = false;
|
|
186960
|
-
else searchTsconfig = searchJsconfig = false;
|
|
186961
|
-
}
|
|
186952
|
+
let searchInDirectory = !isAncestorConfigFileInfo(info);
|
|
186962
186953
|
do {
|
|
186963
|
-
|
|
186964
|
-
|
|
186954
|
+
if (searchInDirectory) {
|
|
186955
|
+
const canonicalSearchPath = normalizedPathToPath(searchPath, this.currentDirectory, this.toCanonicalFileName);
|
|
186965
186956
|
const tsconfigFileName = asNormalizedPath(combinePaths(searchPath, "tsconfig.json"));
|
|
186966
|
-
|
|
186957
|
+
let result = action(combinePaths(canonicalSearchPath, "tsconfig.json"), tsconfigFileName);
|
|
186967
186958
|
if (result) return tsconfigFileName;
|
|
186968
|
-
}
|
|
186969
|
-
if (searchJsconfig) {
|
|
186970
186959
|
const jsconfigFileName = asNormalizedPath(combinePaths(searchPath, "jsconfig.json"));
|
|
186971
|
-
|
|
186960
|
+
result = action(combinePaths(canonicalSearchPath, "jsconfig.json"), jsconfigFileName);
|
|
186972
186961
|
if (result) return jsconfigFileName;
|
|
186973
|
-
|
|
186974
|
-
|
|
186975
|
-
|
|
186962
|
+
if (isNodeModulesDirectory(canonicalSearchPath)) {
|
|
186963
|
+
break;
|
|
186964
|
+
}
|
|
186976
186965
|
}
|
|
186977
186966
|
const parentPath = asNormalizedPath(getDirectoryPath(searchPath));
|
|
186978
186967
|
if (parentPath === searchPath) break;
|
|
186979
186968
|
searchPath = parentPath;
|
|
186980
|
-
|
|
186969
|
+
searchInDirectory = true;
|
|
186981
186970
|
} while (anySearchPathOk || isSearchPathInProjectRoot());
|
|
186982
186971
|
return void 0;
|
|
186983
186972
|
}
|
|
@@ -187000,19 +186989,8 @@ var _ProjectService = class _ProjectService {
|
|
|
187000
186989
|
/** Caches the configFilename for script info or ancestor of open script info */
|
|
187001
186990
|
setConfigFileNameForFileInCache(info, configFileName) {
|
|
187002
186991
|
if (!this.openFiles.has(info.path)) return;
|
|
187003
|
-
|
|
187004
|
-
|
|
187005
|
-
this.configFileForOpenFiles.set(info.path, config);
|
|
187006
|
-
} else {
|
|
187007
|
-
let configFileForOpenFile = this.configFileForOpenFiles.get(info.path);
|
|
187008
|
-
if (!configFileForOpenFile || isString(configFileForOpenFile)) {
|
|
187009
|
-
this.configFileForOpenFiles.set(
|
|
187010
|
-
info.path,
|
|
187011
|
-
configFileForOpenFile = (/* @__PURE__ */ new Map()).set(false, configFileForOpenFile)
|
|
187012
|
-
);
|
|
187013
|
-
}
|
|
187014
|
-
configFileForOpenFile.set(info.fileName, config);
|
|
187015
|
-
}
|
|
186992
|
+
if (isAncestorConfigFileInfo(info)) return;
|
|
186993
|
+
this.configFileForOpenFiles.set(info.path, configFileName || false);
|
|
187016
186994
|
}
|
|
187017
186995
|
/**
|
|
187018
186996
|
* This function tries to search for a tsconfig.json for the given file.
|
|
@@ -188398,7 +188376,7 @@ Dynamic files must always be opened with service's current directory or service
|
|
|
188398
188376
|
seenProjects
|
|
188399
188377
|
};
|
|
188400
188378
|
function tryFindDefaultConfiguredProject(project) {
|
|
188401
|
-
return isDefaultProject(project) ? defaultProject : tryFindDefaultConfiguredProjectFromReferences(project)
|
|
188379
|
+
return isDefaultProject(project) ? defaultProject : tryFindDefaultConfiguredProjectFromReferences(project);
|
|
188402
188380
|
}
|
|
188403
188381
|
function isDefaultProject(project) {
|
|
188404
188382
|
if (!tryAddToSet(seenProjects, project)) return;
|
|
@@ -188421,20 +188399,6 @@ Dynamic files must always be opened with service's current directory or service
|
|
|
188421
188399
|
reloadedProjects
|
|
188422
188400
|
);
|
|
188423
188401
|
}
|
|
188424
|
-
function tryFindDefaultConfiguredProjectFromAncestor(project) {
|
|
188425
|
-
return forEachAncestorProject(
|
|
188426
|
-
// If not in referenced projects, try ancestors and its references
|
|
188427
|
-
info,
|
|
188428
|
-
project,
|
|
188429
|
-
tryFindDefaultConfiguredProject,
|
|
188430
|
-
kind,
|
|
188431
|
-
`Creating possible configured project for ${info.fileName} to open`,
|
|
188432
|
-
allowDeferredClosed,
|
|
188433
|
-
reloadedProjects,
|
|
188434
|
-
/*searchOnlyPotentialSolution*/
|
|
188435
|
-
false
|
|
188436
|
-
);
|
|
188437
|
-
}
|
|
188438
188402
|
}
|
|
188439
188403
|
tryFindDefaultConfiguredProjectAndLoadAncestorsForOpenScriptInfo(info, kind, reloadedProjects, delayReloadedConfiguredProjects) {
|
|
188440
188404
|
const allowDeferredClosed = kind === 0 /* Find */;
|
|
@@ -188457,8 +188421,6 @@ Dynamic files must always be opened with service's current directory or service
|
|
|
188457
188421
|
`Creating project possibly referencing default composite project ${defaultProject.getProjectName()} of open file ${info.fileName}`,
|
|
188458
188422
|
allowDeferredClosed,
|
|
188459
188423
|
reloadedProjects,
|
|
188460
|
-
/*searchOnlyPotentialSolution*/
|
|
188461
|
-
true,
|
|
188462
188424
|
delayReloadedConfiguredProjects
|
|
188463
188425
|
);
|
|
188464
188426
|
}
|
|
@@ -62,6 +62,7 @@
|
|
|
62
62
|
"A_namespace_declaration_cannot_be_in_a_different_file_from_a_class_or_function_with_which_it_is_merg_2433": "命名空間宣告的所在檔案位置,不得與其要合併的類別或函式不同。",
|
|
63
63
|
"A_namespace_declaration_cannot_be_located_prior_to_a_class_or_function_with_which_it_is_merged_2434": "命名空間宣告的位置不得先於其要合併的類別或函式。",
|
|
64
64
|
"A_namespace_declaration_is_only_allowed_at_the_top_level_of_a_namespace_or_module_1235": "命名空間宣告只允許在命名空間或模組的頂層。",
|
|
65
|
+
"A_namespace_declaration_should_not_be_declared_using_the_module_keyword_Please_use_the_namespace_key_1540": "不應該使用 'module' 關鍵字宣告 'namespace' 宣告。請改為使用 'namespace' 關鍵字。",
|
|
65
66
|
"A_non_dry_build_would_build_project_0_6357": "非 -dry 組建會建置專案 '{0}'",
|
|
66
67
|
"A_non_dry_build_would_delete_the_following_files_Colon_0_6356": "非 -dry 組建會刪除下列檔案: {0}",
|
|
67
68
|
"A_non_dry_build_would_update_timestamps_for_output_of_project_0_6374": "非 DRY 組建將會更新專案 '{0}' 輸出的時間戳記",
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "@typescript-deploys/pr-build",
|
|
3
3
|
"author": "Microsoft Corp.",
|
|
4
4
|
"homepage": "https://www.typescriptlang.org/",
|
|
5
|
-
"version": "5.6.0-pr-
|
|
5
|
+
"version": "5.6.0-pr-59644-8",
|
|
6
6
|
"license": "Apache-2.0",
|
|
7
7
|
"description": "TypeScript is a language for application scale JavaScript development",
|
|
8
8
|
"keywords": [
|