options for compiling C using C++ compiler [trying 1 more time]

John R x-list-subscriptions@hotmail.com
Thu Dec 15 07:31:00 GMT 2005


I'm working on a project where I post-process AST (.tu) output from gcc 
using the -fdump-translation-unit option.

Problem is the C compiler does not generate useful AST data. So I actually 
run the preprocessed source again thru g++ to get AST data. This works fine 
unless there are constructs not allowed under C++. Particular problems are 
bool and other keyword stuff and K&R style function declarations.

I'm trying to find the best way to minimize the problem via options or other 
ways. I already use "-fpermissive" and this eases it a bit.

Suggestions?

-J

_________________________________________________________________
Express yourself instantly with MSN Messenger! Download today - it's FREE! 
http://messenger.msn.click-url.com/go/onm00200471ave/direct/01/



More information about the Gcc mailing list