This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/35630] New: function definition changes typedef meaning
- From: "tim at klingt dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 18 Mar 2008 23:01:46 -0000
- Subject: [Bug c++/35630] New: function definition changes typedef meaning
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
this code does not compile with g++-4.3 (4.1 and 4.2 are able to compile it):
template <typename T>
struct set
{};
struct derived:
public set<int>
{
typedef set<int> base;
void set(void) {}
};
tim@laptop:~$ g++-4.3 -v
Using built-in specs.
Target: i486-linux-gnu
Configured with: ../src/configure linux gnu
Thread model: posix
gcc version 4.3.0 20080301 (prerelease) [gcc-4_3-branch revision 132801]
(Debian 4.3.0~rc2-1)
tim@laptop:~$ g++-4.3 -c tst.cpp
tst.cpp:10: error: declaration of â??void derived::set()â??
tst.cpp:3: error: changes meaning of â??setâ?? from â??struct set<int>â??
--
Summary: function definition changes typedef meaning
Product: gcc
Version: unknown
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c++
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: tim at klingt dot org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35630