[<<][staapl][>>][..]
Fri Jul 18 22:39:03 CEST 2008

Generating typed programs

Actually, generating a statically typed system in a dynamically typed
language isn't such a crazy idea. The type checking of the generated
program can happen at generator run time, at which also the generator
dynamic types are available.

However, what I am doing in Staapl is to generate the target program,
but to also compile it immediately. There is not really an
intermediate generated program representation other than the data
types exchanged between code processors. This data however could
really be representing code bodies for embedded languages.

In any case, static guarantees about the target program are really
dynamic checks of the data passed between code processors /
generators. At generator compile time, I can't check anything. But is
this really necessary? What is lost is the ability to typecheck
generator components. Only when they are instantiated, they can be
tested. Adding an explicit test suite for generators solves that
problem.



[Reply][About]
[<<][staapl][>>][..]