Re: BASIC-to-Euphoria - some inquiries
- Posted by David Cuny <dcuny at LANSET.COM> Mar 18, 2002
- 379 views
Jeff wrote: > I'd be interested in hearing what you have to say about the revised > approach - or hearing that you _haven't_ abandoned ebasic, and > are on the verge of releasing an update. I've continued not to work on eBasic. I have written a BASIC interpreter called wxBasic, but it's coded in C, not Euphoria. Most BASIC functions can be emulated in Euphoria. If I recall, EBASIC.E contains quite a few of them. The bits that are more problematic are: - GOTO - GOSUB - pass by reference - FOR loops altering indexes Were I to do it again, I don't think I'd bother with a QBasic->Euphoria translator. There are just too many dissimilarities between the languages. It would be more sensible to write a virtual machine to run the QBasic code. Barring that, I'd grab the patched version of Euphoria, by Karl Bochert. It already supports GOTO and pass by reference. You can convert QBasic FOR loops to Euphoria while loops. For GOSUB, if you ask Karl nicely, he might add it to his version of Euphoria. In terms of doing this with an unpatched version of Euphoria: it can be done, but the results won't be what you wanted. -- David Cuny