Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!ames!haven!adm!smoke!gwyn From: gwyn@smoke.BRL.MIL (Doug Gwyn ) Newsgroups: comp.lang.c Subject: Re: use of NULL Keywords: NULL zero 0 C function prototype Message-ID: <9699@smoke.BRL.MIL> Date: 23 Feb 89 19:51:46 GMT References: <1167@unisec.usi.com. <5312@turnkey.TCC.COM. <9582@smoke.BRL.MIL. <399@twwells.uucp: <973@optilink.UUCP> <9684@smoke.BRL.MIL> <20928@shemp.CS.UCLA.EDU> Reply-To: gwyn@brl.arpa (Doug Gwyn (VLD/VMB) ) Organization: Ballistic Research Lab (BRL), APG, MD. Lines: 8 In article <20928@shemp.CS.UCLA.EDU> heather@SEAS.UCLA.EDU (Heather Burris) writes: >Why doesn't the C standard treat NULL or 0 (a static/constant NULL or 0, >i.e. indicated at compile time) passed to a function that has a pointer >value in the function prototype as a special case and do the cast implicitly? It does (actually it's not a special case), but most existing C code does not use prototypes, in which case the programmer has to explicitly cast the NULL argument to the proper type.