This is the mail archive of the binutils@sources.redhat.com mailing list for the binutils 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: Get rid of underscore.c


On Thu, Sep 12, 2002 at 07:42:36PM +0100, Nick Clifton wrote:
> Hi Zack,
> 
> > > This has just broken binutils builds.  Binutils currently builds its own 
> > > copy of cxxfilt and now it has no main function.
> > 
> > My recommendation is to drop cxxfilt from binutils.  Patch appended.
> 
> Err that seems a little bit draconian to me.  Why shouldn't the
> binutils package provide a C++ demangler.  (Answer: because G++ now
> does so).  But why should G++ have its own demangler ?  Why not use
> the binutils one ?  (Possible answer: because the G++ guys want to
> control the demangler ?)

I think that only one of binutils and gcc should provide c++filt.
I put cxxfilt.c in gcc because that was convenient for the goal of the
patch I was developing at the time; also, the information about the
presence or absence of a leading underscore on symbols is readily
available in gcc, where in binutils you have to have a kludge with
config.bfd or else link c++filt against libbfd.

However, it is arguably more natural for it to be part of binutils,
and documentation for it exists in binutils but not in gcc.  I can
provide an alternate patch to that effect, if someone will suggest
what to do about the leading underscore issue.  (The whole point of
this exercise has been to get rid of underscore.c.)

It's worth pointing out that the meat of the demangler is in libiberty
and is therefore shared already.

zw


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