This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: gengtype and typedef to enum
- From: Gabriel Dos Reis <gdr at integrable-solutions dot net>
- To: Mike Stump <mrs at apple dot com>
- Cc: Geoff Keating <geoffk at geoffk dot org>, gcc at gcc dot gnu dot org
- Date: 20 Mar 2003 00:15:40 +0100
- Subject: Re: gengtype and typedef to enum
- Organization: Integrable Solutions
- References: <4AC55BF9-5A5F-11D7-B09F-003065A77310@apple.com>
Mike Stump <mrs at apple dot com> writes:
| On Wednesday, March 19, 2003, at 02:43 PM, Gabriel Dos Reis wrote:
| > I discovered by the hard way (2 hours chasing the "problem") that the
| > gengtype machinery does not recognize typedef to enums.
|
| > Is this a feature?
|
| No. It isn't a feature. Think of it this way, imagine you had a
| really good C parser, but that you couldn't reuse any of it to write
| complex transformational style code, but rather, had to re-implement a
| new C parser from scratch and you did it, uhm, what's the right word,
| expediently.
|
| One is safer using a very limited subset of C for such things.
I can understand that view. What surprised me (and also the reason I
did not suspect -- in the first place -- gengtype not recognizing
typedefs to enums) is that gengtype can resolve typedefs to structs or
unions...
Thanks.
-- Gaby