projects
/
lambda.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
tree_monadize tweaks
[lambda.git]
/
code
/
tree_monadize.ml
diff --git
a/code/tree_monadize.ml
b/code/tree_monadize.ml
index
c751b36
..
08b8d69
100644
(file)
--- a/
code/tree_monadize.ml
+++ b/
code/tree_monadize.ml
@@
-184,7
+184,7
@@
module TreeCont = Tree_monadizer2(Continuation_monad);;
*)
*)
-let int_readerize : int -> int
reader
=
+let int_readerize : int -> int
Reader_monad.monad
=
fun (a : int) -> fun (env : int -> int) -> env a;;
(* int_readerize takes an int and returns a Reader monad that
fun (a : int) -> fun (env : int -> int) -> env a;;
(* int_readerize takes an int and returns a Reader monad that
@@
-202,7
+202,7
@@
TreeReader.monadize int_readerize t1 env;;
-let incrementer : int -> int
state
=
+let incrementer : int -> int
State_monad.monad
=
fun (a : int) -> fun s -> (a, s+1);;
(* incrementer takes an 'a and returns it wrapped in a
fun (a : int) -> fun s -> (a, s+1);;
(* incrementer takes an 'a and returns it wrapped in a
@@
-221,7
+221,7
@@
TreeList.monadize (fun i -> [ [i;i*i] ]) t1;;
(* do nothing *)
let initial_continuation = fun t -> t in
(* do nothing *)
let initial_continuation = fun t -> t in
-TreeCont.monadize
cont_
unit t1 initial_continuation;;
+TreeCont.monadize
Continuation_monad.
unit t1 initial_continuation;;
(* convert tree to list of leaves *)
let initial_continuation = fun t -> [] in
(* convert tree to list of leaves *)
let initial_continuation = fun t -> [] in