Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP
Posting-Version: version B 2.10.1a 12/4/83; site rlgvax.UUCP
Path: utzoo!watmath!clyde!floyd!harpo!seismo!rlgvax!guy
From: guy@rlgvax.UUCP (Guy Harris)
Newsgroups: net.unix-wizards
Subject: Re: NULL vs 0
Message-ID: <1650@rlgvax.UUCP>
Date: Fri, 3-Feb-84 16:04:16 EST
Article-I.D.: rlgvax.1650
Posted: Fri Feb  3 16:04:16 1984
Date-Received: Thu, 9-Feb-84 06:43:03 EST
References: <126@exodus.UUCP> <464@dalcs.UUCP>
Organization: CCI Office Systems Group, Reston, VA
Lines: 17

> The problem here is with the C `bible' and with the C compilers.  NULL
> should NOT be defined in the `stdio.h' package as this assumes (de facto)
> that there is a common interpretation.  If a generic NULL is to be
> recognized it *has* to be done by the compiler, NOT the preprocessor.  Only
> the compiler has the info (if it does) to correctly interpret the `current'
> meaning of NULL.  The idea that NULL could be something simple, like 0,
> doesn't work as we have seen over the weeks.  If there is to be a generic
> NULL pointer it MUST be known to the compiler.

Unfortunately, the only way the compiler could know the proper type to
case 0/NULL to would be if there was a way to declare the types of the arguments
that a function expects; however, there is no such provision in the C
language at present.  It is being considered by the ANSI C language standard
committee.

	Guy Harris
	{seismo,ihnp4,allegra}!rlgvax!guy