This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/35772] New: GCC allows defining pure virtual functions
- From: "yuriry at gmail dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 30 Mar 2008 22:17:43 -0000
- Subject: [Bug c++/35772] New: GCC allows defining pure virtual functions
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
GCC compiles the code below without any error:
//----------------------------------
class A {
protected:
virtual void foo() const = 0;
};
// Defining pure virtual functions should not be allowed.
void A::foo() const
{
}
//----------------------------------
--
Summary: GCC allows defining pure virtual functions
Product: gcc
Version: 4.1.3
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c++
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: yuriry at gmail dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35772