Self-Extension

From bootstrapping
Jump to: navigation, search

Self-Extension[edit]

To get good bootstrap leverage it's useful when a language implementation provides more than it uses. One technique to do this is Self-Extension.

The PL can implement only very spares functionality, including a way to add to itself. Then a bunch of new features can be loaded on boot.

Examples of Self-Extension:

  • forth immediate words: adds new syntax to forth.
  • lisp macro definitions: allows you to add new language constructs to lisp.
  • lisp reader: implement only a basic reader in the core, use it to read in and make use of a much more comprehensive lisp reader from then on (MES does this).

any more?