summaryrefslogtreecommitdiffstats
path: root/clang/lib
diff options
context:
space:
mode:
authorDouglas Gregor <dgregor@apple.com>2009-11-23 12:39:54 +0000
committerDouglas Gregor <dgregor@apple.com>2009-11-23 12:39:54 +0000
commit601f4f0b07925c9225b2cbd9de268762dadf615a (patch)
tree807e606310a6bcbcebf64e13d5ecdc140daedb80 /clang/lib
parent27381f3d93454ef46c7ede3089d910930e7ffabf (diff)
downloadbcm5719-llvm-601f4f0b07925c9225b2cbd9de268762dadf615a.tar.gz
bcm5719-llvm-601f4f0b07925c9225b2cbd9de268762dadf615a.zip
Improve type-checking of templates by distinguishing between members
of the current instantiation and members of an unknown specialization when type-checking a qualified-if expression. llvm-svn: 89653
Diffstat (limited to 'clang/lib')
-rw-r--r--clang/lib/Sema/SemaExpr.cpp8
1 files changed, 2 insertions, 6 deletions
diff --git a/clang/lib/Sema/SemaExpr.cpp b/clang/lib/Sema/SemaExpr.cpp
index 1506fbaf606..d32b3a97cd3 100644
--- a/clang/lib/Sema/SemaExpr.cpp
+++ b/clang/lib/Sema/SemaExpr.cpp
@@ -673,12 +673,8 @@ Sema::ActOnDeclarationNameExpr(Scope *S, SourceLocation Loc,
if (SS && SS->isInvalid())
return ExprError();
- // C++ [temp.dep.expr]p3:
- // An id-expression is type-dependent if it contains:
- // -- a nested-name-specifier that contains a class-name that
- // names a dependent type.
- // FIXME: Member of the current instantiation.
- if (SS && isDependentScopeSpecifier(*SS)) {
+ // Determine whether this is a member of an unknown specialization.
+ if (SS && SS->isSet() && !computeDeclContext(*SS, false)) {
return Owned(new (Context) DependentScopeDeclRefExpr(Name, Context.DependentTy,
Loc, SS->getRange(),
static_cast<NestedNameSpecifier *>(SS->getScopeRep()),
OpenPOWER on IntegriCloud