summaryrefslogtreecommitdiffstats
path: root/clang/lib/Sema/Sema.cpp
diff options
context:
space:
mode:
authorDouglas Gregor <dgregor@apple.com>2009-06-14 08:02:22 +0000
committerDouglas Gregor <dgregor@apple.com>2009-06-14 08:02:22 +0000
commite141633f55335ad3bbb25d26e3dc4682ee4bbada (patch)
treeaa5f0cb482ea4b98fc7b3adec1eba92d63279bf5 /clang/lib/Sema/Sema.cpp
parent2f550270123d0bb955edce1a5b819fc16b8b66bd (diff)
downloadbcm5719-llvm-e141633f55335ad3bbb25d26e3dc4682ee4bbada.tar.gz
bcm5719-llvm-e141633f55335ad3bbb25d26e3dc4682ee4bbada.zip
Introduce a SFINAE "trap" that keeps track of the number of errors
that were suppressed due to SFINAE. By checking whether any errors occur at the end of template argument deduction, we avoid the possibility of suppressing an error (due to SFINAE) and then recovering so well that template argument deduction never detects that there was a problem. Thanks to Eli for the push in this direction. llvm-svn: 73336
Diffstat (limited to 'clang/lib/Sema/Sema.cpp')
-rw-r--r--clang/lib/Sema/Sema.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/clang/lib/Sema/Sema.cpp b/clang/lib/Sema/Sema.cpp
index 4dc52220726..a5f243816ab 100644
--- a/clang/lib/Sema/Sema.cpp
+++ b/clang/lib/Sema/Sema.cpp
@@ -183,7 +183,7 @@ Sema::Sema(Preprocessor &pp, ASTContext &ctxt, ASTConsumer &consumer,
CurBlock(0), PackContext(0), IdResolver(pp.getLangOptions()),
GlobalNewDeleteDeclared(false),
CompleteTranslationUnit(CompleteTranslationUnit),
- CurrentInstantiationScope(0) {
+ NumSFINAEErrors(0), CurrentInstantiationScope(0) {
StdNamespace = 0;
TUScope = 0;
OpenPOWER on IntegriCloud