Mail Archives: djgpp/1997/01/22/13:33:38
Alan Bostick wrote:
>
> have discovered, when compiling his examples, that djgpp chokes on the
> following construction:
> enum Boolean {false = 0, true};
It is not DJGPP but gcc which complains the above. The reason: 'false'
and
'true' are reserved words in gcc of the new type 'bool'. If you realy
want
to declare your own Boolean type, use any other (not reserved) words.
But I
think the better way is to use the 'bool' type, because it is stored as
a single byte but an 'enum' is stored (mostly) as an int (4 bytes).
Robert
--
*****************************************************************
* Robert Hoehne, Fakultaet fuer Mathematik, TU-Chemnitz-Zwickau *
* Post: Am Berg 3, D-09573 Dittmannsdorf *
* e-Mail: Robert DOT Hoehne AT Mathematik DOT TU-Chemnitz DOT DE *
* WWW: http://www.tu-chemnitz.de/~rho *
*****************************************************************
- Raw text -