dsanders created this revision. dsanders added a reviewer: aaron.ballman. Herald added a project: clang. Herald added a subscriber: cfe-commits.
Following on from review comments in D65919 <https://reviews.llvm.org/D65919> about the ordering of the registerCheck<> calls. Ignore namespaces when finding the correct insertion point to make the heuristic more accurate. The actual sort order is based on the check name in the string but that isn't always on the same line so the class name is used as a proxy. Repository: rG LLVM Github Monorepo https://reviews.llvm.org/D66505 Files: clang-tools-extra/clang-tidy/add_new_check.py Index: clang-tools-extra/clang-tidy/add_new_check.py =================================================================== --- clang-tools-extra/clang-tidy/add_new_check.py +++ clang-tools-extra/clang-tidy/add_new_check.py @@ -185,7 +185,7 @@ check_added = True f.write(check_decl) else: - match = re.search('registerCheck<(.*)>', line) + match = re.search('registerCheck<((.*::).*)>', line) if match and match.group(1) > check_name_camel: check_added = True f.write(check_decl)
Index: clang-tools-extra/clang-tidy/add_new_check.py =================================================================== --- clang-tools-extra/clang-tidy/add_new_check.py +++ clang-tools-extra/clang-tidy/add_new_check.py @@ -185,7 +185,7 @@ check_added = True f.write(check_decl) else: - match = re.search('registerCheck<(.*)>', line) + match = re.search('registerCheck<((.*::).*)>', line) if match and match.group(1) > check_name_camel: check_added = True f.write(check_decl)
_______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits