TRUE and FALSE

Rahul Dhesi dhesi%cirrusl at oliveb.ATC.olivetti.com
Tue Aug 28 14:22:31 AEST 1990


In <514 at demott.COM> kdq at demott.COM (Kevin D. Quitt) writes:

     TRUE and FALSE are used for assignment purposes only.  It makes
     the intent of the code more obvious.

When I find somebody who really, really, really wants to define TRUE
and FALSE, even somebody who uses them for assignment only, I recommend
the following defines instead:

     #define ZERO   0
     #define ONE    1

These are so much more clear than TRUE and FALSE, and if you use
them in a test, you know exactly what you're testing!
--
Rahul Dhesi <dhesi%cirrusl at oliveb.ATC.olivetti.com>
UUCP:  oliveb!cirrusl!dhesi



More information about the Comp.lang.c mailing list