Patch: stdbool.h should be compatible with C++
Gabriel Dos_Reis
gdr@codesourcery.com
Fri Dec 31 16:38:00 GMT 1999
Martin Buchholz <martin@xemacs.org> writes:
[...]
| Alternatively, perhaps
|
| #include <stdbool.h>
|
| could be interpreted as asking for C semantics for true and false. So
| defining them to be 0 and 1 might be reasonable.
You mean something along the NULL magic?
#define true __true
#define false __false
and the compiler magically give the right meanings for __true and
__false.
I don't know how clean that solution is though, but it requires to
modify the parser.
-- Gaby
More information about the Gcc-patches
mailing list