[PATCH] D59935: Disable warnings when indexing as a standalone action.

Haojian Wu via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Thu Mar 28 08:04:32 PDT 2019


hokein added inline comments.


================
Comment at: clangd/index/IndexAction.cpp:140
+    // Avoids some analyses too.
+    CI.getDiagnosticOpts().IgnoreWarnings = true;
     return WrapperFrontendAction::BeginInvocation(CI);
----------------
Can we add a unittest for this?

IIRC, `IgnoreWarnings` option must be set before `CompilerInstance` is created, otherwise it doesn't take affect, see https://github.com/llvm-mirror/clang-tools-extra/blob/master/clangd/CodeComplete.cpp#L1029


Repository:
  rCTE Clang Tools Extra

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D59935/new/

https://reviews.llvm.org/D59935





More information about the cfe-commits mailing list