llvm-project/clang-tools-extra
Sam McCall 3c1f4903b7 [clang-tidy] Untangle layering in ClangTidyDiagnosticConsumer somewhat. NFC
Summary:
Clang's hierarchy is CompilerInstance -> DiagnosticsEngine -> DiagnosticConsumer.
(Ownership is optional/shared, but this structure is fairly clear).

Currently ClangTidyDiagnosticConsumer *owns* the DiagnosticsEngine:
 - this inverts the hierarchy, which is confusing
 - this means ClangTidyDiagnosticConsumer() mutates the passed-in context, which
   is both surprising and limits flexibility
 - it's not possible to use a different DiagnosticsEngine with ClangTidy

This means a little bit more code in the places ClangTidy is used standalone,
but more flexibility in using ClangTidy with other diagnostics configurations.

Reviewers: hokein

Subscribers: xazax.hun, cfe-commits

Differential Revision: https://reviews.llvm.org/D54033

llvm-svn: 346418
2018-11-08 17:42:16 +00:00
..
change-namespace [change-namespace] Enhance detection of conflicting namespaces. 2018-10-22 12:48:49 +00:00
clang-apply-replacements Deduplicate replacements from diagnostics. 2018-09-25 08:24:07 +00:00
clang-doc [clang-doc] Switch to default to all-TUs executor 2018-10-26 19:11:34 +00:00
clang-move [clang-move] Remove clang:: qualifier 2018-10-11 16:09:26 +00:00
clang-query [clang-query] Add non-exclusive output API 2018-10-29 18:59:56 +00:00
clang-reorder-fields [CMake] Use PRIVATE in target_link_libraries for executables 2017-12-05 21:49:56 +00:00
clang-tidy [clang-tidy] Untangle layering in ClangTidyDiagnosticConsumer somewhat. NFC 2018-11-08 17:42:16 +00:00
clang-tidy-vs Update copyright year to 2018. 2018-06-18 12:22:17 +00:00
clangd [clangd] Drop namespace references in the index. 2018-11-07 14:59:24 +00:00
docs [clang-tidy] fix example code-blocks indendation 2018-11-05 22:30:17 +00:00
include-fixer Replace hardcoded format styles in a few tools with the default style in libFormat. 2018-08-02 10:30:56 +00:00
modularize NFC: Enforce good formatting across multiple clang-tools-extra files 2018-08-14 16:03:32 +00:00
pp-trace [pp-trace] Remove unused using directives 2018-09-18 06:57:58 +00:00
test [clang-tidy] fix test after r346414 2018-11-08 17:10:31 +00:00
tool-template Port getLocStart -> getBeginLoc 2018-08-09 22:42:26 +00:00
unittests [clang-tidy] Untangle layering in ClangTidyDiagnosticConsumer somewhat. NFC 2018-11-08 17:42:16 +00:00
.arcconfig [clang-tools-extra] Set up .arcconfig to point to new Diffusion CTE repository 2017-11-27 15:58:25 +00:00
.gitignore
CMakeLists.txt [clang-tidy] Build it even without static analyzer 2018-10-01 20:24:22 +00:00
CODE_OWNERS.TXT Updating the code owners list. 2015-09-02 20:00:41 +00:00
LICENSE.TXT Update copyright year to 2018. 2018-06-18 12:22:17 +00:00
README.txt

README.txt

//===----------------------------------------------------------------------===//
// Clang Tools repository
//===----------------------------------------------------------------------===//

Welcome to the repository of extra Clang Tools.  This repository holds tools
that are developed as part of the LLVM compiler infrastructure project and the
Clang frontend.  These tools are kept in a separate "extra" repository to
allow lighter weight checkouts of the core Clang codebase.

This repository is only intended to be checked out inside of a full LLVM+Clang
tree, and in the 'tools/extra' subdirectory of the Clang checkout.

All discussion regarding Clang, Clang-based tools, and code in this repository
should be held using the standard Clang mailing lists:
  http://lists.llvm.org/mailman/listinfo/cfe-dev

Code review for this tree should take place on the standard Clang patch and
commit lists:
  http://lists.llvm.org/mailman/listinfo/cfe-commits

If you find a bug in these tools, please file it in the LLVM bug tracker:
  http://llvm.org/bugs/