pure virtual w/implementation bug in GCC 3.3?

lrtaylor@micron.com lrtaylor@micron.com
Fri Sep 19 18:46:00 GMT 2003


I was under the impression that virtual functions could not be inlined (seems I read that somewhere), because, especially in the case of polymorphism, which function to call cannot be determined at compile time.  I can see cases where the compiler _would_ know that it could be inlined, though.  It just seemed that that was a matter of policy in the standard.  Is my impression incorrect?

Thanks,
Lyle Taylor

-----Original Message-----
From: Eljay Love-Jensen [mailto:eljay@adobe.com]
Sent: Friday, September 19, 2003 11:33 AM
To: m.; gcc-help@gcc.gnu.org
Subject: Re: pure virtual w/implementation bug in GCC 3.3?

Hi m,

Thank you for the clarification.  :-)

10.4 paragraph 2 clearly shows that the construct is illegal.

I'll use the sanctioned form:
class Foo { public: virtual ~Foo() = 0; };
inline Foo::~Foo() { }

Sincerely,
--Eljay



More information about the Gcc-help mailing list