Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!mnetor!uunet!husc6!panda!teddy!jpn From: jpn@teddy.UUCP (John P. Nelson) Newsgroups: comp.sys.ibm.pc Subject: Re: ** Re: MSC 4.0 Large Model ** Original Posters problem solved!!! Message-ID: <4296@teddy.UUCP> Date: Mon, 24-Aug-87 12:34:07 EDT Article-I.D.: teddy.4296 Posted: Mon Aug 24 12:34:07 1987 Date-Received: Tue, 25-Aug-87 03:09:58 EDT References: <10400006@altger.UUCP> <72@cunixc.columbia.edu> <1014@bsu-cs.UUCP> <4291@teddy.UUCP> <283@axis.fr> Reply-To: jpn@teddy.UUCP (John P. Nelson) Followup-To: comp.lang.c Organization: GenRad, Inc., Concord, Mass. Lines: 26 >Kernighan and Ritchie introduced NULL (one assumes) for the simple >reason that pointers are not the same as interges (nor shorts, longs etc) >If you use NULL the correct value will always be used. assume: making an ASS out of U and ME. This is wrong. Please people, we have hashed this to death. For the last time, NULL is NOT somehow special, it is simply a #define that MUST be the same as zero. This is true in both K&R and ANSI C. Anyone who believes differently is MISINFORMED. This has been discussed to death in comp.lang.c also. As for K&R, this is what K&R says about NULL (re: an example function pair, alloc and free, section 5.4). NULL is quite clearly shown as having the value 0. I quote: C guarantees that no pointer that validly points at data will contain zero, so a return value of zero can be used to signal an abnormal event, in this case, no space. We write NULL instead of zero, however, to indicate more clearly that this is a special value for a pointer. So NULL is simply a #defined constant with the value 0, and it is used instead of the contant zero to make the meaning clear. That is ALL! It has NO SPECIAL SIGNIFICANCE beyond that! Let's move this discussion to /dev/null