This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/19199] [3.3/3.4/4.0/4.1 Regression] Wrong warning about returning a reference to a temporary
- From: "mark at codesourcery dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 7 Mar 2005 04:19:15 -0000
- Subject: [Bug c++/19199] [3.3/3.4/4.0/4.1 Regression] Wrong warning about returning a reference to a temporary
- References: <20041230105911.19199.lars@trolltech.com>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Additional Comments From mark at codesourcery dot com 2005-03-07 04:19 -------
Subject: Re: [PR c++/19199] don't turn cond_expr lvalue into min_expr rvalue
(continued from PR c++/20280)
Alexandre Oliva wrote:
> On Mar 5, 2005, Mark Mitchell <mark@codesourcery.com> wrote:
>
>
>>Roger has objected to this change in the past. As I noted in the
>>audit trail for 19199, there's stuff in build_modify_expr to handle
>>MIN_EXPR/MAX_EXPR as lvalues
>
>
> Problem is, with the transformation performed by fold, it's no longer
> an lvalue, and forcing it back into an lvalue just because it looks
> like it should be one could break other programs.
Yes, I understand. You still need to take it up with Roger, though.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=19199