From: Paolo Carlini Date: Mon, 4 Nov 2013 00:42:09 +0000 (+0000) Subject: re PR c++/52071 (Constructor invocation confused) X-Git-Tag: releases/gcc-4.9.0~3066 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=846276fae10922d24c9be666e264aa8058384de4;p=thirdparty%2Fgcc.git re PR c++/52071 (Constructor invocation confused) 2013-11-03 Paolo Carlini PR c++/52071 * g++.dg/parse/pr52071.C: New. From-SVN: r204343 --- diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index 09dc34363e31..19e5c3803fc7 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,8 @@ +2013-11-03 Paolo Carlini + + PR c++/52071 + * g++.dg/parse/pr52071.C: New. + 2013-11-03 Paolo Carlini PR c++/38313 diff --git a/gcc/testsuite/g++.dg/parse/pr52071.C b/gcc/testsuite/g++.dg/parse/pr52071.C new file mode 100644 index 000000000000..99456c0041a0 --- /dev/null +++ b/gcc/testsuite/g++.dg/parse/pr52071.C @@ -0,0 +1,23 @@ +// PR c++/52071 + +struct C1 { + C1(int); +}; + +struct C2 { + C2(); + C2(C1); +}; + +void f() +{ + int x; + int y = 1; + C2 vc; + + vc = C2(C1(x = y)); + + vc = (C2(C1(x = y))); + + vc = (C2(C1((0, x = y)))); +}