AST: Don't treat a TemplateExpansion as a Template

Summary:
Instead of calling getAsTemplate(), call
getAsTemplateOrTemplatePattern() because it handles the
TemplateExpansion case too.

This fixes PR16997.

Reviewers: doug.gregor, rsmith

Reviewed By: rsmith

CC: cfe-commits

Differential Revision: http://llvm-reviews.chandlerc.com/D1512

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@189422 91177308-0d34-0410-b5e6-96231b3b80d8
This test now needs C++11


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@189425 91177308-0d34-0410-b5e6-96231b3b80d8
Revert "Use CMAKE_RUNTIME_OUTPUT_DIRECTORY instead of LLVM_BINARY_DIR for installing Clang headers."

This appears to be breaking the buildbots.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@189426 91177308-0d34-0410-b5e6-96231b3b80d8
Some of this test doesn't want -std=c++11

Sorry for the churn.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@189429 91177308-0d34-0410-b5e6-96231b3b80d8