This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: typedef vs. typename confusion
- To: egcs at cygnus dot com
- Subject: Re: typedef vs. typename confusion
- From: Gerald Pfeifer <pfeifer at dbai dot tuwien dot ac dot at>
- Date: Thu, 13 Aug 1998 22:54:07 +0200 (MET DST)
- cc: Joe Buck <jbuck at synopsys dot com>, Gabriel Dos Reis <Gabriel dot Dos-Reis at dptmaths dot ens-cachan dot fr>
On Tue, 4 Aug 1998, Joe Buck wrote:
> That is, whereever the compiler is in effect inserting "typename" (or,
> to be more correct, where the compiler is assuming that a name refers
> to a type, even though by the strict ISO C++ rules it should not), it
> should issue a warning. This warning should have its own flag but be
> turned on by -Wall.
I strongly second this!
Current practice is that every three months or so, suddenly some code of
ours stops compiling after I have installed a new egcs snapshot, exactly
because of "typename" issues. (And yes, we compile with -ansi -pedantic.)
So I really would like to see behavior similiar to what happened when
the new scoping semantics for for(;;) loops was introduced -- not just
automatic correction but also warnings whenever that happens.
Gerald
--
Gerald Pfeifer (Jerry) Vienna University of Technology
pfeifer@dbai.tuwien.ac.at http://www.dbai.tuwien.ac.at/~pfeifer/