This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [patch] support for -fdump-ada-spec


On Thu, 6 May 2010, Arnaud Charlet wrote:

> > What I mean is convert the preprocessing token to a tree value the same
> > way the C front end does, then convert the tree to an appropriate Ada
> > representation.
> 
> Could you give some pointers to do that? Initially I said this sounded
> like lots of extra work, but if it's simple to do, why not. I'm in particular
> concerned that I'll need to add an expression converter (from C expressions
> to Ada expression), which is currently intentionally avoided, we only
> convert tree declarations, and no expressions.

See what c_lex_with_flags does.

I'm concerned about having multiple separate implementations of processing 
C tokens that make it unclear what should be updated when a new type of 
constant or string is added, and are liable to get out of sync.

-- 
Joseph S. Myers
joseph@codesourcery.com


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]