summaryrefslogtreecommitdiffstats
path: root/test/CXX/special/class.inhctor/p4.cpp
diff options
context:
space:
mode:
authordim <dim@FreeBSD.org>2013-12-22 00:07:40 +0000
committerdim <dim@FreeBSD.org>2013-12-22 00:07:40 +0000
commit952eddef9aff85b1e92626e89baaf7a360e2ac85 (patch)
treedf8df0b0067b381eab470a3b8f28d14a552a6340 /test/CXX/special/class.inhctor/p4.cpp
parentea266cad53e3d49771fa38103913d3ec7a166694 (diff)
downloadFreeBSD-src-952eddef9aff85b1e92626e89baaf7a360e2ac85.zip
FreeBSD-src-952eddef9aff85b1e92626e89baaf7a360e2ac85.tar.gz
Vendor import of clang release_34 branch r197841 (effectively, 3.4 RC3):
https://llvm.org/svn/llvm-project/cfe/branches/release_34@197841
Diffstat (limited to 'test/CXX/special/class.inhctor/p4.cpp')
-rw-r--r--test/CXX/special/class.inhctor/p4.cpp13
1 files changed, 6 insertions, 7 deletions
diff --git a/test/CXX/special/class.inhctor/p4.cpp b/test/CXX/special/class.inhctor/p4.cpp
index 512705e..356cdef 100644
--- a/test/CXX/special/class.inhctor/p4.cpp
+++ b/test/CXX/special/class.inhctor/p4.cpp
@@ -43,13 +43,13 @@ FA fa2{X<2>{}}; // expected-error {{calling a private constructor}}
// It is deleted if the corresponding constructor [...] is deleted.
struct G {
- G(int) = delete;
- template<typename T> G(T*) = delete;
+ G(int) = delete; // expected-note {{function has been explicitly marked deleted here}}
+ template<typename T> G(T*) = delete; // expected-note {{function has been explicitly marked deleted here}}
};
struct H : G {
- using G::G; // expected-note 2{{marked deleted here}}
+ using G::G; // expected-note 2{{deleted constructor was inherited here}}
};
-H h1(5); // expected-error {{call to implicitly-deleted function of 'H'}}
+H h1(5); // expected-error {{call to deleted constructor of 'H'}}
H h2("foo"); // expected-error {{call to deleted constructor of 'H'}}
@@ -58,15 +58,14 @@ H h2("foo"); // expected-error {{call to deleted constructor of 'H'}}
namespace DRnnnn {
struct A {
constexpr A(int, float = 0) {}
- explicit A(int, int = 0) {}
+ explicit A(int, int = 0) {} // expected-note {{constructor cannot be inherited}}
A(int, int, int = 0) = delete;
};
struct B : A {
- // FIXME: produce notes indicating why it was deleted
using A::A; // expected-note {{here}}
};
constexpr B b0(0, 0.0f); // ok, constexpr
- B b1(0, 1); // expected-error {{call to implicitly-deleted}}
+ B b1(0, 1); // expected-error {{call to deleted constructor of 'DRnnnn::B'}}
}
OpenPOWER on IntegriCloud