[clang-tools-extra] r351319 - Fix build breakage from llvm r351317
Pavel Labath via cfe-commits
cfe-commits at lists.llvm.org
Wed Jan 16 02:26:53 PST 2019
Author: labath
Date: Wed Jan 16 02:26:52 2019
New Revision: 351319
URL: http://llvm.org/viewvc/llvm-project?rev=351319&view=rev
Log:
Fix build breakage from llvm r351317
The two-argument version of llvm::sys::fs::make_absolute no longer
returns an error code.
Modified:
clang-tools-extra/trunk/clang-move/ClangMove.cpp
clang-tools-extra/trunk/clangd/tool/ClangdMain.cpp
Modified: clang-tools-extra/trunk/clang-move/ClangMove.cpp
URL: http://llvm.org/viewvc/llvm-project/clang-tools-extra/trunk/clang-move/ClangMove.cpp?rev=351319&r1=351318&r2=351319&view=diff
==============================================================================
--- clang-tools-extra/trunk/clang-move/ClangMove.cpp (original)
+++ clang-tools-extra/trunk/clang-move/ClangMove.cpp Wed Jan 16 02:26:52 2019
@@ -76,10 +76,7 @@ std::string MakeAbsolutePath(StringRef C
return "";
llvm::SmallString<128> InitialDirectory(CurrentDir);
llvm::SmallString<128> AbsolutePath(Path);
- if (std::error_code EC =
- llvm::sys::fs::make_absolute(InitialDirectory, AbsolutePath))
- llvm::errs() << "Warning: could not make absolute file: '" << EC.message()
- << '\n';
+ llvm::sys::fs::make_absolute(InitialDirectory, AbsolutePath);
return CleanPath(std::move(AbsolutePath));
}
Modified: clang-tools-extra/trunk/clangd/tool/ClangdMain.cpp
URL: http://llvm.org/viewvc/llvm-project/clang-tools-extra/trunk/clangd/tool/ClangdMain.cpp?rev=351319&r1=351318&r2=351319&view=diff
==============================================================================
--- clang-tools-extra/trunk/clangd/tool/ClangdMain.cpp (original)
+++ clang-tools-extra/trunk/clangd/tool/ClangdMain.cpp Wed Jan 16 02:26:52 2019
@@ -223,9 +223,7 @@ public:
Body = Body.ltrim('/');
llvm::SmallVector<char, 16> Path(Body.begin(), Body.end());
path::native(Path);
- auto Err = fs::make_absolute(TestScheme::TestDir, Path);
- if (Err)
- llvm_unreachable("Failed to make absolute path in test scheme.");
+ fs::make_absolute(TestScheme::TestDir, Path);
return std::string(Path.begin(), Path.end());
}
More information about the cfe-commits
mailing list