+2011-11-04 Olivier Goffart <olivier@woboq.com>
+ Jason Merrill <jason@redhat.com>
+
+ PR c++/50965
+ * class.c (check_field_decls): NSDMI makes a class non-aggregate.
+
2011-11-04 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/48420
no_const_asn_ref_p,
&any_default_members);
+ /* Now that we've removed bit-field widths from DECL_INITIAL,
+ anything left in DECL_INITIAL is an NSDMI that makes the class
+ non-aggregate. */
+ if (DECL_INITIAL (x))
+ CLASSTYPE_NON_AGGREGATE (t) = true;
+
/* If any field is const, the structure type is pseudo-const. */
if (CP_TYPE_CONST_P (type))
{
/* [dcl.init.aggr]
- An aggregate is an array or a class with no user-declared
- constructors, no private or protected non-static data members, no
+ An aggregate is an array or a class with no user-provided
+ constructors, no brace-or-equal-initializers for non-static data
+ members, no private or protected non-static data members, no
base classes, and no virtual functions.
As an extension, we also treat vectors as aggregates. Keep these
+2011-11-04 Olivier Goffart <olivier@woboq.com>
+
+ PR c++/50965
+ * g++.dg/cpp0x/nsdmi1.C: Add more cases.
+
2011-11-04 Jiangning Liu <jiangning.liu@arm.com>
PR rtl-optimization/38644
{
A a1;
if (a1.i != 42) return 1;
- A a2 = { 24 };
- if (a2.i != 24) return 2;
+ A a2{};
+ if (a2.i != 42) return 2;
A a3[1];
if (a3[0].i != 42) return 3;
C<int,3> c1;
if (c1.m != 3) return 5;
- C<int,3> c2 { 5 };
+ C<int,5> c2 {};
if (c2.m != 5) return 6;
D<int,3> d1;