But assuming you do manage to compile and install Oleg's library, here's how you'd use it in an OCaml session:
#require "delimcc";; (* loading Oleg's library this way requires the findlib package *)
+ (* if you don't have findlib, you'll need to start ocaml like
+ * this instead: ocaml -I /path/to/directory/containing/delimcc delimcc.cma
+ *)
open Delimcc;; (* this lets you say e.g. new_prompt instead of Delimcc.new_prompt *)
let p = new_prompt ();;
let prompt thunk = push_prompt p thunk;;
For more details, see:
* [Haskell wikibook on do-notation](http://en.wikibooks.org/wiki/Haskell/do_Notation)
+ * [Yet Another Haskell Tutorial on do-notation](http://en.wikibooks.org/wiki/Haskell/YAHT/Monads#Do_Notation)
* [Do-notation considered harmful](http://www.haskell.org/haskellwiki/Do_notation_considered_harmful)
* If you like the Haskell do-notation, there's [a library](http://www.cas.mcmaster.ca/~carette/pa_monad/) you can compile and install to let you use something similar in OCaml.