Forward declaration of enums

Mumit Khan khan@NanoTech.Wisc.EDU
Thu Apr 27 14:24:00 GMT 2000


On Thu, 27 Apr 2000, robin 'xer.xes' putters wrote:

> Okay, I don't know if this is a bug, but I can't forward declare any enums,

There is really no such thing as "forward declaration" for enumerated
types in C or C++ ISO standards (hence the respective language
definitions).
  
  /* This is NOT OK. */
  enum foo;
  enum foo { foo1 = 0 };

  /* This is OK however. */
  enum foo { foo1 = 0 };
  enum foo;

> it works in all other compilers I use.

Well, all those other compilers have implemented this as an extension
obviously.

In any case, this is not a Cygwin issue, and if you want to lobby to get
such an extension in gcc, you'll have to use GCC forums instead. See
http://gcc.gnu.org/

Regards,
Mumit



--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe@sourceware.cygnus.com



More information about the Cygwin mailing list