let rec bind (u : 'a tree) (f : 'a -> 'b tree) : 'b tree =
match u with
- | Leaf a -> (fun b -> b) (f a) (* see below *)
+ | Leaf a -> f a;;
| Node (l, r) -> (fun l' r' -> Node (l', r')) (bind l f) (bind r f);;
(* monadic operations for the TreeT monadic transformer *)
+ (* NOTE THIS IS NOT YET WORKING --- STILL REFINING *)
type ('a, M) treeT =
'a tree M;;