mirror of
https://github.com/microsoft/TypeScript.git
synced 2025-11-18 17:21:48 +00:00
Move assertion to realpath evaluation
This commit is contained in:
@@ -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);
|
||||
});
|
||||
}
|
||||
|
||||
@@ -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;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user