This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: warning with gcc 2.95.1
- To: Jean-Francois dot Morcillo at steria dot fr, jbuck at synopsys dot COM
- Subject: Re: warning with gcc 2.95.1
- From: Mike Stump <mrs at wrs dot com>
- Date: Wed, 18 Aug 1999 06:04:04 -0700 (PDT)
- Cc: gcc at gcc dot gnu dot org
> Date: Wed, 18 Aug 1999 14:37:35 +0200
> From: =?iso-8859-1?Q?Jean=2DFran=E7ois?= MORCILLO
> <Jean-Francois.Morcillo@steria.fr>
> the code look like this :
> void my_delete(void *adr)
> {
> //some stuff
> ...
> //free memory
> delete adr ;
> }
> in the C++ Programming Lanhuage Third edition, le the prototype for
> operator delete is the same....
Wrong type, please ask how to a program in C++ type questions on
comp.lang.c++.
Try delete new char; or _any_ other type but void, above you use void.
delete new void; is invalid.