This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug c++/25908] [4.2 Regression] Multiple definitions of symbol vtables



------- 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


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]