PR c++/71166
* g++.dg/cpp0x/constexpr-array18.C: New test.
From-SVN: r244450
+2017-01-13 Marek Polacek <polacek@redhat.com>
+
+ PR c++/71166
+ * g++.dg/cpp0x/constexpr-array18.C: New test.
+
2017-01-13 Janne Blomqvist <jb@gcc.gnu.org>
PR fortran/78534
--- /dev/null
+// PR c++/71166
+// { dg-do compile { target c++11 } }
+
+struct Foo { int value; };
+
+constexpr Foo MakeFoo() { return Foo{0}; }
+
+struct Bar {
+ Foo color = MakeFoo();
+};
+
+struct BarContainer {
+ Bar array[1];
+};
+
+Foo X ()
+{
+ return MakeFoo ();
+}
+
+void Foo() {
+ new BarContainer();
+}