home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.lang.c++
- Path: sparky!uunet!mcsun!sunic!ugle.unit.no!alkymi.unit.no!robert
- From: robert@alkymi.unit.no (Robert Schmidt)
- Subject: Is (p) instead of (p!=NULL) portable?
- Message-ID: <1993Jan25.125627.29030@ugle.unit.no>
- Sender: news@ugle.unit.no (NetNews Administrator)
- Organization: Norwegian Institute of Technology
- Date: Mon, 25 Jan 93 12:56:27 GMT
- Lines: 11
-
-
- In PC C's, the NULL pointer is defined with a bit pattern of all zero's,
- and the constructs
- if (p)
- and
- if (!p)
- checks for NULL and non-NULL respectively. Is this portable to *all*
- platforms?
-
-
- Robert
-