diff options
Diffstat (limited to 'test')
-rw-r--r-- | test/CXX/dcl.decl/dcl.init/dcl.init.aggr/p1-0x.cpp | 4 | ||||
-rw-r--r-- | test/CXX/expr/expr.prim/expr.prim.lambda/p19.cpp | 9 | ||||
-rw-r--r-- | test/CXX/special/class.copy/implicit-move.cpp | 10 | ||||
-rw-r--r-- | test/CXX/special/class.copy/p11.0x.copy.cpp | 14 | ||||
-rw-r--r-- | test/CXX/special/class.ctor/p5-0x.cpp | 57 | ||||
-rw-r--r-- | test/SemaCXX/cxx0x-deleted-default-ctor.cpp | 54 | ||||
-rw-r--r-- | test/SemaCXX/dr1301.cpp | 16 | ||||
-rw-r--r-- | test/SemaCXX/implicit-exception-spec.cpp | 5 | ||||
-rw-r--r-- | test/SemaCXX/value-initialization.cpp | 4 |
9 files changed, 86 insertions, 87 deletions
diff --git a/test/CXX/dcl.decl/dcl.init/dcl.init.aggr/p1-0x.cpp b/test/CXX/dcl.decl/dcl.init/dcl.init.aggr/p1-0x.cpp index 03f25ba1de..47efde2db0 100644 --- a/test/CXX/dcl.decl/dcl.init/dcl.init.aggr/p1-0x.cpp +++ b/test/CXX/dcl.decl/dcl.init/dcl.init.aggr/p1-0x.cpp @@ -54,9 +54,9 @@ struct NonAggr5 : Aggr { // expected-note 3 {{candidate constructor}} }; NonAggr5 na5 = { b }; // expected-error {{no matching constructor for initialization of 'NonAggr5'}} template<typename...BaseList> -struct MaybeAggr5a : BaseList... {}; // expected-note {{explicitly marked deleted}} +struct MaybeAggr5a : BaseList... {}; // expected-note {{defined here}} MaybeAggr5a<> ma5a0 = {}; // ok -MaybeAggr5a<Aggr> ma5a1 = {}; // expected-error {{call to deleted constructor of 'MaybeAggr5a<Aggr>'}} +MaybeAggr5a<Aggr> ma5a1 = {}; // expected-error {{call to implicitly-deleted default constructor of 'MaybeAggr5a<Aggr>'}} // and no virtual functions. struct NonAggr6 { // expected-note 3 {{candidate constructor}} diff --git a/test/CXX/expr/expr.prim/expr.prim.lambda/p19.cpp b/test/CXX/expr/expr.prim/expr.prim.lambda/p19.cpp index b5a445cd9e..6fe3b25259 100644 --- a/test/CXX/expr/expr.prim/expr.prim.lambda/p19.cpp +++ b/test/CXX/expr/expr.prim/expr.prim.lambda/p19.cpp @@ -7,16 +7,13 @@ struct MoveOnly { template<typename T> T &&move(T&); void test_special_member_functions(MoveOnly mo, int i) { - // FIXME: terrible note - auto lambda1 = [i]() { }; // expected-note{{function has been explicitly marked deleted here}} \ - // expected-note{{the implicit copy assignment operator}} \ - // expected-note{{the implicit move assignment operator}} \ + auto lambda1 = [i]() { }; // expected-note 2 {{lambda expression begins here}} // Default constructor - decltype(lambda1) lambda2; // expected-error{{call to deleted constructor}} + decltype(lambda1) lambda2; // expected-error{{call to implicitly-deleted default constructor of 'decltype(lambda1)' (aka '<lambda}} // Copy assignment operator - lambda1 = lambda1; // expected-error{{overload resolution selected deleted operator '='}} + lambda1 = lambda1; // expected-error{{overload resolution selected implicitly-deleted copy assignment operator}} // Move assignment operator lambda1 = move(lambda1); diff --git a/test/CXX/special/class.copy/implicit-move.cpp b/test/CXX/special/class.copy/implicit-move.cpp index 74f7eee9ee..cc39af97ae 100644 --- a/test/CXX/special/class.copy/implicit-move.cpp +++ b/test/CXX/special/class.copy/implicit-move.cpp @@ -54,7 +54,7 @@ void test_basic_exclusion() { static_assert(noexcept(HasMoveConstructor((HasMoveConstructor()))), ""); HasMoveConstructor hmc; - hmc = HasMoveConstructor(); // expected-error {{selected deleted operator}} + hmc = HasMoveConstructor(); // expected-error {{selected implicitly-deleted copy assignment}} (HasMoveAssignment(HasMoveAssignment())); // expected-error {{uses deleted function}} HasMoveAssignment hma; @@ -87,8 +87,8 @@ private: ~PrivateDestructor() noexcept; }; -struct InheritsPrivateDestructor : PrivateDestructor {}; // expected-note {{explicitly marked deleted}} -struct ContainsPrivateDestructor { // expected-note {{explicitly marked deleted}} +struct InheritsPrivateDestructor : PrivateDestructor {}; // expected-note{{defined here}} +struct ContainsPrivateDestructor { // expected-note{{defined here}} PrivateDestructor pd; }; @@ -131,8 +131,8 @@ void test_deletion_exclusion() { ContainsPrivateMove cpm; static_assert(!noexcept(cpm = ContainsPrivateMove()), ""); - (InheritsPrivateDestructor(InheritsPrivateDestructor())); // expected-error {{call to deleted constructor}} - (ContainsPrivateDestructor(ContainsPrivateDestructor())); // expected-error {{call to deleted constructor}} + (InheritsPrivateDestructor(InheritsPrivateDestructor())); // expected-error {{call to implicitly-deleted default constructor}} + (ContainsPrivateDestructor(ContainsPrivateDestructor())); // expected-error {{call to implicitly-deleted default constructor}} static_assert(!noexcept(InheritsNonTrivialCopyOnly(InheritsNonTrivialCopyOnly())), ""); static_assert(!noexcept(ContainsNonTrivialCopyOnly(ContainsNonTrivialCopyOnly())), ""); diff --git a/test/CXX/special/class.copy/p11.0x.copy.cpp b/test/CXX/special/class.copy/p11.0x.copy.cpp index 752872adb9..65fd985924 100644 --- a/test/CXX/special/class.copy/p11.0x.copy.cpp +++ b/test/CXX/special/class.copy/p11.0x.copy.cpp @@ -9,7 +9,7 @@ union DeletedNTVariant { // expected-note{{here}} DeletedNTVariant(); }; DeletedNTVariant DVa; -DeletedNTVariant DVb(DVa); // expected-error{{call to deleted constructor}} +DeletedNTVariant DVb(DVa); // expected-error{{call to implicitly-deleted copy constructor}} struct DeletedNTVariant2 { // expected-note{{here}} union { @@ -18,7 +18,7 @@ struct DeletedNTVariant2 { // expected-note{{here}} DeletedNTVariant2(); }; DeletedNTVariant2 DV2a; -DeletedNTVariant2 DV2b(DV2a); // expected-error{{call to deleted constructor}} +DeletedNTVariant2 DV2b(DV2a); // expected-error{{call to implicitly-deleted copy constructor}} struct NoAccess { NoAccess() = default; @@ -32,7 +32,7 @@ struct HasNoAccess { // expected-note{{here}} NoAccess NA; }; HasNoAccess HNAa; -HasNoAccess HNAb(HNAa); // expected-error{{call to deleted constructor}} +HasNoAccess HNAb(HNAa); // expected-error{{call to implicitly-deleted copy constructor}} struct HasAccess { NoAccess NA; @@ -55,13 +55,13 @@ struct IsAmbiguous { // expected-note{{here}} IsAmbiguous(); }; IsAmbiguous IAa; -IsAmbiguous IAb(IAa); // expected-error{{call to deleted constructor}} +IsAmbiguous IAb(IAa); // expected-error{{call to implicitly-deleted copy constructor}} struct Deleted { // expected-note{{here}} IsAmbiguous IA; }; Deleted Da; -Deleted Db(Da); // expected-error{{call to deleted constructor}} +Deleted Db(Da); // expected-error{{call to implicitly-deleted copy constructor}} struct NoAccessDtor { private: @@ -75,7 +75,7 @@ struct HasNoAccessDtor { // expected-note{{here}} ~HasNoAccessDtor(); }; HasNoAccessDtor HNADa; -HasNoAccessDtor HNADb(HNADa); // expected-error{{call to deleted constructor}} +HasNoAccessDtor HNADb(HNADa); // expected-error{{call to implicitly-deleted copy constructor}} struct HasAccessDtor { NoAccessDtor NAD; @@ -87,4 +87,4 @@ struct RValue { // expected-note{{here}} int && ri = 1; }; RValue RVa; -RValue RVb(RVa); // expected-error{{call to deleted constructor}} +RValue RVb(RVa); // expected-error{{call to implicitly-deleted copy constructor}} diff --git a/test/CXX/special/class.ctor/p5-0x.cpp b/test/CXX/special/class.ctor/p5-0x.cpp index 00c25e8e3a..b2fa0cf298 100644 --- a/test/CXX/special/class.ctor/p5-0x.cpp +++ b/test/CXX/special/class.ctor/p5-0x.cpp @@ -21,19 +21,22 @@ int n; // - X is a union-like class that has a variant member with a non-trivial // default constructor, -union Deleted1a { UserProvidedDefCtor u; }; // expected-note {{deleted here}} -Deleted1a d1a; // expected-error {{deleted constructor}} +union Deleted1a { UserProvidedDefCtor u; }; // expected-note {{defined here}} +Deleted1a d1a; // expected-error {{implicitly-deleted default constructor}} union NotDeleted1a { DefaultedDefCtor1 nu; }; NotDeleted1a nd1a; // FIXME: clang implements the pre-FDIS rule, under which DefaultedDefCtor2's // default constructor is non-trivial. -union NotDeleted1b { DefaultedDefCtor2 nu; }; // unexpected-note {{deleted here}} -NotDeleted1b nd1b; // unexpected-error {{deleted constructor}} +union NotDeleted1b { DefaultedDefCtor2 nu; }; // unexpected-note {{defined here}} +NotDeleted1b nd1b; // unexpected-error {{implicitly-deleted default constructor}} // - any non-static data member with no brace-or-equal-initializer is of // reference type, -class Deleted2a { Deleted2a() = default; int &a; }; // expected-note {{deleted here}} -Deleted2a d2a; // expected-error {{deleted constructor}} +class Deleted2a { // expected-note {{defined here}} + Deleted2a() = default; // expected-note {{declared here}} + int &a; +}; +Deleted2a d2a; // expected-error {{implicitly-deleted default constructor}} class NotDeleted2a { int &a = n; }; NotDeleted2a nd2a; class NotDeleted2b { int &a = error; }; // expected-error {{undeclared identifier}} @@ -45,11 +48,11 @@ NotDeleted2b nd2b; class Deleted3a { const int a; }; // expected-note {{here}} \ expected-warning {{does not declare any constructor}} \ expected-note {{will never be initialized}} -Deleted3a d3a; // expected-error {{deleted constructor}} +Deleted3a d3a; // expected-error {{implicitly-deleted default constructor}} class Deleted3b { const DefaultedDefCtor1 a[42]; }; // expected-note {{here}} -Deleted3b d3b; // expected-error {{deleted constructor}} -class Deleted3c { const DefaultedDefCtor2 a; }; // expected-note {{deleted}} -Deleted3c d3c; // expected-error {{deleted constructor}} +Deleted3b d3b; // expected-error {{implicitly-deleted default constructor}} +class Deleted3c { const DefaultedDefCtor2 a; }; // expected-note {{defined here}} +Deleted3c d3c; // expected-error {{implicitly-deleted default constructor}} class NotDeleted3a { const int a = 0; }; NotDeleted3a nd3a; class NotDeleted3b { const DefaultedDefCtor1 a[42] = {}; }; @@ -60,23 +63,23 @@ union NotDeleted3d { const int a; int b; }; NotDeleted3d nd3d; // FIXME: this class should not have a deleted default constructor. union NotDeleted3e { const DefaultedDefCtor1 a[42]; int b; }; // unexpected-note {{here}} -NotDeleted3e nd3e; // unexpected-error {{deleted constructor}} +NotDeleted3e nd3e; // unexpected-error {{implicitly-deleted default constructor}} // FIXME: clang implements the pre-FDIS rule, under which DefaultedDefCtor2 is // non-trivial. union NotDeleted3f { const DefaultedDefCtor2 a; int b; }; // unexpected-note {{here}} -NotDeleted3f nd3f; // unexpected-error {{deleted constructor}} +NotDeleted3f nd3f; // unexpected-error {{implicitly-deleted default constructor}} // - X is a union and all of its variant members are of const-qualified type (or // array thereof), union Deleted4a { const int a; const int b; const UserProvidedDefCtor c; }; // expected-note {{here}} -Deleted4a d4a; // expected-error {{deleted constructor}} +Deleted4a d4a; // expected-error {{implicitly-deleted default constructor}} union Deleted4b { const int a; int b; }; Deleted4b d4b; // - X is a non-union class and all members of any anonymous union member are of // const-qualified type (or array thereof), struct Deleted5a { union { const int a; }; union { int b; }; }; // expected-note {{here}} -Deleted5a d5a; // expected-error {{deleted constructor}} +Deleted5a d5a; // expected-error {{implicitly-deleted default constructor}} struct Deleted5b { union { const int a; int b; }; union { const int c; int d; }; }; Deleted5b d5b; @@ -86,17 +89,17 @@ Deleted5b d5b; // constructor results in an ambiguity or in a function that is deleted or // inaccessible from the defaulted default constructor, or struct Deleted6a : Deleted2a {}; // expected-note {{here}} -Deleted6a d6a; // expected-error {{deleted constructor}} +Deleted6a d6a; // expected-error {{implicitly-deleted default constructor}} struct Deleted6b : virtual Deleted2a {}; // expected-note {{here}} -Deleted6b d6b; // expected-error {{deleted constructor}} +Deleted6b d6b; // expected-error {{implicitly-deleted default constructor}} struct Deleted6c { Deleted2a a; }; // expected-note {{here}} -Deleted6c d6c; // expected-error {{deleted constructor}} +Deleted6c d6c; // expected-error {{implicitly-deleted default constructor}} struct Deleted6d { DeletedDefCtor a; }; // expected-note {{here}} -Deleted6d d6d; // expected-error {{deleted constructor}} +Deleted6d d6d; // expected-error {{implicitly-deleted default constructor}} struct NotDeleted6a { DeletedDefCtor a = 0; }; NotDeleted6a nd6a; struct Deleted6e { PrivateDefCtor a; }; // expected-note {{here}} -Deleted6e d6e; // expected-error {{deleted constructor}} +Deleted6e d6e; // expected-error {{implicitly-deleted default constructor}} struct NotDeleted6b { PrivateDefCtor a = 0; }; NotDeleted6b nd6b; struct NotDeleted6c { Friend a; }; @@ -106,21 +109,21 @@ NotDeleted6c nd6c; // a destructor that is deleted or inaccessible from the defaulted default // constructor. struct Deleted7a : DeletedDtor {}; // expected-note {{here}} -Deleted7a d7a; // expected-error {{deleted constructor}} +Deleted7a d7a; // expected-error {{implicitly-deleted default constructor}} struct Deleted7b : virtual DeletedDtor {}; // expected-note {{here}} -Deleted7b d7b; // expected-error {{deleted constructor}} +Deleted7b d7b; // expected-error {{implicitly-deleted default constructor}} struct Deleted7c { DeletedDtor a; }; // expected-note {{here}} -Deleted7c d7c; // expected-error {{deleted constructor}} +Deleted7c d7c; // expected-error {{implicitly-deleted default constructor}} struct Deleted7d { DeletedDtor a = {}; }; // expected-note {{here}} -Deleted7d d7d; // expected-error {{deleted constructor}} +Deleted7d d7d; // expected-error {{implicitly-deleted default constructor}} struct Deleted7e : PrivateDtor {}; // expected-note {{here}} -Deleted7e d7e; // expected-error {{deleted constructor}} +Deleted7e d7e; // expected-error {{implicitly-deleted default constructor}} struct Deleted7f : virtual PrivateDtor {}; // expected-note {{here}} -Deleted7f d7f; // expected-error {{deleted constructor}} +Deleted7f d7f; // expected-error {{implicitly-deleted default constructor}} struct Deleted7g { PrivateDtor a; }; // expected-note {{here}} -Deleted7g d7g; // expected-error {{deleted constructor}} +Deleted7g d7g; // expected-error {{implicitly-deleted default constructor}} struct Deleted7h { PrivateDtor a = {}; }; // expected-note {{here}} -Deleted7h d7h; // expected-error {{deleted constructor}} +Deleted7h d7h; // expected-error {{implicitly-deleted default constructor}} struct NotDeleted7i : Friend {}; NotDeleted7i d7i; struct NotDeleted7j : virtual Friend {}; diff --git a/test/SemaCXX/cxx0x-deleted-default-ctor.cpp b/test/SemaCXX/cxx0x-deleted-default-ctor.cpp index 16c56642c0..9df41991cc 100644 --- a/test/SemaCXX/cxx0x-deleted-default-ctor.cpp +++ b/test/SemaCXX/cxx0x-deleted-default-ctor.cpp @@ -7,27 +7,27 @@ struct non_trivial { ~non_trivial(); }; -union bad_union { // expected-note {{marked deleted here}} +union bad_union { // expected-note {{defined here}} non_trivial nt; }; -bad_union u; // expected-error {{call to deleted constructor}} -union bad_union2 { // expected-note {{marked deleted here}} +bad_union u; // expected-error {{call to implicitly-deleted default constructor}} +union bad_union2 { // expected-note {{defined here}} const int i; }; -bad_union2 u2; // expected-error {{call to deleted constructor}} +bad_union2 u2; // expected-error {{call to implicitly-deleted default constructor}} -struct bad_anon { // expected-note {{marked deleted here}} +struct bad_anon { // expected-note {{defined here}} union { non_trivial nt; }; }; -bad_anon a; // expected-error {{call to deleted constructor}} -struct bad_anon2 { // expected-note {{marked deleted here}} +bad_anon a; // expected-error {{call to implicitly-deleted default constructor}} +struct bad_anon2 { // expected-note {{defined here}} union { const int i; }; }; -bad_anon2 a2; // expected-error {{call to deleted constructor}} +bad_anon2 a2; // expected-error {{call to implicitly-deleted default constructor}} // This would be great except that we implement union good_union { @@ -48,10 +48,10 @@ struct good : non_trivial { }; good g; -struct bad_const { // expected-note {{marked deleted here}} +struct bad_const { // expected-note {{defined here}} const good g; }; -bad_const bc; // expected-error {{call to deleted constructor}} +bad_const bc; // expected-error {{call to implicitly-deleted default constructor}} struct good_const { const non_trivial nt; @@ -65,38 +65,38 @@ struct no_dtor { ~no_dtor() = delete; }; -struct bad_field_default { // expected-note {{marked deleted here}} +struct bad_field_default { // expected-note {{defined here}} no_default nd; }; -bad_field_default bfd; // expected-error {{call to deleted constructor}} -struct bad_base_default : no_default { // expected-note {{marked deleted here}} +bad_field_default bfd; // expected-error {{call to implicitly-deleted default constructor}} +struct bad_base_default : no_default { // expected-note {{defined here}} }; -bad_base_default bbd; // expected-error {{call to deleted constructor}} +bad_base_default bbd; // expected-error {{call to implicitly-deleted default constructor}} -struct bad_field_dtor { // expected-note {{marked deleted here}} +struct bad_field_dtor { // expected-note {{defined here}} no_dtor nd; }; -bad_field_dtor bfx; // expected-error {{call to deleted constructor}} -struct bad_base_dtor : no_dtor { // expected-note {{marked deleted here}} +bad_field_dtor bfx; // expected-error {{call to implicitly-deleted default constructor}} +struct bad_base_dtor : no_dtor { // expected-note {{defined here}} }; -bad_base_dtor bbx; // expected-error {{call to deleted constructor}} +bad_base_dtor bbx; // expected-error {{call to implicitly-deleted default constructor}} struct ambiguous_default { ambiguous_default(); ambiguous_default(int = 2); }; -struct has_amb_field { // expected-note {{marked deleted here}} +struct has_amb_field { // expected-note {{defined here}} ambiguous_default ad; }; -has_amb_field haf; // expected-error {{call to deleted constructor}} +has_amb_field haf; // expected-error {{call to implicitly-deleted default constructor}} class inaccessible_default { inaccessible_default(); }; -struct has_inacc_field { // expected-note {{marked deleted here}} +struct has_inacc_field { // expected-note {{defined here}} inaccessible_default id; }; -has_inacc_field hif; // expected-error {{call to deleted constructor}} +has_inacc_field hif; // expected-error {{call to implicitly-deleted default constructor}} class friend_default { friend struct has_friend; @@ -107,11 +107,11 @@ struct has_friend { }; has_friend hf; -struct defaulted_delete { +struct defaulted_delete { // expected-note {{defined here}} no_default nd; - defaulted_delete() = default; // expected-note {{marked deleted here}} + defaulted_delete() = default; // expected-note{{declared here}} }; -defaulted_delete dd; // expected-error {{call to deleted constructor}} +defaulted_delete dd; // expected-error {{call to implicitly-deleted default constructor}} struct late_delete { no_default nd; @@ -121,12 +121,12 @@ 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 {}; // expected-error {{implicitly-deleted default 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 { union {}; }; }; // expected-error {{implicitly-deleted default constructor}} expected-note {{here}} static union { struct { struct {}; }; }; } diff --git a/test/SemaCXX/dr1301.cpp b/test/SemaCXX/dr1301.cpp index e3d63be1f6..a348977f50 100644 --- a/test/SemaCXX/dr1301.cpp +++ b/test/SemaCXX/dr1301.cpp @@ -14,13 +14,13 @@ int b = B().n; // expected-error {{call to deleted}} struct C { // expected-note {{here}} B b; }; -int c = C().b.n; // expected-error {{call to deleted}} +int c = C().b.n; // expected-error {{call to implicitly-deleted default}} -struct D { - D() = default; // expected-note {{here}} +struct D { // expected-note {{defined here}} + D() = default; // expected-note {{declared here}} B b; }; -int d = D().b.n; // expected-error {{call to deleted}} +int d = D().b.n; // expected-error {{call to implicitly-deleted default}} struct E { E() = default; @@ -37,7 +37,7 @@ int f = F().n; // ok union G { // expected-note {{here}} F f; }; -int g = G().f.n; // expected-error {{call to deleted}} +int g = G().f.n; // expected-error {{call to implicitly-deleted default}} struct H { int n; @@ -49,7 +49,7 @@ int h = H().n; // expected-error {{private constructor}} struct I { // expected-note {{here}} H h; }; -int i = I().h.n; // expected-error {{call to deleted}} +int i = I().h.n; // expected-error {{call to implicitly-deleted default}} struct J { J(); @@ -63,5 +63,5 @@ union K { // expected-note 2{{here}} J j; int m; }; -int k1 = K().j.n; // expected-error {{call to deleted}} -int k2 = K().j.f(); // expected-error {{call to deleted}} +int k1 = K().j.n; // expected-error {{call to implicitly-deleted default}} +int k2 = K().j.f(); // expected-error {{call to implicitly-deleted default}} diff --git a/test/SemaCXX/implicit-exception-spec.cpp b/test/SemaCXX/implicit-exception-spec.cpp index 559c3013f7..f8ee76727e 100644 --- a/test/SemaCXX/implicit-exception-spec.cpp +++ b/test/SemaCXX/implicit-exception-spec.cpp @@ -54,10 +54,9 @@ namespace ExceptionSpecification { // The same problem arises in delayed parsing of default arguments, // which clang does not yet support. namespace DefaultArgument { - // FIXME: this diagnostic is completely wrong. - struct Default { // expected-note {{explicitly marked deleted here}} + struct Default { // expected-note {{defined here}} struct T { - T(int = ExceptionIf<noexcept(Default())::f()); // expected-error {{call to deleted constructor}} + T(int = ExceptionIf<noexcept(Default())::f()); // expected-error {{call to implicitly-deleted default constructor}} } t; }; } diff --git a/test/SemaCXX/value-initialization.cpp b/test/SemaCXX/value-initialization.cpp index 19be03af8f..3b552e2a42 100644 --- a/test/SemaCXX/value-initialization.cpp +++ b/test/SemaCXX/value-initialization.cpp @@ -1,11 +1,11 @@ // RUN: %clang_cc1 -fsyntax-only -verify %s -std=c++11 -struct A { //expected-note {{marked deleted here}} \ +struct A { //expected-note {{defined here}} \ // expected-warning {{does not declare any constructor to initialize}} const int i; // expected-note{{const member 'i' will never be initialized}} virtual void f() { } }; int main () { - (void)A(); // expected-error {{call to deleted constructor}} + (void)A(); // expected-error {{call to implicitly-deleted default constructor}} } |