Message ID | 20111216163851.GZ1957@tyan-ft48-01.lab.bos.redhat.com |
---|---|
State | New |
Headers | show |
--- gcc/testsuite/g++.dg/opt/pr51575.C.jj 2011-12-16 17:31:45.407444733 +0100 +++ gcc/testsuite/g++.dg/opt/pr51575.C 2011-12-16 17:31:38.526484764 +0100 @@ -0,0 +1,21 @@ +// PR tree-optimization/51575 +// { dg-do compile } +// { dg-options "-O -fnon-call-exceptions" } + +#include <new> + +struct S +{ + S () + { + for (int i = 0; i < 3; ++i) + new (&a[i]) double (); + } + double a[4]; +}; + +void +foo () +{ + S s; +}