clang-format: Add a consumer to diagnostics engine
authorKrasimir Georgiev <krasimir@google.com>
Thu, 29 Oct 2020 10:27:54 +0000 (11:27 +0100)
committerKrasimir Georgiev <krasimir@google.com>
Thu, 29 Oct 2020 10:28:27 +0000 (11:28 +0100)
commitdf00267f1fdb0b098dc42f1caa8a59b29c8e0e5f
tree1526ebe9a3ad9e79c8bf6f373322660bbc8f18be
parentb3761765d00bb4dafb5ecdf17502f7143432371b
clang-format: Add a consumer to diagnostics engine

Contributed by dmikis (Kirill Dmitrenko)!

Otherwise problems like trying to format readonly file in-place led to crashes.

I've added reviewers by looking at `git blame` and other reviews to the changed file, so may have missed someone.

Reviewed By: krasimir

Differential Revision: https://reviews.llvm.org/D90121
clang/tools/clang-format/CMakeLists.txt
clang/tools/clang-format/ClangFormat.cpp