This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: [c++] Another question about demangler output
On Sat, Dec 06, 2003 at 11:46:30PM -0500, Ian Lance Taylor wrote:
> Gabriel Dos Reis <gdr@integrable-solutions.net> writes:
>
> > Ian Lance Taylor <ian@wasabisystems.com> writes:
> >
> > | Gabriel Dos Reis <gdr@integrable-solutions.net> writes:
> > |
> > | > The point is this. "typeof" is a GNU/C++ extension. Its use in a
> > | > function declaration should be mangled differently from any standard
> > | > C++ construction. After all, the ABI has provided hook for vendor
> > | > extension.
> > |
> > | So you are arguing that this is a bug in g++.
> >
> > Yes.
> >
> > | I don't agree. To me it seems natural that typeof should simply be
> > | replaced by the resulting type when doing name mangling.
> >
> > Elsewhere, we seem to refrain from "folding". Which is what I
> > referred to in an earlier message as a schizophrenic position.
>
> g++ refrains from folding in expressions which appear as template
> arguments. I don't know whether that is right or wrong.
Personally, I think it's wrong. In fact, I think it's ludicrously
inconsistent, after the last week of trying to deal with it. But I
know very little about C++, so I assume there was some reason for doing
it this way. If someone has a pointer to the discussion/explanation....
--
Daniel Jacobowitz
MontaVista Software Debian GNU/Linux Developer