Remove unnecessary ClangLibdirSuffix variable.

Twine + const char * is supported.

llvm-svn: 244110
This commit is contained in:
Yaron Keren 2015-08-05 20:06:56 +00:00
parent 4280a96468
commit a910741cea
1 changed files with 4 additions and 6 deletions

View File

@ -1085,13 +1085,11 @@ std::string CompilerInvocation::GetResourcesPath(const char *Argv0,
// Compute the path to the resource directory.
StringRef ClangResourceDir(CLANG_RESOURCE_DIR);
SmallString<128> P(Dir);
if (ClangResourceDir != "") {
if (ClangResourceDir != "")
llvm::sys::path::append(P, ClangResourceDir);
} else {
StringRef ClangLibdirSuffix(CLANG_LIBDIR_SUFFIX);
llvm::sys::path::append(P, "..", Twine("lib") + ClangLibdirSuffix, "clang",
CLANG_VERSION_STRING);
}
else
llvm::sys::path::append(P, "..", Twine("lib") + CLANG_LIBDIR_SUFFIX,
"clang", CLANG_VERSION_STRING);
return P.str();
}