[clangd] No crash on "-verify" mode.
authorHaojian Wu <hokein.wu@gmail.com>
Thu, 19 Nov 2020 10:02:14 +0000 (11:02 +0100)
committerHaojian Wu <hokein.wu@gmail.com>
Thu, 19 Nov 2020 14:51:53 +0000 (15:51 +0100)
commit734d2f98f64940b1f545d677729d213a954c7a3f
tree8c808671b49716b9052631442c7d06bd099f32fe
parent7a0ea120e2a1fffab71f9c8e3d5337899f7a42af
[clangd] No crash on "-verify" mode.

If there is a "-verify" flag in the compile command, clangd will crash
(hit the assertion) inside the `~VerifyDiagnosticConsumer` (Looks like our
compiler invocation doesn't setup correctly?).

This patch disables the verify mode as it is rarely useful in clangd.

Differential Revision: https://reviews.llvm.org/D91777
clang-tools-extra/clangd/Compiler.cpp
clang-tools-extra/clangd/unittests/DiagnosticsTests.cpp