This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/54197] [4.7/4.8 regression] Lifetime of reference not properly extended
- From: "aaw at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Thu, 16 Aug 2012 18:44:01 +0000
- Subject: [Bug c++/54197] [4.7/4.8 regression] Lifetime of reference not properly extended
- Auto-submitted: auto-generated
- References: <bug-54197-4@http.gcc.gnu.org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54197
--- Comment #3 from Ollie Wild <aaw at gcc dot gnu.org> 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 <aaw@google.com>
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