summaryrefslogtreecommitdiffstats
path: root/clang
diff options
context:
space:
mode:
authorAlexis Hunt <alercah@gmail.com>2011-06-22 02:25:26 +0000
committerAlexis Hunt <alercah@gmail.com>2011-06-22 02:25:26 +0000
commit7b7fece4d48a69e4976a04724621b9635d377ae4 (patch)
tree4e4d888935a7d15e5b5eca7ddd6c57e490677e49 /clang
parent6fafebfb6a9fad48c0a6621be08f63ff831b7fde (diff)
downloadbcm5719-llvm-7b7fece4d48a69e4976a04724621b9635d377ae4.tar.gz
bcm5719-llvm-7b7fece4d48a69e4976a04724621b9635d377ae4.zip
Avoid making assumption that this is either a CXXMethodDecl or a
FunctionTemplateDecl. I'm not quite sure what else it could be, though, and would appreciate some insight. This ought to fix the broken builds llvm-svn: 133600
Diffstat (limited to 'clang')
-rw-r--r--clang/lib/Sema/SemaLookup.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/clang/lib/Sema/SemaLookup.cpp b/clang/lib/Sema/SemaLookup.cpp
index 46058b69d14..df4484e0b33 100644
--- a/clang/lib/Sema/SemaLookup.cpp
+++ b/clang/lib/Sema/SemaLookup.cpp
@@ -2273,8 +2273,7 @@ Sema::SpecialMemberOverloadResult *Sema::LookupSpecialMember(CXXRecordDecl *D,
ArgType->getPointeeType().isConstQualified())
Result->setConstParamMatch(true);
}
- } else {
- FunctionTemplateDecl *Tmpl = cast<FunctionTemplateDecl>(*I);
+ } else if (FunctionTemplateDecl *Tmpl = cast<FunctionTemplateDecl>(*I)) {
AddTemplateOverloadCandidate(Tmpl, DeclAccessPair::make(Tmpl, AS_public),
0, &Arg, NumArgs, OCS, true);
}
OpenPOWER on IntegriCloud