5
val of_typestruct : Type_struct.t -> [ `generic of Tagged.t t ]
8
module Make_input(Input:sig type t end)
9
(X:Type_generic.Computation with type 'a t = Input.t -> 'a)
10
: S with type 'a t = Input.t -> 'a
12
module Make_output(Output:sig type t end)
13
(X:Type_generic.Computation with type 'a t = 'a -> Output.t)
14
: S with type 'a t = 'a -> Output.t
17
(Builder:sig type 'a t val make : ('a -> Tagged.t) -> 'a t -> Tagged.t t end)
18
(X:Type_generic.Computation with type 'a t = 'a Builder.t)
19
: S with type 'a t = 'a X.t
22
(Builder:sig type 'a t val make : (Tagged.t -> 'a) -> 'a t -> Tagged.t t end)
23
(X:Type_generic.Computation with type 'a t = 'a Builder.t)
24
: S with type 'a t = 'a X.t
26
(* Advanced utilisation of [Make] *)
28
module type Adapter = sig
31
type 'a adapter = 'a t -> Tagged.t t
34
val int32 : int32 adapter
35
val int64 : int64 adapter
36
val nativeint : nativeint adapter
37
val char : char adapter
38
val bool : bool adapter
39
val string : string adapter
40
val float : float adapter
41
val unit : unit adapter
43
val option : Tagged.t option adapter
44
val list : Tagged.t list adapter
45
val array : Tagged.t array adapter
46
val ref_ : Tagged.t ref adapter
47
val lazy_t : Tagged.t lazy_t adapter
49
val tuple2 : (Tagged.t * Tagged.t) adapter
50
val tuple3 : (Tagged.t * Tagged.t * Tagged.t) adapter
51
val tuple4 : (Tagged.t * Tagged.t * Tagged.t * Tagged.t) adapter
52
val tuple5 : (Tagged.t * Tagged.t * Tagged.t * Tagged.t * Tagged.t) adapter
57
(X:Type_generic.Computation with type 'a t = 'a A.t)
58
: S with type 'a t = 'a X.t
60
module Input_adapter(Input:sig type t end) : Adapter with type 'a t = Input.t -> 'a
61
module Output_adapter(Output:sig type t end) : Adapter with type 'a t = 'a -> Output.t
62
module Reader_adapter(Builder:sig
64
val make : ('a -> Tagged.t) -> 'a t -> Tagged.t t
65
end) : Adapter with type 'a t = 'a Builder.t
66
module Writer_adapter(Builder:sig
68
val make : (Tagged.t -> 'a) -> 'a t -> Tagged.t t
69
end) : Adapter with type 'a t = 'a Builder.t