4 ms·
I've played a bit with weggli, it's pretty useful for "grepping" an entire codebase for patterns (for example, to search for antipatterns in a codebase) Perhap
by creatornator 5y ago
I've played a bit with weggli, it's pretty useful for "grepping" an entire codebase for patterns (for example, to search for antipatterns in a codebase)
Perhaps more capable but also more complex is clang-query:
https://devblogs.microsoft.com/cppblog/exploring-clang-tooling-part-2-examining-the-clang-ast-with-clang-query/ https://devblogs.microsoft.com/cppblog/exploring-clang-tooli...
I couldn't find any direct documentation of clang-query, but it's part of clang-tools:
https://clang.llvm.org/extra/doxygen/ClangQuery_8cpp_source.html https://clang.llvm.org/extra/doxygen/ClangQuery_8cpp_source....
Similarly clang's LibASTMatchers (for writing matchers which can do anything from displaying a message, to actually transforming the matched code):
https://clang.llvm.org/docs/LibASTMatchers.html https://clang.llvm.org/docs/LibASTMatchers.html