home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!iphasew!igor!thor!rmartin
- From: rmartin@thor.Rational.COM (Bob Martin)
- Newsgroups: comp.lang.c++
- Subject: Re: Help on delete
- Message-ID: <rmartin.716170558@thor>
- Date: 11 Sep 92 00:15:58 GMT
- References: <etxolpn.716117347@beppe>
- Sender: news@Rational.COM
- Lines: 26
-
- etxolpn@beppe.ericsson.se (Ola Persson) writes:
-
- |Hello world!
-
- |Suppose
-
- | char *temp = new char[10];
-
- |will
- | delete temp;
-
- |do as freeing or is
-
- | delete []temp;
-
- |necessary ?
-
- If delete temp; works, it is not because the language allows it. The
- proper form is delete [] temp;.
-
-
- --
- Robert Martin Training courses offered in:
- R. C. M. Consulting Object Oriented Analysis
- 2080 Cranbrook Rd. Object Oriented Design
- Green Oaks, Il 60048 (708) 918-1004 C++
-