Browse thread
[Caml-list] lisp to ocaml
[
Home
]
[ Index:
by date
|
by threads
]
[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
| Date: | -- (:) |
| From: | Jon Harrop <jon@f...> |
| Subject: | Re: [Caml-list] lisp to ocaml |
On Sunday 18 September 2005 02:08, Jonathan Roewen wrote: > Does anyone know of a tool that can convert lisp to ocaml (or > something other ML dialect)? I've tried googling and couldn't find > anything. Just all the parentheses gets a bit confusing for a first > look at lisp ;-) You could do a "straightforward" conversion by starting with a simple Lisp interpreter written in OCaml and partially specialising it over the Lisp program. However, if you find Lisp's brackets confusing then you're likely to find the enormous amount of boxing, unboxing and dynamic type checking that would result even more confusing. You could probably get rid of much of that but it would greatly complicate the translator. Interestingly, I just proposed writing a staged Scheme interpreter to Walid Taha, as a possible MetaOCaml example. If one existed then you could just look at the OCaml code that it generated. -- Dr Jon D Harrop, Flying Frog Consultancy Ltd. Objective CAML for Scientists http://www.ffconsultancy.com/products/ocaml_for_scientists