[clang-tidy] Improve add_new_check.py to recognize more checks
When looking for whether or not a check provides fixits, the script examines the implementation of the check. Some checks are not implemented in source files that correspond one-to-one with the check name, e.g. cert-dcl21-cpp. So if we can't find the check implementation directly from the check name, open up the corresponding module file and look for the class name that is registered with the check. Then consult the file corresponding to the class name. Some checks are derived from a base class that implements fixits. So if we can't find fixits in the implementation file for a check, scrape out the name of it's base class. If it's not ClangTidyCheck, then consult the base class implementation to look for fixit support. Differential Revision: https://reviews.llvm.org/D126134 Fixes #55630
Loading
Please sign in to comment