On 24 Jan 1995, Johnathan Taylor wrote:

> This DPL compiler of yours.... How much like compiling stuff under C is it?
> It could be useful for equiping the sam-nativ'ish mode with the many standard
> utils whose only other options would be to either crawl along in a BASIC port
> or be written in machine code which is a bit of a pain IMHO

Okay. DPL is a Pascal-type language, but tweaked slightly to make it more
suitable for an event-driven environment like Driver. The current version
(of the compiler) contains facilities for procedures/functions, type
checking, a minimum number of constructs (a DO [WHILE]..[EXIT]..LOOP
[UNTIL], a IF..[ELSEIF]..[ELSEIF etc]..[ELSE]..ENDIF), a BLOCK..END and a
standard set of built-in procedures/functions for interfacing with 
Driver, converting between types etc. 

It compiles code using the new Driver v2 protocol (which basically means 
that it runs in lomem with a block of interface code added by the OS at 
the bottom, allowing hooks into Driver to be written very consisely as 
RSTs).

It's nice to use, too (IMHO), although at the moment you're limited to the 
standard INT (0-65535), REAL, BOOL and STRING types, and there is no way 
of creating your own. I want to add array support before distributing it.

I've been playing with it over Xmas, and I managed to get some 
interesting (although practically useless) results from it; it copes well 
with recursive and mutually-recursive functions and string manipulation 
(I spent ages perfecting the garbage collection).

As for using it to create standard utilties for the native C compiler... 
I doubt it. Well, certainly not right now, mainly because the DPL 
compiler (and the language) are both designed for using Driver.

Steve.

Reply via email to