Article View: gnu.misc.discuss
Article #74753Re: using 0 instead of NULL
From: Warner Losh
Date: Wed, 06 Mar 1991 20:15
Date: Wed, 06 Mar 1991 20:15
11 lines
917 bytes
917 bytes
0 and NULL are the same thing. All C compilers are required to do the right thing when they see a 0 (or 0L). If your C compiler doesn't, then it is broken. There are very specific guarantees in K&R and in the standard that state that int *p = 0; is exactly the same as int *p=NULL. Warner -- Warner Losh imp@Solbourne.COM We sing about Beauty and we sing about Truth at $10,000 a show.
Technical Details
Message-ID:
<1991Mar6.201539.17401@Solbourne.COM>Path:
arc1-ca.pugleaf.net!gmdzi!unido!mcsun!uunet!stan!impReferences:
<27D16AC5.3952@maccs.dcss.mcmaster.ca>Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 1025b4,343b7ce3977dbb95 X-Google-Attributes: gid1025b4,public X-Google-ArrivalTime: 1991-03-07 04:20:10 PST Path: arc1-ca.pugleaf.net!gmdzi!unido!mcsun!uunet!stan!imp From: imp@Solbourne.COM (Warner Losh) Newsgroups: gnu.misc.discuss Subject: Re: using 0 instead of NULL Message-ID: <1991Mar6.201539.17401@Solbourne.COM> Date: 6 Mar 91 20:15:39 GMT References: <27D16AC5.3952@maccs.dcss.mcmaster.ca> Organization: Solbourne Computer, Inc., Longmont, CO Lines: 11