[PATCH] D16113: [clang-tdiy] Add header file extension configuration support.

Alexander Kornienko via cfe-commits cfe-commits at lists.llvm.org
Thu Jan 14 05:22:44 PST 2016


alexfh added inline comments.

================
Comment at: clang-tidy/tool/ClangTidyMain.cpp:78
@@ +77,3 @@
+static cl::opt<std::string>
+HeaderFileExtensions("header-file-extensions",
+                     cl::desc("File extensions that regard as header file.\n"
----------------
hokein wrote:
> alexfh wrote:
> > We don't need a command-line flag for this. The regular way to configure clang-tidy is .clang-tidy files. However, if needed, check options can be configured from the command line via the `-config=` option. 
> From my understanding, it is a global option for header-file-extensions, right? If we remove this command-line flag, there is only local `header-file-extensions` option remained for particular checks.
Both local and global options reside in `CheckOptions` and can be configured in the same way using either a .clang-tidy file or the -config= command-line option. The only difference between local and global options is that the name of the latter is not prefixed with the "CheckName.". Makes sense?


Repository:
  rL LLVM

http://reviews.llvm.org/D16113





More information about the cfe-commits mailing list