aboutsummaryrefslogtreecommitdiff
path: root/lib/Sema/SemaDeclCXX.cpp
diff options
context:
space:
mode:
authorRichard Smith <richard-llvm@metafoo.co.uk>2012-04-27 19:33:05 +0000
committerRichard Smith <richard-llvm@metafoo.co.uk>2012-04-27 19:33:05 +0000
commita1366cbab89ec6d4f630dca91e85d03d9e5d1d7d (patch)
treef751332ea38ee8e9d20bf8ea8b2da3369daa59bb /lib/Sema/SemaDeclCXX.cpp
parent392b3f5798a62fe038082df0a5e2244b08b917d8 (diff)
PR12224 (sort of): Diagnose inheriting constructor declarations in C++11 mode.
We do not support IRGen for these, and get some parts of the semantic analysis wrong. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@155728 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Sema/SemaDeclCXX.cpp')
-rw-r--r--lib/Sema/SemaDeclCXX.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/lib/Sema/SemaDeclCXX.cpp b/lib/Sema/SemaDeclCXX.cpp
index 5267499ea4..6183942893 100644
--- a/lib/Sema/SemaDeclCXX.cpp
+++ b/lib/Sema/SemaDeclCXX.cpp
@@ -5925,10 +5925,12 @@ Decl *Sema::ActOnUsingDeclaration(Scope *S,
case UnqualifiedId::IK_ConstructorName:
case UnqualifiedId::IK_ConstructorTemplateId:
- // C++0x inherited constructors.
+ // C++11 inheriting constructors.
Diag(Name.getLocStart(),
getLangOpts().CPlusPlus0x ?
- diag::warn_cxx98_compat_using_decl_constructor :
+ // FIXME: Produce warn_cxx98_compat_using_decl_constructor
+ // instead once inheriting constructors work.
+ diag::err_using_decl_constructor_unsupported :
diag::err_using_decl_constructor)
<< SS.getRange();