gcc version: gcc 3.4.0 tarball. system type: Red Hat Linux 9, x86. options given when building gcc: None. command line to trigger bug: g++ test.cc compiler output: gcc34test.cc: In constructor `B::B()': gcc34test.cc:25: error: `virtual void A::do_something()' is protected gcc34test.cc:32: error: within this context the preprocessed file (*.i*) that triggers the bug: Attached.
Created attachment 6308 [details] gcc34test.ii (preprocessed .cc file) test case
This is not a bug in 3.4.0 but a bug in previous versions of gcc and GCC should have rejected this. This is a dup of bug 11174. *** This bug has been marked as a duplicate of 11174 *** *** This bug has been marked as a duplicate of 11174 ***