This is the mail archive of the
mailing list for the GCC project.
Re: [PATCH rs6000] (small C++ patch) Add intrinsics for the new vec_* specified by the C/C++ Language Extension for the CBEA
- From: Mark Mitchell <mark at codesourcery dot com>
- To: Andrew_Pinski at PlayStation dot Sony dot Com
- Cc: David Edelsohn <dje dot gcc at gmail dot com>, GCC Patches <gcc-patches at gcc dot gnu dot org>, Trevor_Smigiel at PlayStation dot Sony dot com
- Date: Wed, 01 Oct 2008 10:38:53 -0700
- Subject: Re: [PATCH rs6000] (small C++ patch) Add intrinsics for the new vec_* specified by the C/C++ Language Extension for the CBEA
- References: <OF7EF8AD3D.B76E6B40-ON882574D5.005EADCD-882574D5.005FDB23@playstation.sony.com>
> Mark Mitchell <email@example.com> wrote on 09/30/2008 07:59:33 PM:
>> Andrew Pinski wrote:
>>> I had to add some small support for C++ to support
>>> COMPOUND_LITERAL_EXPR to say it is a lvalue.
>>> * tree.c (lvalue_p_1): COMPOUND_LITERAL_EXPR is also an lvalue.
>> The C++ change is OK if compound literals are lvalues in C. I'm
>> slightly surprised that they are, but if so, it makes sense to treat
>> them the same way in C++.
> I wonder why you are surprised they are lvalues for C, they were designed
> (as I understand it) to provide an anonymous variable.
I just wasn't sure they were lvalues; there are situations where a
structure is not an lvalue. I guess you can just color me dumb.
Thanks for the reference; in that case, the C++ patch is OK.
(650) 331-3385 x713