Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!swrinde!zaphod.mps.ohio-state.edu!rpi!uupsi!ficc!peter From: peter@ficc.ferranti.com (Peter da Silva) Newsgroups: comp.std.c Subject: Re: gcc and NULL function pointers. Message-ID: Date: 24 Jun 91 18:04:09 GMT References: <9752@cognos.UUCP> <25572@well.sf.ca.us> Reply-To: peter@ficc.ferranti.com (Peter da Silva) Organization: Xenix Support, FICC Lines: 15 In article <25572@well.sf.ca.us> Jef Poskanzer writes: > Hey, I've got an idea: how about not using NULL? Using a 0 explicitly > cast to the appropriate pointer type works perfectly for all machines > and compilers. Furthermore, it makes the code more self-documenting > and maintainable, and less error-prone. Agreed 100%. For me, at least, I've never been talking about how one should write code. There is no question but that this is the best coding practice (for myself, I often use "nil(type)", defined as "((type)0)", which can't be easily abused). -- Peter da Silva; Ferranti International Controls Corporation; +1 713 274 5180; Sugar Land, TX 77487-5012; `-_-' "Have you hugged your wolf, today?"