This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Overzealous implicit typename warning
- From: "Wimmer Andreas (IMPRO)" <andreas dot wimmer at joanneum dot at>
- To: gcc at gcc dot gnu dot org
- Date: Thu, 25 Apr 2002 17:44:16 +0200
- Subject: Overzealous implicit typename warning
- Reply-to: andreas dot wimmer at joanneum dot at
Hi,
I have been trying to compile some of my own code with one of the latest
snapshots of the gcc 3.1 branch (from 22.April) and encounterd some warnings
for using implicit typenames. According to the gnats database this problem
should have been fixed on 10.April since the corresponding PR 5507 has been
closed indicating that a fix has been checked in at 3.1 branch and mainline.
Still, I have the same warning an a slightly modified code snippet
//////////////////////////////////////
template<typename _CharT>
class __ctype_abstract_base
{
typedef _CharT char_type;
};
template<typename _CharT>
class ctype : public __ctype_abstract_base<_CharT>
{
void Test()
{
char_type tOther = 0;
}
};
/////////////////////////////////////////
.. > /usr/local/gcc3_branch/bin/g++ -v
Reading specs from
/usr/local/gcc3_branch/lib/gcc-lib/i686-pc-linux-gnu/3.1/specs
Configured with: /linux/software/gcc-20020422/configure
--prefix=/usr/local/gcc3_branch --enable-threads=posix --enable-shared
Thread model: posix
gcc version 3.1 20020422 (prerelease)
.. > /usr/local/gcc3_branch/bin/g++ -c -o test.o test.cc
test.cc: In member function `void ctype<_CharT>::Test()':
test.cc:13: warning: `typename ctype<_CharT>::char_type' is implicitly a
typename
test.cc:13: warning: implicit typename is deprecated, please see the
documentation for details
Regards,
Andreas