kwn@grn.umb.edu (Kenneth Newman) (10/12/89)
The following program run with version 1.35.0 on a Sun 3/140-M8
using Sun UNIX 4.2 Release 3.4 printed "E" not "D".
#include <stream.h>
class D {
public:
void f(){cout << "D\n";}
int y;
};
class E : public D{
public:
void f(){cout << "E\n";}
};
main(){
E w;
w.D::f();
}schmidt@glacier.ics.uci.edu (Doug Schmidt) (10/13/89)
In article <8910121640.AA12659@grn.umb.edu>, kwn@grn (Kenneth Newman) writes: > > The following program run with version 1.35.0 on a Sun 3/140-M8 >using Sun UNIX 4.2 Release 3.4 printed "E" not "D". >#include <stream.h> >class D { > public: > void f(){cout << "D\n";} > int y; >}; >class E : public D{ > public: > void f(){cout << "E\n";} >}; > >main(){ >E w; >w.D::f(); >} This appears to be fixed in the g++ 1.36 beta. Doug -- Master Swordsman speak of humility; | schmidt@ics.uci.edu (ARPA) Philosophers speak of truth; | office: (714) 856-4034 Saints and wisemen speak of the Tao of no doubt; The moon, sun, and sea speaks for itself. -- Hiroshi Hamada