[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Octave and Guile?
Re: Octave and Guile?
15 Sep 2000 12:32:54 -0700
Gnus/5.0804 (Gnus v5.8.4) Emacs/20.4
>>>>> "jwe" == John W Eaton <address@hidden> writes:
jwe> On 14-Sep-2000, Daschbach, John L <address@hidden>
jwe> wrote: | 2.) Why rewrite the interpreter in guile? At least
jwe> to start it | would seem better to just add the ability to
jwe> evaluate scheme code in octave.
jwe> I'm not suggesting that Octave be rewritten in Guile.
jwe> Instead, I would modify Octave to emit Scheme code, and have
jwe> Guile interpret it.
Depending on semantics, that *is* rewriting the Octave interpreter in
Guile, except that your parser and lexer to go from Octave to scheme
would not have to be in scheme and you could use a stock guile repl.
I haven't worked through this, but it would seem that many of the
Octave syntactic notations could be difficult to rapidly parse into
efficient scheme code without further evaluation or knowledge of the
I could be wrong, but I thought the resolution of the translators
issue was that it was not a good idea to translate to another high
level language. Translating to byte code has it's merits however.
jwe> For maximum benefit to both Guile and
jwe> Octave, I think they need to be able to share all data.
jwe> Based on my understanding of how things work, it would be
jwe> easier to do this if there is really only one interpreter
jwe> running at a time, and it makes more sense for that
jwe> interpreter to be Guile instead of Octave. Guile users would
jwe> be able to call Octave functions and Octave users would be
jwe> able to call Guile procedures. Life would be good.
This is certainly true *if* your first part is done correctly. It's
this that causes some concern. Octave works very well now. I suspect
it will take a lot of work to get a perfect translation from Octave to
scheme, given that Octave has a fair amount of syntactic sugar.
It just seemed to me that if the Guile interpreter was an inferior of
the Octave interpeter that with a little bit of work you would embed
scheme in Octave and share data. This would be limited, since it
seems that the scheme expressions could only return values or modify
octave data passed to them.
Re: Octave and Guile?, Marius Vollmer, 2000/09/17
Re: Octave and Guile?, Matthew R Wette, 2000/09/14
RE: Octave and Guile?, John W. Eaton, 2000/09/15
Re: Octave and Guile?,
John Daschbach <=
Re: Octave and Guile?, Jost Boekemeier, 2000/09/16
- Re: Octave and Guile?, (continued)