summaryrefslogtreecommitdiffstats
path: root/clang/lib/Sema/SemaTemplate.cpp
diff options
context:
space:
mode:
authorDouglas Gregor <dgregor@apple.com>2010-07-06 18:33:12 +0000
committerDouglas Gregor <dgregor@apple.com>2010-07-06 18:33:12 +0000
commitd890b734f81f50a45efe93c8d121728a0760a649 (patch)
treec213c0827cf5de6088746f38eefb94eb8c71635f /clang/lib/Sema/SemaTemplate.cpp
parent6191f6c60749dee9f97deb1cb013b0594c9c2134 (diff)
downloadbcm5719-llvm-d890b734f81f50a45efe93c8d121728a0760a649.tar.gz
bcm5719-llvm-d890b734f81f50a45efe93c8d121728a0760a649.zip
Correctly set the location of the "template" keyword for a class
template specialization, from Peter Collingbourne. llvm-svn: 107682
Diffstat (limited to 'clang/lib/Sema/SemaTemplate.cpp')
-rw-r--r--clang/lib/Sema/SemaTemplate.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/clang/lib/Sema/SemaTemplate.cpp b/clang/lib/Sema/SemaTemplate.cpp
index 336a7bf9d04..af1cb50006e 100644
--- a/clang/lib/Sema/SemaTemplate.cpp
+++ b/clang/lib/Sema/SemaTemplate.cpp
@@ -3959,7 +3959,8 @@ Sema::ActOnClassTemplateSpecialization(Scope *S, unsigned TagSpec,
TemplateArgs, CanonType);
if (TUK != TUK_Friend) {
Specialization->setTypeAsWritten(WrittenTy);
- Specialization->setTemplateKeywordLoc(KWLoc);
+ if (TemplateParams)
+ Specialization->setTemplateKeywordLoc(TemplateParams->getTemplateLoc());
}
TemplateArgsIn.release();
OpenPOWER on IntegriCloud