Mail Archives: djgpp/2000/02/21/17:51:39
-hs- wrote:
> Why ? Simply because <stdlib.h> is missing, that implies that the default
> return type of malloc() is int (also the parameters).
That's wrong in C++, for C++ you *must* do a cast because void * -> char * isn't
allowed without a cast.
And yes, you could need to use malloc in C++, specially when you mix C and C++
code (libc is C).
SET
--
Salvador Eduardo Tropea (SET). (Electronics Engineer)
Visit my home page: http://welcome.to/SetSoft or
http://www.geocities.com/SiliconValley/Vista/6552/
Alternative e-mail: set-soft AT usa DOT net set AT computer DOT org
set AT ieee DOT org set-soft AT bigfoot DOT com
Address: Curapaligue 2124, Caseros, 3 de Febrero
Buenos Aires, (1678), ARGENTINA Phone: +(5411) 4759 0013
- Raw text -