Oberon-2
17-Oct-95 16:34:46
Sb: #48493-Oberon-2
Fm: Peter Wade 100265,2740
To: Bart Van Bockstaele 100574,2352
I have never actually tried to write a compiler but I read about the tiny BASIC
interpreters that used to be popular on old 8 bit machines. They sound quite
simple but IMHO C sounds like a more difficuly language to compile. You have to
keep track of nested structures and variable scope which old fashioned basic
does not allow.
> The only hard part I had in BASIC were the dynamic-length strings
> something that doesn't exist in C.
BASIC's dynamic length strings were very convenient for the programmer but I
can see they would be difficult to implement. The old 8 bit Micosoft BASIC I
used to use could spend a minute or two every so often tidying up it's string
storage. It could be very embarasing, I had one program that always seemed to
hit this between the user pressing return to continue and the program printing
the message saying it was starting processing.
> I haven't used any debugger for years. I reverted to the patches I used
> in the good(?) old days and feel quite happy about it.
I have been spoilt by interactive debuggers. Its just so convenient to be able
to load the program into the debugger and not have to fiddle with the program
first.
Writing a compiler is one of those projects I have always intended to do and
probably will never get around to starting. A small Forth compiler probably
wouldn't be too hard and might even be useful. Ah well, put it in the queue
behind the Web browser that works and the Doom clone…
Peter Wade
Autopiloting from London, England