Path: utzoo!utgpu!news-server.csri.toronto.edu!clyde.concordia.ca!uunet!decwrl!mips!pacbell.com!pacbell!att!dptg!ulysses!andante!alice!ark From: ark@alice.UUCP (Andrew Koenig) Newsgroups: comp.lang.c++ Subject: Re: Destructors and arrays Message-ID: <11139@alice.UUCP> Date: 4 Aug 90 00:36:41 GMT References: Distribution: comp Organization: AT&T Bell Laboratories, Liberty Corner NJ Lines: 23 In article , matthew@cs.ua.oz.au (Matthew Donaldson) writes: > Here is the code I used: > main() > { > X *Ar= new X[10]; > delete Ar; > } You should say X *Ar = new X[10]; delete[10] Ar; With cfront 2.1, you can say delete[] Ar; but the brackets are still essential. -- --Andrew Koenig ark@europa.att.com