[PATCH] D89936: [clang-tidy] adding "--clang-tidy-config=<file-path>" to specify custom config file

Dmitry Polukhin via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Tue Oct 27 03:57:04 PDT 2020


DmitryPolukhin added a comment.

@Hiralo, it looks like you uploaded wrong diff because your previous revision is shown as "base" version. Base revision should be clang-tidy sources without your changes.

Please add Lit test for the new option, see https://llvm.org/docs/TestingGuide.html for more details and existing clang-tidy tests.



================
Comment at: clang-tools-extra/clang-tidy/tool/ClangTidyMain.cpp:330
   if (!Config.empty()) {
     if (llvm::ErrorOr<ClangTidyOptions> ParsedConfig =
             parseConfiguration(Config)) {
----------------
I think you can make this option much simpler if you just read file content and use it or `Config` here. No changes in clang-tools-extra/clang-tidy/ClangTidyOptions.h/.cpp will be required.


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

https://reviews.llvm.org/D89936



More information about the cfe-commits mailing list