Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!tut.cis.ohio-state.edu!EROS.BERKELEY.EDU!whitcomb From: whitcomb@EROS.BERKELEY.EDU (Gregg Whitcomb) Newsgroups: gnu.g++.bug Subject: g++ 1.34.1 bug Message-ID: <8903290158.AA20749@eros.berkeley.edu> Date: 29 Mar 89 01:58:35 GMT Sender: daemon@tut.cis.ohio-state.edu Distribution: gnu Organization: GNUs Not Usenet Lines: 51 version: 1.34.1 example: #include "stream.h" class c; class xx; class b { int y; int x; b(int j, int i = 9) {y = j; x = i;} void print() {cout << x << "\n";} friend xx; }; class c : public b { c(int i = 1) : (5,i) {} void print() { b::print(); } friend void m(); }; void m() { c a; a.print(); c* e; e = new c(); e->print(); } main() { m(); } % g++ -g testinit.cc % a.out 0 0 ------------------- if class b was a friend of class c, this program works correctly. As is, an error or warning should be generated but is not.