This is the mail archive of the
gdb@sourceware.cygnus.com
mailing list for the GDB project.
Re: enum xyz;
- To: Stan Shebs <shebs@cygnus.com>
- Subject: Re: enum xyz;
- From: Andrew Cagney <ac131313@cygnus.com>
- Date: Wed, 11 Aug 1999 12:29:21 +1000
- CC: jtc@redback.com, gdb@sourceware.cygnus.com
- Organization: Cygnus Solutions
- References: <199908092157.OAA18400@andros.cygnus.com>
Stan Shebs wrote:
> We should probably lose the incomplete enum definitions in the
> sources, because they are a portability problem, the problem can be
> solved just by declaring affected functions after the enum's
> definition in value.h, and there aren't very many incomplete enum in
> the GDB sources.
Er, put that can opener down, that is a can of worms your trying to open
:-)
Incomplete enum's (like incomplete structs) are nice as they can help
you avoid some of that #include forest.
If there are really more than one or two such delcarations it might in
fact be better to conditionalize the code on CC_HAS_INCOMPLETE_ENUMS
(assuming autoconf gets a AC_CC_HAS_INCOMPLETE_ENUMS test :-). When not
defined, skip the relevant prototype.
Andrew