[clang-tools-extra] r336260 - [clangd] only ignore collected symbols if TU has uncompilable errors.
Eric Liu via cfe-commits
cfe-commits at lists.llvm.org
Wed Jul 4 03:39:48 PDT 2018
Author: ioeric
Date: Wed Jul 4 03:39:48 2018
New Revision: 336260
URL: http://llvm.org/viewvc/llvm-project?rev=336260&view=rev
Log:
[clangd] only ignore collected symbols if TU has uncompilable errors.
Modified:
clang-tools-extra/trunk/clangd/global-symbol-builder/GlobalSymbolBuilderMain.cpp
Modified: clang-tools-extra/trunk/clangd/global-symbol-builder/GlobalSymbolBuilderMain.cpp
URL: http://llvm.org/viewvc/llvm-project/clang-tools-extra/trunk/clangd/global-symbol-builder/GlobalSymbolBuilderMain.cpp?rev=336260&r1=336259&r2=336260&view=diff
==============================================================================
--- clang-tools-extra/trunk/clangd/global-symbol-builder/GlobalSymbolBuilderMain.cpp (original)
+++ clang-tools-extra/trunk/clangd/global-symbol-builder/GlobalSymbolBuilderMain.cpp Wed Jul 4 03:39:48 2018
@@ -84,9 +84,10 @@ public:
const auto &CI = getCompilerInstance();
if (CI.hasDiagnostics() &&
- (CI.getDiagnosticClient().getNumErrors() > 0)) {
- llvm::errs() << "Found errors in the translation unit. Igoring "
- "collected symbols...\n";
+ CI.getDiagnostics().hasUncompilableErrorOccurred()) {
+ llvm::errs()
+ << "Found uncompilable errors in the translation unit. Igoring "
+ "collected symbols...\n";
return;
}
More information about the cfe-commits
mailing list