summaryrefslogtreecommitdiffstats
path: root/clang/lib/Sema
diff options
context:
space:
mode:
authorHans Wennborg <hans@hanshq.net>2015-06-12 21:23:23 +0000
committerHans Wennborg <hans@hanshq.net>2015-06-12 21:23:23 +0000
commitb274738725f2e25595a6e1d021699194c146221a (patch)
tree7bfd2484789660ce0f8d42f0374157e4fb6ecd33 /clang/lib/Sema
parent1054420ba3b908ade5ef654c4cb82f174a8430c4 (diff)
downloadbcm5719-llvm-b274738725f2e25595a6e1d021699194c146221a.tar.gz
bcm5719-llvm-b274738725f2e25595a6e1d021699194c146221a.zip
[ms] Don't try to delay lookup for failures in SFINAE context (PR23823)
The underlying problem in PR23823 already existed before my recent change in r239558, but that change made it worse (failing not only for undeclared symbols, but also failed overload resolution). This makes Clang not try to delay the lookup in SFINAE context. I assume no current code is relying on SFINAE working with lookups that need to be delayed, because that never seems to have worked. Differential Revision: http://reviews.llvm.org/D10417 llvm-svn: 239639
Diffstat (limited to 'clang/lib/Sema')
-rw-r--r--clang/lib/Sema/SemaOverload.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/clang/lib/Sema/SemaOverload.cpp b/clang/lib/Sema/SemaOverload.cpp
index 117ca135a22..f8610e009bd 100644
--- a/clang/lib/Sema/SemaOverload.cpp
+++ b/clang/lib/Sema/SemaOverload.cpp
@@ -10750,7 +10750,8 @@ bool Sema::buildOverloadedCallSet(Scope *S, Expr *Fn,
// functions, including those from argument-dependent lookup.
AddOverloadedCallCandidates(ULE, Args, *CandidateSet);
- if (getLangOpts().MSVCCompat && CurContext->isDependentContext() &&
+ if (getLangOpts().MSVCCompat &&
+ CurContext->isDependentContext() && !isSFINAEContext() &&
(isa<FunctionDecl>(CurContext) || isa<CXXRecordDecl>(CurContext))) {
OverloadCandidateSet::iterator Best;
OpenPOWER on IntegriCloud