Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 10 Aug 2000 12:46:17 -0500 (CDT)
From:      David Scheidt <dscheidt@enteract.com>
To:        Anatoly Vorobey <mellon@pobox.com>
Cc:        "Thomas M. Sommers" <tms2@mail.ptd.net>, chat@freebsd.org
Subject:   Re: C time functions - problem
Message-ID:  <Pine.NEB.3.96.1000810124500.82980A-100000@shell-1.enteract.com>
In-Reply-To: <20000810191221.A12280@happy.checkpoint.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Thu, 10 Aug 2000, Anatoly Vorobey wrote:

:On Thu, Aug 10, 2000 at 01:30:44AM -0400, Thomas M. Sommers wrote:
:> 
:> "An integer constant expression with the value 0, or such an expression
:> cast to type void *, is called a null pointer constant. If a null
:> pointer constant is converted to a pointer type, the resulting pointer,
:> called a null pointer, is guaranteed to compare unequal to a pointer to
:> any object or function."
:> 
:> There are very few circumstances in which you need to cast 0 to make it
:> a null pointer constant.
:
:I am not aware of any such circumstances at all. 0 can always be used 
:instead of NULL, and, since I find it completely unambiguous, I always
:use 0 for null pointers.

This is only true on systems where 0 is not a valid address.  On such
systems, NULL pointers aren't equal to 0.

David



To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-chat" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.NEB.3.96.1000810124500.82980A-100000>