Time to standardize "true" and "false"
Tom Neff
tneff at bfmny0.UU.NET
Wed Sep 27 00:40:53 AEST 1989
There is so much code that already thinks it has to - and can - define
what "boolean" is, that adding a reserved "boolean" type would probably
be greeted with more groans than cheers. Nor does much of this existing
code make any room for 1-bit implementations, from what I've seen.
I think that at MOST, "boolean," "TRUE" and "FALSE" should have the same
status as "NULL," i.e., some (new) standard header like <bool.h> should
define them if you bother to include it. And the guidance would suggest
saying
#define boolean int
#define TRUE 1
#define FALSE 0
although I have always smiled on clevernesses like
#define TRUE (1==1)
#define FALSE (1==0)
--
'The Nazis have no sense of humor, so why -| Tom Neff
should they want television?' -- Phil Dick |- tneff at bfmny0.UU.NET
More information about the Comp.lang.c
mailing list