[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Denemo-devel] Running Denemo from the tcl interpreter

From: Richard Shann
Subject: Re: [Denemo-devel] Running Denemo from the tcl interpreter
Date: Tue, 19 Aug 2008 09:31:14 +0100

On Tue, 2008-08-19 at 00:42 -0500, Jeremiah Benham wrote:
> The generate_source is to create the interface file like
> denemointerface.i or denemointerface.h correct?
yes (and to generate other things).
What generate_source.c is (at the abstract level) is a database of our
built-in commands, with a bit of access mechanism attached all in one
file. The data is the unmenued_commands[] array (plus a bit more I think
just embedded in loops of foreach duration??) and the access mechanism
is some printf statements and loops.
 It's just the cheapest way for a C programmer to store something which
they are sure they will want to output in various formats. A competent
awk, bash ... writer would do things differently, but I can only hold
one language in my head at any one time.
So until now it was generating menu_entries[] and callback functions,
and we will now want to use it to generate an interface to some
scripting language.
BTW you mentioned having got the tidy-up part done but getting a
compilation error? You will have hit the fact that the last entry in
menu_entries[] cannot have a trailing comma? You can put a dummy entry
at the end of the array and put the #include "entries.h" before it.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]