[clang-tidy] Use new ASTMatchers to identify template instantiations instead of copying it everywhere.

No intended functionality change.