Driver: Simplify a use of the path API

It's a bit more obvious what's going on if we use path::filename
rather than decrementing an iterator here.

llvm-svn: 214668
This commit is contained in:
Justin Bogner 2014-08-03 21:46:33 +00:00
parent 921c01b5e5
commit 6bcf724f52
1 changed files with 1 additions and 1 deletions

View File

@ -37,7 +37,7 @@ static void normalizePathSegment(std::string &Segment) {
// Prune trailing "/" or "./"
while (1) {
StringRef last = *--path::end(seg);
StringRef last = path::filename(seg);
if (last != ".")
break;
seg = path::parent_path(seg);