English version
Accueil     À propos     Téléchargement     Ressources     Contactez-nous    

Ce site est rarement mis à jour. Pour les informations les plus récentes, rendez-vous sur le nouveau site OCaml à l'adresse ocaml.org.

Browse thread
ML extension language
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: 1997-02-28 (11:28)
From: Lyn A Headley <laheadle@m...>
Subject: ML extension language
dear caml-list,

I'm hoping, as a bachelor's project for my computer science degree,
to implement an extension language which is a dialect of ML.  

If you aren't familiar with extension languages, an extension language
is meant for making applications customizable to a high degree.  The
usual procedure is that one writes the core of an application in C/C++
and then adds new primitive functions and types (created by the user)
to the extension language.  Then much of the coding for the
application is done in the extension language and many opportunities
are presented to the user to radically change the innards of the
application.  Emacs Lisp is probably the most famous extension
language, but there do exist languages which can be used with any
application, such as lua(http://www.inf.puc-rio.br/~roberto/lua.html),
and elk(http://www-rn.informatik.uni-bremen.de/software/elk/,
and (kind-of) python(http://www.python.org),
and tcl.

A main advantage of extension languages is that they enable a high
degree of portability, thereby facilitating the availability of (in
this case) functional programming tools.  More specifically, instead
of requiring the user to install an interpreter at their site to be
able to run their application, the application *is* an interpreter for
its own private language.

Another nice thing about ex langs is that they increase efficiency, by
allowing time-critical functions to be coded in a low-level, compiled 
language.  But the best thing is to allow for highly customizable

I realize that CAML already contains facilities for creating new
primitives in C, but the main difference is that in a caml program,
the main program is the interpreter for the caml virtual machine, whereas
in an extension language control resides in the application.

Do people see this as worthwhile project, and one that is fairly
different from existing facilities?  It is interesting that *all*
existing extension languages are weakly typed, and it would be neat to
see what a polymorphically typed one could offer.  Thus far, I plan
to use almost the entire caml-light runtime system, and write a different
compiler (in C) for a simpler, but (hopefully!) still powerful language.  

I just wanted to post this to see what comments could be heard from
the caml light community.

Lyn Headley