]> granicus.if.org Git - clang/commit
Use memoization for has()-matcher.
authorDaniel Jasper <djasper@google.com>
Thu, 25 Jul 2013 09:32:14 +0000 (09:32 +0000)
committerDaniel Jasper <djasper@google.com>
Thu, 25 Jul 2013 09:32:14 +0000 (09:32 +0000)
commit8357746fe68cdc45052de4fc9d1d8b03e14ab900
tree0d73ee55347a54c832b1862d15c85400f79416fd
parent2c4b2e42c5af83dc2138ecceab7f492fe9d6c555
Use memoization for has()-matcher.

In TUs with large classes, a matcher like

  methodDecl(ofClass(recordDecl(has(varDecl()))))

(finding all member functions of classes with static variables)
becomes unbearably slow otherwise.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@187115 91177308-0d34-0410-b5e6-96231b3b80d8
lib/ASTMatchers/ASTMatchFinder.cpp