PR c++/54812
* g++.dg/cpp0x/defaulted47.C: New.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@204057
138bc75d-0d04-0410-961f-
82ee72b054a4
+2013-10-25 Paolo Carlini <paolo.carlini@oracle.com>
+
+ PR c++/54812
+ * g++.dg/cpp0x/defaulted47.C: New.
+
2013-10-25 Eric Botcazou <ebotcazou@adacore.com>
* gcc.c-torture/execute/pr58831.c: New test.
--- /dev/null
+// PR c++/54812
+// { dg-do compile { target c++11 } }
+
+class A
+{
+ A() = default; // { dg-error "private" }
+};
+
+A a; // { dg-error "context" }
+
+class B
+{
+ ~B() = default; // { dg-error "private" }
+};
+
+B b; // { dg-error "context" }