This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: Demangling broken (was: Re: [PATCH] Demangler woes with currentCVS and type names)
- From: Jason Merrill <jason at redhat dot com>
- To: Phil Edwards <phil at jaj dot com>
- Cc: "H . J . Lu" <hjl at lucon dot org>,Andrew Cagney <ac131313 at cygnus dot com>,Hans-Peter Nilsson <hans-peter dot nilsson at axis dot com>,gcc-patches at gcc dot gnu dot org, binutils at sources dot redhat dot com
- Date: Fri, 01 Feb 2002 22:55:06 +0000
- Subject: Re: Demangling broken (was: Re: [PATCH] Demangler woes with currentCVS and type names)
- References: <20020131123141.A10866@disaster.basement.lan><200201311828.TAA12642@ignucius.axis.se><20020131163600.A11943@disaster.basement.lan><20020131182231.A5727@nevyn.them.org><20020131185227.A12592@disaster.basement.lan><20020131162415.A26740@lucon.org> <3C59E20A.7000100@cygnus.com><20020131165555.A27351@lucon.org><wvladut7zil.fsf@prospero.cambridge.redhat.com><20020201164949.B17061@disaster.basement.lan>
>>>>> "Phil" == Phil Edwards <phil@jaj.com> writes:
> On Fri, Feb 01, 2002 at 07:50:10PM +0000, Jason Merrill wrote:
>> >>>>> "H" == H J Lu <hjl@lucon.org> writes:
>>
>> > (main): Set cplus_demangle_v3_p to cplus_demangle_v3_type for
>> > gnu_v3_demangling:
>>
>> Not OK. This will wreak the same havoc that Phil's original change did,
>> just only with -s gnu-v3. The type-handling behavior should be limited to
>> command line arguments, it should never be active in filter mode.
> What if HJ's patch were to turn on type demangling by default only when
> the standalone c++filt were being built, and leave the current semantics
> stand for the library? (Is that what you're saying?)
No. I'm saying that it's OK for 'c++filt d' to say 'double', because
giving a name on the command line makes it explicit that we think it's a
mangled name, so it's appropriate to try hard to demangle it.
However, 'echo d|c++filt' should always say 'd', or you get very strange
results from trying to read assembly output with c++filt.
With HJ's patch, 'echo d|c++filt -s gnu-v3' would say 'double', which is
undesirable.
Jason