binutils/libiberty patch for c++filt to demangle ObjC++ symbols
Dave MacLachlan
dmaclach@google.com
Fri Apr 20 00:02:00 GMT 2007
On Apr 13, 2007, at 10:17 , Andrew Pinski wrote:
> On 4/13/07, Dave MacLachlan <dmaclach@google.com> wrote:
>> This is a patch for c++filt so it can demangle ObjC++ symbols. Turns
>> out that if you have an Objective C++ file (.mm) with a static var
>> inside of a method it will get mangled in such a fashion that the
>> current c++filt can't unmangle it:
>>
>> @implementation Foo
>> + (void)bar:(id)sender {
>> static int baz = 1;
>> }
>> @end
>>
>> gets mangled to
>>
>> _ZZ11+[Foo bar:]E3baz
>
>
> Actually I think this is the way it gets mangled on Darwin, I think it
> gets mangled differently on any other target as the other targets
> actually mangle the message name instead of keeping it as "+[Foo
> bar:]".
>
> So you might want to double check what happens under Linux with the
> objective-C++ front-end also.
>
> Thanks,
> Andrew Pinski
Andrew...
You are 100% correct. Should I change the option then from ObjC++ to
AppleObjC++ or do we hope that they are going to be changing their
mangling to be C++ compliant?
Other options?
Cheers,
Dave
More information about the Binutils
mailing list