summaryrefslogtreecommitdiffstats
path: root/clang/lib/Sema/SemaTemplate.cpp
diff options
context:
space:
mode:
authorDouglas Gregor <dgregor@apple.com>2011-03-01 01:34:45 +0000
committerDouglas Gregor <dgregor@apple.com>2011-03-01 01:34:45 +0000
commit3d0da5f5dde8ed58cc30a83cf88317aeab171387 (patch)
tree34af24b04245f79181828d81beb086c1c9ffed91 /clang/lib/Sema/SemaTemplate.cpp
parent918c84789073b47164ecb49ae4b9aad175a8e942 (diff)
downloadbcm5719-llvm-3d0da5f5dde8ed58cc30a83cf88317aeab171387.tar.gz
bcm5719-llvm-3d0da5f5dde8ed58cc30a83cf88317aeab171387.zip
Push nested-name-specifier source location information into
DependentNameTypeLoc. Teach the recursive AST visitor and libclang how to walk DependentNameTypeLoc nodes. Also, teach libclang about TypedefDecl source ranges, so that we get those. The massive churn in test/Index/recursive-cxx-member-calls.cpp is a good thing: we're annotating a lot more of this test correctly now. llvm-svn: 126729
Diffstat (limited to 'clang/lib/Sema/SemaTemplate.cpp')
-rw-r--r--clang/lib/Sema/SemaTemplate.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/clang/lib/Sema/SemaTemplate.cpp b/clang/lib/Sema/SemaTemplate.cpp
index b3187de0258..cdb35a20c09 100644
--- a/clang/lib/Sema/SemaTemplate.cpp
+++ b/clang/lib/Sema/SemaTemplate.cpp
@@ -5909,8 +5909,8 @@ Sema::ActOnTypenameType(Scope *S, SourceLocation TypenameLoc,
Diag(TypenameLoc, diag::ext_typename_outside_of_template)
<< FixItHint::CreateRemoval(TypenameLoc);
- QualType T = CheckTypenameType(ETK_Typename, TypenameLoc,
- SS.getWithLocInContext(Context),
+ NestedNameSpecifierLoc QualifierLoc = SS.getWithLocInContext(Context);
+ QualType T = CheckTypenameType(ETK_Typename, TypenameLoc, QualifierLoc,
II, IdLoc);
if (T.isNull())
return true;
@@ -5919,7 +5919,7 @@ Sema::ActOnTypenameType(Scope *S, SourceLocation TypenameLoc,
if (isa<DependentNameType>(T)) {
DependentNameTypeLoc TL = cast<DependentNameTypeLoc>(TSI->getTypeLoc());
TL.setKeywordLoc(TypenameLoc);
- TL.setQualifierRange(SS.getRange());
+ TL.setQualifierLoc(QualifierLoc);
TL.setNameLoc(IdLoc);
} else {
ElaboratedTypeLoc TL = cast<ElaboratedTypeLoc>(TSI->getTypeLoc());
OpenPOWER on IntegriCloud