Source-Changes archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: CVS commit: src/sys/sys
David Laight wrote:
> > Modified Files:
> > src/sys/sys: null.h
> >
> > Log Message:
> > Define NULL as (void *)0, unless C++ is being used.
>
> I don't believe that is valid portable C.
> Although off hand I dont know the counter example.
C99 says:
The macros are
NULL
which expands to an implementation-defined null pointer
constant; and ...
> What about the comparison of function pointers?
gcc331 and lint are both happy with this.
> I just remember reading somewhere that the only valid
> definition for NULL is 0.
What Frank has done doesn't appear to be against any standards
that I can find...
Simon.
--
Simon Burge <simonb%wasabisystems.com@localhost>
NetBSD Support and Service: http://www.wasabisystems.com/
Home |
Main Index |
Thread Index |
Old Index