Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!csd4.milw.wisc.edu!uxc!deimos.cis.ksu.edu!rutgers!att!ulysses!andante!alice!ark From: ark@alice.UUCP (Andrew Koenig) Newsgroups: comp.lang.c++ Subject: Re: Legal initializer? Keywords: initialization initializer new Message-ID: <9293@alice.UUCP> Date: 3 May 89 21:10:41 GMT References: <161@mole-end.UUCP> Organization: AT&T Bell Laboratories, Liberty Corner NJ Lines: 22 In article <161@mole-end.UUCP>, mat@mole-end.UUCP (Mark A Terribile) asks about the legality of the following: class My_buf { public: const int size; char *const buffer; My_buf( int ); }; My_buf::My_buf( int sz ) : size( sz ), buffer( new char[ sz ] ) {} He points out that his version of cfront generates bad C code. Well, he's right -- it's a cfront bug. It'll work in 2.0. -- --Andrew Koenig ark@europa.att.com