summaryrefslogtreecommitdiffstats
path: root/clang/lib/AST/ASTContext.cpp
diff options
context:
space:
mode:
authorReid Kleckner <reid@kleckner.net>2014-06-06 22:36:36 +0000
committerReid Kleckner <reid@kleckner.net>2014-06-06 22:36:36 +0000
commitdf6e4a06e42b8282220a73e6299b30ff2ec329ed (patch)
tree1384aa1336da74d0c26d9a12c19d3f4da9acf480 /clang/lib/AST/ASTContext.cpp
parent57e06dfb4123b2dc2b3483931f8319cc35bb44b3 (diff)
downloadbcm5719-llvm-df6e4a06e42b8282220a73e6299b30ff2ec329ed.tar.gz
bcm5719-llvm-df6e4a06e42b8282220a73e6299b30ff2ec329ed.zip
Delay lookup of simple default template arguments under -fms-compatibility
MSVC delays parsing of default arguments until instantiation. If the default argument is never used, it is never parsed. We don't model this. Instead, if lookup of a type name fails in a template argument context, we form a DependentNameType, which will be looked up at instantiation time. This fixes errors about 'CControlWinTraits' in atlwin.h. Reviewers: rsmith Differential Revision: http://reviews.llvm.org/D3995 llvm-svn: 210382
Diffstat (limited to 'clang/lib/AST/ASTContext.cpp')
-rw-r--r--clang/lib/AST/ASTContext.cpp2
1 files changed, 0 insertions, 2 deletions
diff --git a/clang/lib/AST/ASTContext.cpp b/clang/lib/AST/ASTContext.cpp
index 3f48e798687..4dff88bbebe 100644
--- a/clang/lib/AST/ASTContext.cpp
+++ b/clang/lib/AST/ASTContext.cpp
@@ -3318,8 +3318,6 @@ QualType ASTContext::getDependentNameType(ElaboratedTypeKeyword Keyword,
NestedNameSpecifier *NNS,
const IdentifierInfo *Name,
QualType Canon) const {
- assert(NNS->isDependent() && "nested-name-specifier must be dependent");
-
if (Canon.isNull()) {
NestedNameSpecifier *CanonNNS = getCanonicalNestedNameSpecifier(NNS);
ElaboratedTypeKeyword CanonKeyword = Keyword;
OpenPOWER on IntegriCloud