Mailinglist Archive: opensuse-programming (118 mails)
| < Previous | Next > |
Re: [suse-programming-e] Programming standards!
- From: Jerry Feldman <gaf@xxxxxxx>
- Date: Wed, 20 Apr 2005 08:16:35 -0400
- Message-id: <200504200816.35935.gaf@xxxxxxx>
On Tuesday 19 April 2005 7:39 pm, Philipp Thomas wrote:
> That's from the pre-ANSI days, when void and 'void *' didn't exist. The
> C standard defines NULL to be (void *)0.
Not entirely true:
"NULL which expands to an implementation-defined null pointer constant".
ISO/IEC 9899:1999
Also, the void keyword did exist, at least back in 1980 when I was working
on porting Xenix to a Raytheon machine. I believe that ANSI '89 defined the
(void *) type at the universal pointer.
The null pointer constant: "An integer constant expression with the value of
0, or such an expression cast to type void *".
In C, both K&R and ANSI, the integer 0 has a special consideration.
--
Jerry Feldman <gaf@xxxxxxx>
Boston Linux and Unix user group
http://www.blu.org PGP key id:C5061EA9
PGP Key fingerprint:053C 73EC 3AC1 5C44 3E14 9245 FB00 3ED5 C506 1EA9
> That's from the pre-ANSI days, when void and 'void *' didn't exist. The
> C standard defines NULL to be (void *)0.
Not entirely true:
"NULL which expands to an implementation-defined null pointer constant".
ISO/IEC 9899:1999
Also, the void keyword did exist, at least back in 1980 when I was working
on porting Xenix to a Raytheon machine. I believe that ANSI '89 defined the
(void *) type at the universal pointer.
The null pointer constant: "An integer constant expression with the value of
0, or such an expression cast to type void *".
In C, both K&R and ANSI, the integer 0 has a special consideration.
--
Jerry Feldman <gaf@xxxxxxx>
Boston Linux and Unix user group
http://www.blu.org PGP key id:C5061EA9
PGP Key fingerprint:053C 73EC 3AC1 5C44 3E14 9245 FB00 3ED5 C506 1EA9
| < Previous | Next > |