+2008-02-12 Jason Merrill <jason@redhat.com>
+
+ PR c++/34094
+ * decl2.c (cp_write_global_declarations): Don't write out static
+ data members with DECL_IN_AGGR_P set.
+
+ PR c++/33916
+ * Revert:
+ 2006-10-17 Mark Mitchell <mark@codesourcery.com>
+ PR c++/29039
+ * typeck2.c (build_functional_cast): Don't zero-initialize
+ non-PODs; instead, call their constructors.
+
2008-02-05 Richard Guenther <rguenther@suse.de>
Backport from mainline:
/* Static data members are just like namespace-scope globals. */
for (i = 0; VEC_iterate (tree, pending_statics, i, decl); ++i)
{
- if (var_finalized_p (decl) || DECL_REALLY_EXTERN (decl))
+ if (var_finalized_p (decl) || DECL_REALLY_EXTERN (decl)
+ /* Don't write it out if we haven't seen a definition. */
+ || DECL_IN_AGGR_P (decl))
continue;
import_export_decl (decl);
/* If this static data member is needed, provide it to the
if (parms && TREE_CHAIN (parms) == NULL_TREE)
return build_c_cast (type, TREE_VALUE (parms));
- /* We need to zero-initialize POD types. */
- if (parms == NULL_TREE
- && !CLASSTYPE_NON_POD_P (type)
+ /* We need to zero-initialize POD types. Let's do that for everything
+ that doesn't need a constructor. */
+ if (parms == NULL_TREE && !TYPE_NEEDS_CONSTRUCTING (type)
&& TYPE_HAS_DEFAULT_CONSTRUCTOR (type))
{
exp = build_zero_init (type,
+2008-02-12 Jason Merrill <jason@redhat.com>
+
+ * g++.dg/init/ctor8.C: Remove.
+
2008-02-06 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
* g++.dg/tree-ssa/ivopts-1.C: Remove xfails for hppa*-*-*.
+++ /dev/null
-// PR c++/29039
-
-typedef struct S { // { dg-error "reference" }
- int &r;
-};
-
-S f () {
- return S (); // { dg-error "synthesized" }
-}
-
-