Re: C++ demangler fix

2013-09-11 Thread Jakub Jelinek
On Wed, Sep 11, 2013 at 01:49:46PM +0100, Gary Benson wrote: > Jakub Jelinek wrote: > > cp-demangle.c isn't used just in libiberty, where using hashtab, > > xcalloc, XNEW etc. is fine, but also in libsupc++/libstdc++, where > > none of that is fine. That is why cp-demangle.c only uses > > e.g. rea

Re: C++ demangler fix

2013-09-11 Thread Gary Benson
Jakub Jelinek wrote: > cp-demangle.c isn't used just in libiberty, where using hashtab, > xcalloc, XNEW etc. is fine, but also in libsupc++/libstdc++, where > none of that is fine. That is why cp-demangle.c only uses > e.g. realloc, checks for allocation failures and propagates those to > the call

Re: C++ demangler fix

2013-09-10 Thread Paolo Carlini
Hi, On 09/10/2013 05:34 PM, Jakub Jelinek wrote: On Wed, Sep 04, 2013 at 03:29:43PM +0100, Gary Benson wrote: I've added the result to the demangler test suite, but I know of no way to check the validity of the demangled symbol other than by inspection (and I am no expert here!) If anybody kno

Re: C++ demangler fix

2013-09-10 Thread Paolo Carlini
On 09/10/2013 08:38 PM, Jakub Jelinek wrote Agreed, can you please revert it? Sure, I'll do that momentarily. Paolo.

Re: C++ demangler fix

2013-09-10 Thread Jakub Jelinek
On Tue, Sep 10, 2013 at 08:36:02PM +0200, Paolo Carlini wrote: > On 09/10/2013 05:34 PM, Jakub Jelinek wrote: > >On Wed, Sep 04, 2013 at 03:29:43PM +0100, Gary Benson wrote: > >>I've added the result to the demangler test suite, but I know of > >>no way to check the validity of the demangled symbol

Re: C++ demangler fix

2013-09-10 Thread Jakub Jelinek
On Wed, Sep 04, 2013 at 03:29:43PM +0100, Gary Benson wrote: > I've added the result to the demangler test suite, but I know of > no way to check the validity of the demangled symbol other than by > inspection (and I am no expert here!) If anybody knows a way to > check this then please let me kno

Re: C++ demangler fix

2013-09-06 Thread Jason Merrill
OK, thanks. Jason

C++ demangler fix

2013-09-04 Thread Gary Benson
Hi all, d_print_comp maintains a certain amount of scope across calls (namely a stack of templates) which is used when evaluating references in template argument lists. If such a reference is later used from a subtitution then the scope in force at the time of the substitution is used. This appe