Commit 4bbbcbf6 by Jason Merrill

re PR c++/53356 (ICE in verify_gimple_stmt, at tree-cfg.c:4258)

	PR c++/53356
	* tree.c (stabilize_init): Side effects make the init unstable.

From-SVN: r188019
parent e40a9680
2012-05-30 Jason Merrill <jason@redhat.com>
PR c++/53356
* tree.c (stabilize_init): Side effects make the init unstable.
2012-05-28 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/53503
......
......@@ -3458,7 +3458,7 @@ stabilize_init (tree init, tree *initp)
/* The initialization is being performed via a bitwise copy -- and
the item copied may have side effects. */
return TREE_SIDE_EFFECTS (init);
return !TREE_SIDE_EFFECTS (init);
}
/* Like "fold", but should be used whenever we might be processing the
......
2012-05-30 Jakub Jelinek <jakub@redhat.com>
PR c++/53356
* g++.dg/init/new33.C: New test.
2012-05-30 Richard Guenther <rguenther@suse.de>
PR middle-end/53501
......
// PR c++/53356
// { dg-do compile }
struct A {};
struct B { operator const A & () const; };
struct C { operator const A & () const; C (); };
struct D { operator const A & () const; D (); ~D (); };
A *foo () { return new A (B ()); }
A *bar () { return new A (C ()); }
A *baz () { return new A (D ()); }
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment