diff options
author | Dimitry Andric <dim@FreeBSD.org> | 2011-10-20 21:14:49 +0000 |
---|---|---|
committer | Dimitry Andric <dim@FreeBSD.org> | 2011-10-20 21:14:49 +0000 |
commit | 36981b17ed939300f6f8fc2355a255f711fcef71 (patch) | |
tree | ee2483e98b09cac943dc93a6969d83ca737ff139 /test/SemaCXX/cxx0x-deleted-default-ctor.cpp | |
parent | 180abc3db9ae3b4fc63cd65b15697e6ffcc8a657 (diff) | |
download | src-36981b17ed939300f6f8fc2355a255f711fcef71.tar.gz src-36981b17ed939300f6f8fc2355a255f711fcef71.zip |
Notes
Diffstat (limited to 'test/SemaCXX/cxx0x-deleted-default-ctor.cpp')
-rw-r--r-- | test/SemaCXX/cxx0x-deleted-default-ctor.cpp | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/test/SemaCXX/cxx0x-deleted-default-ctor.cpp b/test/SemaCXX/cxx0x-deleted-default-ctor.cpp index dcb6ba2790be..16c56642c06b 100644 --- a/test/SemaCXX/cxx0x-deleted-default-ctor.cpp +++ b/test/SemaCXX/cxx0x-deleted-default-ctor.cpp @@ -1,4 +1,4 @@ -// RUN: %clang_cc1 -std=c++0x -fsyntax-only -verify %s +// RUN: %clang_cc1 -std=c++11 -fsyntax-only -verify %s struct non_trivial { non_trivial(); @@ -118,3 +118,15 @@ struct late_delete { late_delete(); }; late_delete::late_delete() = default; // expected-error {{would delete it}} + +// See also rdar://problem/8125400. +namespace empty { + static union {}; // expected-error {{deleted constructor}} expected-note {{here}} + static union { union {}; }; + static union { struct {}; }; + static union { union { union {}; }; }; + static union { union { struct {}; }; }; + static union { struct { union {}; }; }; // expected-error {{deleted constructor}} expected-note {{here}} + static union { struct { struct {}; }; }; +} + |