🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.std.c
Article #5788

Re: realloc

#5788
From: Tainter
Date: Thu, 30 Mar 1989 21:05
21 lines
1208 bytes
In article <9118@alice.UUCP> ark@alice.UUCP (Andrew Koenig) writes:
>Hm.  Here's what my draft ANSI C spec has to say about realloc:

>	void *realloc(void *ptr, size_t size);
>  If `ptr' is a null pointer, the
>realloc function behaves like the malloc function for the
>specified size...

>Of course, not all C implementations behave this way.

This just serves to remind us all that there is ONE and ONLY ONE good
use for the __ANSI define, put the following at the top of your files:

#ifndef __ANSI

This text should not compile and will produce errors.  This should show you
uou don't want to compile this anywhere but where __ANSI is defined.

#endif

--johnathan.a.tainter--
Technical Details
Message-ID: <10062@ihlpb.ATT.COM>
Path: arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!husc6!rutgers!att!ihlpb!tainter
References: <10170@bloom-beacon.MIT.EDU> <10032@ihlpb.ATT.COM> <9118@alice.UUCP>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!husc6!rutgers!att!ihlpb!tainter
From: tainter@ihlpb.ATT.COM (Tainter)
Newsgroups: comp.std.c,comp.lang.c
Subject: Re: realloc
Summary: ANSI drafts and other spine chilling things
Message-ID: <10062@ihlpb.ATT.COM>
Date: 30 Mar 89 21:05:45 GMT
References: <10170@bloom-beacon.MIT.EDU> <10032@ihlpb.ATT.COM> <9118@alice.UUCP>
Reply-To: tainter@ihlpb.UUCP (55521-Tainter,J.A.)
Organization: AT&T Bell Laboratories - Naperville, Illinois
Lines: 21