]> granicus.if.org Git - clang/commit
Fix several issues related to specializations and explicit instantiations.
authorNico Weber <nicolasweber@gmx.de>
Fri, 23 Dec 2011 20:58:04 +0000 (20:58 +0000)
committerNico Weber <nicolasweber@gmx.de>
Fri, 23 Dec 2011 20:58:04 +0000 (20:58 +0000)
commitff91d240d431afbec18e25909caaf5c17f26e643
treed02f9d52632765070556e55ee4bf6b32cfd7b620
parent17ba267cae596d5eb35fa0963ebcf73571572940
Fix several issues related to specializations and explicit instantiations.

Explicit instantiations following specializations are no-ops and hence have
no PointOfInstantiation. That was done correctly in most cases, but for a
specialization -> instantiation decl -> instantiation definition chain, the
definition didn't realize that it was a no-op. Fix that.

Also, when printing diagnostics for these no-ops, get the diag location from
the decl name location.

Add many test cases, one of them not yet passing (but it failed the same way
before this change). Fixes http://llvm.org/pr11558 and more.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@147225 91177308-0d34-0410-b5e6-96231b3b80d8
include/clang/AST/DeclTemplate.h
lib/Sema/SemaTemplate.cpp
test/CXX/temp/temp.spec/temp.expl.spec/examples.cpp