64-bit NULL: a followup

M. Warner Losh imp at bsdimp.com
Fri Nov 28 22:43:35 PST 2003


In message: <20031129055619.GA48381 at dhcp01.pn.xcllnt.net>
            Marcel Moolenaar <marcel at xcllnt.net> writes:
: Ok, so what is better (void*)0 or 0L?

Short answer:
	Yes. "Is it quicker to Philadelphia or by bus?"

Longer answer:

Each definition helps to flush out certain kinds of bugs while
papering over other kinds of bugs.  It needs to be 0L for C++, but in
C either is fine.  I have traditionally had the opposite in my tree
than what the current FreeBSD definition is to catch the other kinds
of bugs that others don't see with the default definition.  Neither
one is clearly better or worse than the other in the general case.

Warner


More information about the freebsd-standards mailing list