ebasic documentation?
Rayman
Posts: 14,665
The ebasic demo is kinda interesting. jazzed suggested using it as a performance benchmark.
So, I started looking closer at it...
There are some notes in the README.txt file. The code appears to be from David Betz with "all rights reserved".
David, did you write this from scratch?
Is there no GNU version of BASIC out there for GCC?
Does it really compile before running? Can you save the compiled version?
So, I started looking closer at it...
There are some notes in the README.txt file. The code appears to be from David Betz with "all rights reserved".
David, did you write this from scratch?
Is there no GNU version of BASIC out there for GCC?
Does it really compile before running? Can you save the compiled version?
Comments
Yes, I wrote ebasic. I'm not sure I can say I wrote it from scratch because every language I've written for the past 30 years has been based on bits and pieces of other earlier languages that I wrote. This one borrows from a text adventure authoring system I wrote ages ago called AdvSys.
There may be a GNU Basic out there somewhere. I'd be surprised if there isn't. It will almost certainy be far bigger though.
When running in xmm modes in SimpleIDE, the terminal window misses the first welcome prompt...
Only see it in SD or other slow modes...
Sorry, that will not happen.
The constructor is always called before main. It's a good place to turn off buffering and other customizations.
You can call it peanutbutterAndJellySandwitch() if you like.
It's still a very nice demo though. Also, might be a basis for implementing a LOGO interpreter in GCC...
But, don't all variables have global scope?
Try this:
It's in the readme. The readme isn't very easy on the eyes though. Someone should take time to make an html guide.
The readme is missing info about the line number editor. The line numbers for example are not "goto" or "gosub" line numbers. There is a "label: goto label" convention, and "gosub" is replaced by functions.
Also DIM is optional and variables can be more than one letter. It's not clear what the limits are and whether symbols can contain numbers and under-bars.
I'm trying to convince David that a version of ebasic (and/or xbasic) that could be split into smaller pieces might be useful. It could be split into an editor, compiler, and interpreter. All of it could be run from a monitor like Dave Hein's spinix (or some other loader). The xbasic version is very powerful in that among other things it can launch PASM cogs. Xbasic programs are also very small (maybe smaller than spin).
Do you think that has any value?
It may find a niche audience.
I'm mostly interested in it because it's big and needs xmm modes to run...
I don't think I'd actually build an application with it...
Rampage2 with the x driver is ~4X faster than C3 in xmmc and split modes.
So, I feel better about that now
BTW: ebasic doesn't work with C3 in xmm-single mode... Is that a bug?