Make sure FileSystem::Resolve preserves the path/file distinction.

This should finally fix TestPaths.py.

llvm-svn: 356057
This commit is contained in:
Adrian Prantl 2019-03-13 15:54:18 +00:00
parent 506552351c
commit 81d03f3a8f
1 changed files with 4 additions and 1 deletions

View File

@ -264,6 +264,9 @@ void FileSystem::Resolve(FileSpec &file_spec) {
Resolve(path);
// Update the FileSpec with the resolved path.
if (file_spec.GetFilename().IsEmpty())
file_spec.GetDirectory().SetString(path);
else
file_spec.SetPath(path);
file_spec.SetIsResolved(true);
}