ABataev added inline comments.
================
Comment at: lib/Driver/ToolChains/Cuda.cpp:535
+ SmallVector<std::string, 8> LibraryPaths;
+ if (char *env = ::getenv("LIBRARY_PATH")) {
+ StringRef CompilerPath = env;
----------------
1. `char *`->`const char *`
2. `::getenv`->`llvm::Process::GetEnv`
================
Comment at: lib/Driver/ToolChains/Cuda.cpp:539
+ std::pair<StringRef, StringRef> Split =
+ CompilerPath.split(llvm::sys::EnvPathSeparator);
+ LibraryPaths.push_back(Split.first);
----------------
Use `llvm::SplitString` instead
================
Comment at: lib/Driver/ToolChains/Cuda.cpp:548
+ bool FoundBCLibrary = false;
+ for (std::string LibraryPath : LibraryPaths) {
+ SmallString<128> LibOmpTargetFile(LibraryPath);
----------------
`const std::string &`
Repository:
rC Clang
https://reviews.llvm.org/D43197
_______________________________________________
cfe-commits mailing list
[email protected]
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits