Browse thread
[Caml-list] lisp -> 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: | Markus Mottl <mottl@m...> |
| Subject: | Re: [Caml-list] lisp -> ocaml |
On Tue, 22 May 2001, Miles Egan wrote: > Which fails to compile, for obvious reasons. Is the solution to > refactor the code into a nonrecursive form? In the absence of forward > declarations, I'm not sure what else to do. No, you have to explicitly express that the two functions are mutually recursive by using the "and" keyword as in, e.g.: let rec f () = g () and g () = f () Regards, Markus Mottl -- Markus Mottl, mottl@miss.wu-wien.ac.at, http://miss.wu-wien.ac.at/~mottl ------------------- To unsubscribe, mail caml-list-request@inria.fr. Archives: http://caml.inria.fr