Move assertion to realpath evaluation

This commit is contained in:
uniqueiniquity
2018-01-19 16:23:24 -08:00
parent 1fc6675a29
commit 46fa477c15
2 changed files with 1 additions and 1 deletions
-1
View File
@@ -25004,7 +25004,6 @@ namespace ts {
return;
}
const file = host.getSourceFile(resolvedDirective.resolvedFileName);
Debug.assert(!!file, `Resolved filename ${resolvedDirective.resolvedFileName} did not map to existing source file. Consider enabling --preserveSymlinks if appropriate`); // tslint:disable-line
fileToDirective.set(file.path, key);
});
}
+1
View File
@@ -782,6 +782,7 @@ namespace ts {
if (traceEnabled) {
trace(host, Diagnostics.Resolving_real_path_for_0_result_1, path, real);
}
Debug.assert(host.fileExists(real), `${path} linked to non-existing file ${real}`); // tslint:disable-line
return real;
}