Barry Gershenfeld wrote:
I am working on something that I think's a bit over my head, but I'm
persistent and computers are at least supposed to be logical, so I ought to
have a chance.
I have a complex web of #defines that are all interdependent and I want to
find out what they end up being set to. What I'm looking for is something
like a .message directive so that if the compiler compiles that line I can
print a message and know that's how it proceeded. Being spoiled (FORTH) I
feel I ought to be able to make the compiler talk while it's working. Silly
me, but anyway I'd settle for this ability to output messages. Yes I will
probably devise some trick by forcing an error but I'm looking for an actual
reliable simple intentionally-put-there-as-a-feature way.
It doesn't link so I can't do any run-time message tricks.
It's not my code so no need for lectures about that.
What would you do?
So, I'm not sure if gcc -i will get you what you need. It sounds like
you want something more interactive than that. Off the top of my head I
can think of Wave, which is a nice implementation of the C preprocessor
that can be accessed programatically in a fairly straightforward manner:
http://www.boost.org/libs/wave/index.html
--Chris
--
[email protected]
http://www.kernel-panic.org/cgi-bin/mailman/listinfo/kplug-lpsg