This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/25908] [4.2 Regression] Multiple definitions of symbol vtables
- From: "pinskia at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 24 Jan 2006 20:14:12 -0000
- Subject: [Bug c++/25908] [4.2 Regression] Multiple definitions of symbol vtables
- References: <bug-25908-7427@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #7 from pinskia at gcc dot gnu dot org 2006-01-24 20:14 -------
Reduced testcase:
file1.cc:
class f
{
virtual void g();
};
inline void f::g()
{}
int sub(void)
{}
file2.cc:
class f
{
virtual void g();
};
inline void f::g()
{}
int main(void)
{}
------
Now why does this work if I add inline to the method inside the declaration of
the class.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=25908