[Coco] The Coco's first webserver, written in Basic09
Christian Lesage
hyperfrog at gmail.com
Thu Dec 31 01:16:22 EST 2009
Wayne Campbell wrote:
>
> The converter would be easy to write, yes. But Basic09 is not a script
> language like javascript. That code would have to be loaded into
> Basic09 to be run, and that is a waste of memory, and is slower than
> running packed procedures from the command line with RunB. It would be
> the same as running Visual Studio every time you created a c++ source
> file.
This is why I wrote "you compile the resulting PROCEDURE into bytecode,
and it becomes the active page that the server RUNs whenever it needs to
display it". What's wrong with that? I admit I haven't programmed in
BASIC09 for the last 20 years, so you certainly know a lot more than I
do about how it uses memory. But the manual says RUN "can also be used
to call a previously compiled (by the PACK command) procedure", so it
seems like a logical choice to me.
Besides, you can't make an omelet without breaking eggs. I think the
question is: "What would waste the most resources?" Writing an
interpreter within the interpreter, or using the one you already have?
More information about the Coco
mailing list