This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [C++ PATCH, related to ObjC++ support] Don't treat enumeration vals as lvalues (PR c++/41131)


On Thu, Aug 20, 2009 at 3:01 PM, Jason Merrill<jason@redhat.com> wrote:
> On 08/20/2009 05:44 PM, Jakub Jelinek wrote:
>>
>> When Obj-C++ support was added, CONST_DECL handling has been added to
>> lvalue_p_1. ÂAs CONST_DECL are used in C++ land just for enumeration
>> values,
>> I assume it could be only because of objc_build_string_object which
>> creates
>> a CONST_DECL and creates ADDR_EXPR from it.
>
> What? ÂWhy is ObjC using CONST_DECL for that? ÂIt should be VAR_DECL, I'd
> think.

At one point it was a VAR_DECL but that caused issues from what I
remember.  The Fortran front-end uses CONST_DECL in a similar way as
the objective-C front-end does ...

-- Pinski


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]