[PATCH] D57769: [PDB] Remove dots and canonicalize slashes when using /PDBSOURCEPATH
Nico Weber via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Feb 5 13:02:05 PST 2019
thakis accepted this revision.
thakis added a comment.
This revision is now accepted and ready to land.
lgtm either way, but below seems simpler to me.
(Also, isn't it GuessedStyle instead of guessed_style in llvm style?
================
Comment at: lld/COFF/PDB.cpp:300
+ // it starts with a forward slash.
SmallString<128> AbsoluteFileName = Config->PDBSourcePath;
sys::path::append(AbsoluteFileName, FileName);
----------------
It's already in a SmallString here though. Wouldn't it just be
```
sys::path::append(AbsolutFileName, guessed_style, FileName);
sys::path::native(AbsoluteFileName, guessed_style);
sys::path::remove_dots(AbsoluteFileName, /*remove_dot_dots=*/true,
guessed_style);
```
?
(and put the sys::path::native(FileName) call above into the PDBSourcePath.empyt() if)
Repository:
rLLD LLVM Linker
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D57769/new/
https://reviews.llvm.org/D57769
More information about the llvm-commits
mailing list