summaryrefslogtreecommitdiffstats
path: root/clang/lib/Sema/SemaDecl.cpp
diff options
context:
space:
mode:
authorAbramo Bagnara <abramo.bagnara@gmail.com>2012-01-27 09:46:47 +0000
committerAbramo Bagnara <abramo.bagnara@gmail.com>2012-01-27 09:46:47 +0000
commit7945c981b974f58c021762e77f13cd4859ac447b (patch)
treebde36b37a54a925cd44c1683bd35e4ea3d3adb47 /clang/lib/Sema/SemaDecl.cpp
parentfc0da1a8e095a52fba5e7d9a0a537725716ce508 (diff)
downloadbcm5719-llvm-7945c981b974f58c021762e77f13cd4859ac447b.tar.gz
bcm5719-llvm-7945c981b974f58c021762e77f13cd4859ac447b.zip
Added source location for the template keyword in AST template-id expressions.
llvm-svn: 149127
Diffstat (limited to 'clang/lib/Sema/SemaDecl.cpp')
-rw-r--r--clang/lib/Sema/SemaDecl.cpp8
1 files changed, 5 insertions, 3 deletions
diff --git a/clang/lib/Sema/SemaDecl.cpp b/clang/lib/Sema/SemaDecl.cpp
index a6e1e401b3a..c20f9426fba 100644
--- a/clang/lib/Sema/SemaDecl.cpp
+++ b/clang/lib/Sema/SemaDecl.cpp
@@ -642,7 +642,7 @@ Corrected:
Result.suppressDiagnostics();
return NameClassification::Unknown();
- case LookupResult::NotFoundInCurrentInstantiation:
+ case LookupResult::NotFoundInCurrentInstantiation: {
// We performed name lookup into the current instantiation, and there were
// dependent bases, so we treat this result the same way as any other
// dependent nested-name-specifier.
@@ -657,7 +657,9 @@ Corrected:
// perform some heroics to see if we actually have a
// template-argument-list, which would indicate a missing 'template'
// keyword here.
- return BuildDependentDeclRefExpr(SS, NameInfo, /*TemplateArgs=*/0);
+ return BuildDependentDeclRefExpr(SS, /*TemplateKWLoc=*/SourceLocation(),
+ NameInfo, /*TemplateArgs=*/0);
+ }
case LookupResult::Found:
case LookupResult::FoundOverloaded:
@@ -763,7 +765,7 @@ Corrected:
}
if (!Result.empty() && (*Result.begin())->isCXXClassMember())
- return BuildPossibleImplicitMemberExpr(SS, Result, 0);
+ return BuildPossibleImplicitMemberExpr(SS, SourceLocation(), Result, 0);
bool ADL = UseArgumentDependentLookup(SS, Result, NextToken.is(tok::l_paren));
return BuildDeclarationNameExpr(SS, Result, ADL);
OpenPOWER on IntegriCloud