diff options
author | Eric Liu <ioeric@google.com> | 2018-07-04 10:39:48 +0000 |
---|---|---|
committer | Eric Liu <ioeric@google.com> | 2018-07-04 10:39:48 +0000 |
commit | 156fca5d430ed9611a1c8f34f3ecc773fbf246a9 (patch) | |
tree | df3d9f7bb032ce941bde421f1830e9d42f82daab /clang-tools-extra | |
parent | 514ac22d8f5d4d04f8d1f5a7c085996ce1786eae (diff) | |
download | bcm5719-llvm-156fca5d430ed9611a1c8f34f3ecc773fbf246a9.tar.gz bcm5719-llvm-156fca5d430ed9611a1c8f34f3ecc773fbf246a9.zip |
[clangd] only ignore collected symbols if TU has uncompilable errors.
llvm-svn: 336260
Diffstat (limited to 'clang-tools-extra')
-rw-r--r-- | clang-tools-extra/clangd/global-symbol-builder/GlobalSymbolBuilderMain.cpp | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/clang-tools-extra/clangd/global-symbol-builder/GlobalSymbolBuilderMain.cpp b/clang-tools-extra/clangd/global-symbol-builder/GlobalSymbolBuilderMain.cpp index 1cfda579d7f..1082cf60d09 100644 --- a/clang-tools-extra/clangd/global-symbol-builder/GlobalSymbolBuilderMain.cpp +++ b/clang-tools-extra/clangd/global-symbol-builder/GlobalSymbolBuilderMain.cpp @@ -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; } |