Archives
D Programming
DD.gnu digitalmars.D digitalmars.D.bugs digitalmars.D.dtl digitalmars.D.dwt digitalmars.D.announce digitalmars.D.learn digitalmars.D.debugger C/C++ Programming
c++c++.announce c++.atl c++.beta c++.chat c++.command-line c++.dos c++.dos.16-bits c++.dos.32-bits c++.idde c++.mfc c++.rtl c++.stl c++.stl.hp c++.stl.port c++.stl.sgi c++.stlsoft c++.windows c++.windows.16-bits c++.windows.32-bits c++.wxwindows digitalmars.empire digitalmars.DMDScript |
c++ - Access Bug...
#include <stdio.h> class X { public : virtual void Print (); }; class Y : public X { private : typedef X super; public : void Print (); }; class Z : public Y { //private : // typedef Y super; public : void Print (); }; void X :: Print () { putchar ( 'X' ); } void Y :: Print () { super :: Print (); putchar ( 'Y' ); } void Z :: Print () { super :: Print (); // 'super' is 'Y :: super' and should be INACCESIBLE!!! putchar ( 'Z' ); } int main ( int, char **, char ** ) { Z z; z.Print (); return ( 0 ); } -- ManiaC++ Jan Knepper But as for me and my household, we shall use Mozilla... www.mozilla.org Jul 15 2004
|