[clangd] Log error message instead write to errs(). NFC
authorEric Liu <ioeric@google.com>
Tue, 15 May 2018 16:22:43 +0000 (16:22 +0000)
committerEric Liu <ioeric@google.com>
Tue, 15 May 2018 16:22:43 +0000 (16:22 +0000)
llvm-svn: 332366

clang-tools-extra/clangd/index/SymbolCollector.cpp

index 4e2e7d9..9e9df7f 100644 (file)
@@ -51,8 +51,7 @@ llvm::Optional<std::string> toURI(const SourceManager &SM, StringRef Path,
   if (std::error_code EC =
           SM.getFileManager().getVirtualFileSystem()->makeAbsolute(
               AbsolutePath))
-    llvm::errs() << "Warning: could not make absolute file: '" << EC.message()
-                 << '\n';
+    log("Warning: could not make absolute file: " + EC.message());
   if (llvm::sys::path::is_absolute(AbsolutePath)) {
     // Handle the symbolic link path case where the current working directory
     // (getCurrentWorkingDirectory) is a symlink./ We always want to the real