[Bug c++/54197] [4.7/4.8 regression] Lifetime of reference not properly extended
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54197 Ollie Wild changed: What|Removed |Added Status|ASSIGNED|RESOLVED Resolution||FIXED --- Comment #7 from Ollie Wild 2012-08-31 17:24:07 UTC --- Fixed for 4.7.2+.
[Bug c++/54197] [4.7/4.8 regression] Lifetime of reference not properly extended
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54197 --- Comment #6 from Ollie Wild 2012-08-31 17:16:47 UTC --- Author: aaw Date: Fri Aug 31 17:16:39 2012 New Revision: 190839 URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=190839 Log: Backport from mainline 2012-08-31 Ollie Wild PR c++/54197 * gcc/cp/call.c (extend_ref_init_temps_1): Handle COMPOUND_EXPR trees. * gcc/testsuite/g++.dg/init/lifetime3.C: New test. Added: branches/gcc-4_7-branch/gcc/testsuite/g++.dg/init/lifetime3.C Modified: branches/gcc-4_7-branch/gcc/cp/ChangeLog branches/gcc-4_7-branch/gcc/cp/call.c branches/gcc-4_7-branch/gcc/testsuite/ChangeLog
[Bug c++/54197] [4.7/4.8 regression] Lifetime of reference not properly extended
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54197 --- Comment #5 from Ollie Wild 2012-08-31 15:47:37 UTC --- Author: aaw Date: Fri Aug 31 15:47:29 2012 New Revision: 190834 URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=190834 Log: 2012-08-31 Ollie Wild PR c++/54197 * gcc/cp/call.c (extend_ref_init_temps_1): Handle COMPOUND_EXPR trees. * gcc/testsuite/g++.dg/init/lifetime3.C: New test. Added: trunk/gcc/testsuite/g++.dg/init/lifetime3.C Modified: trunk/gcc/cp/ChangeLog trunk/gcc/cp/call.c trunk/gcc/testsuite/ChangeLog
[Bug c++/54197] [4.7/4.8 regression] Lifetime of reference not properly extended
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54197 --- Comment #4 from Ollie Wild 2012-08-16 18:46:42 UTC --- Fix submitted to the google/gcc-4_7 branch. Still waiting on maintainer approval for the trunk and gcc-4_7-branches.
[Bug c++/54197] [4.7/4.8 regression] Lifetime of reference not properly extended
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54197 --- Comment #3 from Ollie Wild 2012-08-16 18:44:01 UTC --- Author: aaw Date: Thu Aug 16 18:43:52 2012 New Revision: 190450 URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=190450 Log: Fix some cases where lifetimes of temporaries bound to expressions are not properly extended (Google ref b/6946758). 2012-08-16 Ollie Wild PR c++/54197 * gcc/cp/call.c (extend_ref_init_temps_1): Handle COMPOUND_EXPR trees. * gcc/testsuite/g++.dg/init/lifetime3.C: New test. Added: branches/google/gcc-4_7/gcc/testsuite/g++.dg/init/lifetime3.C Modified: branches/google/gcc-4_7/gcc/cp/ChangeLog.google-4_7 branches/google/gcc-4_7/gcc/cp/call.c branches/google/gcc-4_7/gcc/testsuite/ChangeLog.google-4_7
[Bug c++/54197] [4.7/4.8 regression] Lifetime of reference not properly extended
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54197 Jonathan Wakely changed: What|Removed |Added Status|NEW |ASSIGNED
[Bug c++/54197] [4.7/4.8 regression] Lifetime of reference not properly extended
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54197 Ollie Wild changed: What|Removed |Added CC||aaw at gcc dot gnu.org AssignedTo|unassigned at gcc dot |aaw at gcc dot gnu.org |gnu.org | --- Comment #2 from Ollie Wild 2012-08-13 18:04:21 UTC --- The issue is that these cause a COMPOUND_EXPR to be passed to extend_ref_init_temps_1. I have a patch which replaces the second operand of the COMPOUND_EXPR with another call to extend_ref_init_temps_1. Testing now. Will send out for review shortly.
[Bug c++/54197] [4.7/4.8 regression] Lifetime of reference not properly extended
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54197 Richard Guenther changed: What|Removed |Added Target Milestone|--- |4.7.2
[Bug c++/54197] [4.7/4.8 regression] Lifetime of reference not properly extended
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54197 H.J. Lu changed: What|Removed |Added Status|UNCONFIRMED |NEW Last reconfirmed||2012-08-07 CC||jason at redhat dot com Ever Confirmed|0 |1 --- Comment #1 from H.J. Lu 2012-08-07 19:55:37 UTC --- It is caused by revision 180944: http://gcc.gnu.org/ml/gcc-cvs/2011-11/msg00230.html