doc: inline the doc of CCShim*_ module in the doc

This commit is contained in:
Fardale 2021-11-12 17:34:06 +01:00
parent 57cb3446b3
commit a5822f7273
11 changed files with 34 additions and 25 deletions

View file

@ -15,6 +15,7 @@ type 'a printer = Format.formatter -> 'a -> unit
(** {2 Arrays} *) (** {2 Arrays} *)
include module type of CCShimsArray_ include module type of CCShimsArray_
(** @inline *)
val empty : 'a t val empty : 'a t
(** [empty] is the empty array, physically equal to [[||]]. *) (** [empty] is the empty array, physically equal to [[||]]. *)
@ -177,6 +178,12 @@ val random_choose : 'a t -> 'a random_gen
(** [random_choose a rs] randomly chooses an element of [a]. (** [random_choose a rs] randomly chooses an element of [a].
@raise Not_found if the array/slice is empty. *) @raise Not_found if the array/slice is empty. *)
(*val of_list_map : ('a -> 'b) -> 'a list -> 'b t/*)
(** [of_list_map f l] applies the function [f] to all the elements of the list [l]
and builds an array with the results returned by [f]. The result is equivalent to
[map f (Array.of_list l)].
@since NEXT_RELEASE *)
val to_string : ?sep:string -> ('a -> string) -> 'a array -> string val to_string : ?sep:string -> ('a -> string) -> 'a array -> string
(** [to_string ~sep item_to_string a] print [a] to a string using [sep] as a separator (** [to_string ~sep item_to_string a] print [a] to a string using [sep] as a separator
between elements of [a]. between elements of [a].
@ -294,7 +301,8 @@ module Infix : sig
@since 0.17 *) @since 0.17 *)
(** Let operators on OCaml >= 4.08.0, nothing otherwise (** Let operators on OCaml >= 4.08.0, nothing otherwise
@since 2.8 *) @since 2.8
@inline *)
include CCShimsMkLet_.S with type 'a t_let := 'a array include CCShimsMkLet_.S with type 'a t_let := 'a array
end end

View file

@ -15,6 +15,7 @@ type 'a printer = Format.formatter -> 'a -> unit
(** {2 Arrays} *) (** {2 Arrays} *)
include module type of CCShimsArrayLabels_ include module type of CCShimsArrayLabels_
(** @inline *)
val empty : 'a t val empty : 'a t
(** [empty] is the empty array, physically equal to [||]. *) (** [empty] is the empty array, physically equal to [||]. *)
@ -310,7 +311,8 @@ module Infix : sig
@since 0.17 *) @since 0.17 *)
(** Let operators on OCaml >= 4.08.0, nothing otherwise (** Let operators on OCaml >= 4.08.0, nothing otherwise
@since 2.8 *) @since 2.8
@inline *)
include CCShimsMkLet_.S with type 'a t_let := 'a array include CCShimsMkLet_.S with type 'a t_let := 'a array
end end

View file

@ -4,6 +4,7 @@
(** Basic operations on Functions *) (** Basic operations on Functions *)
include module type of CCShimsFun_ include module type of CCShimsFun_
(** @inline *)
val compose : ('a -> 'b) -> ('b -> 'c) -> 'a -> 'c val compose : ('a -> 'b) -> ('b -> 'c) -> 'a -> 'c
(** [compose f g x] is [g (f x)]. Composition. *) (** [compose f g x] is [g (f x)]. Composition. *)

View file

@ -4,6 +4,7 @@
(** Basic Int functions *) (** Basic Int functions *)
include module type of CCShimsInt_ include module type of CCShimsInt_
(** @inline *)
type t = int type t = int

View file

@ -926,15 +926,15 @@ module Infix : sig
@since 0.17 *) @since 0.17 *)
(** Let operators on OCaml >= 4.08.0, nothing otherwise (** Let operators on OCaml >= 4.08.0, nothing otherwise
@since 2.8 *) @since 2.8
@inline *)
include CCShimsMkLet_.S with type 'a t_let := 'a list include CCShimsMkLet_.S with type 'a t_let := 'a list
include CCShimsMkLetList_.S include CCShimsMkLetList_.S
(** @inline *)
end end
(** Let operators on OCaml >= 4.08.0, nothing otherwise include module type of Infix
@since 2.8 *)
include CCShimsMkLet_.S with type 'a t_let := 'a list
(** {2 IO} *) (** {2 IO} *)

View file

@ -903,15 +903,15 @@ module Infix : sig
@since 0.17 *) @since 0.17 *)
(** Let operators on OCaml >= 4.08.0, nothing otherwise (** Let operators on OCaml >= 4.08.0, nothing otherwise
@since 2.8 *) @since 2.8
@inline *)
include CCShimsMkLet_.S with type 'a t_let := 'a list include CCShimsMkLet_.S with type 'a t_let := 'a list
include CCShimsMkLetList_.S include CCShimsMkLetList_.S
(** @inline *)
end end
(** Let operators on OCaml >= 4.08.0, nothing otherwise include module type of Infix
@since 2.8 *)
include CCShimsMkLet_.S with type 'a t_let := 'a list
(** {2 IO} *) (** {2 IO} *)

View file

@ -187,15 +187,13 @@ module Infix : sig
(** [o1 <+> o2] is [o1] if [o1] is [Some _], [o2] if [o1] is [None]. *) (** [o1 <+> o2] is [o1] if [o1] is [Some _], [o2] if [o1] is [None]. *)
(** Let operators on OCaml >= 4.08.0, nothing otherwise (** Let operators on OCaml >= 4.08.0, nothing otherwise
@since 2.8 *) @since 2.8
@inline *)
include CCShimsMkLet_.S with type 'a t_let := 'a option include CCShimsMkLet_.S with type 'a t_let := 'a option
end end
include module type of Infix
(** Let operators on OCaml >= 4.08.0, nothing otherwise
@since 2.8 *)
include CCShimsMkLet_.S with type 'a t_let := 'a option
(** {2 Conversion and IO} *) (** {2 Conversion and IO} *)

View file

@ -644,7 +644,8 @@ module Infix : sig
@since 3.6 *) @since 3.6 *)
(** Let operators on OCaml >= 4.08.0, nothing otherwise (** Let operators on OCaml >= 4.08.0, nothing otherwise
@since 2.8 *) @since 2.8
@inline *)
include CCShimsMkLet_.S with type 'a t_let := 'a t include CCShimsMkLet_.S with type 'a t_let := 'a t
end end

View file

@ -151,7 +151,8 @@ val pure : 'a -> 'a t
val (<*>) : ('a -> 'b) t -> 'a t -> 'b t val (<*>) : ('a -> 'b) t -> 'a t -> 'b t
(** Let operators on OCaml >= 4.08.0, nothing otherwise (** Let operators on OCaml >= 4.08.0, nothing otherwise
@since 2.8 *) @since 2.8
@inline *)
include CCShimsMkLet_.S with type 'a t_let := 'a t include CCShimsMkLet_.S with type 'a t_let := 'a t
(** {4 Run a generator} *) (** {4 Run a generator} *)

View file

@ -191,17 +191,13 @@ module Infix : sig
over the error of [b] if both fail. *) over the error of [b] if both fail. *)
(** Let operators on OCaml >= 4.08.0, nothing otherwise (** Let operators on OCaml >= 4.08.0, nothing otherwise
@since 2.8 *) @since 2.8
@inline *)
include CCShimsMkLet_.S2 with type ('a,'e) t_let2 := ('a,'e) result include CCShimsMkLet_.S2 with type ('a,'e) t_let2 := ('a,'e) result
end end
include module type of Infix include module type of Infix
(** Let operators on OCaml >= 4.08.0, nothing otherwise
@since 2.8 *)
include CCShimsMkLet_.S2 with type ('a,'e) t_let2 := ('a,'e) result
(** {2 Collections} *) (** {2 Collections} *)
val flatten_l : ('a, 'err) t list -> ('a list, 'err) t val flatten_l : ('a, 'err) t list -> ('a list, 'err) t

View file

@ -384,5 +384,6 @@ val pp : ?pp_start:unit printer -> ?pp_stop:unit printer -> ?pp_sep:unit printer
(fun out -> Format.fprintf out ",@ "). *) (fun out -> Format.fprintf out ",@ "). *)
(** Let operators on OCaml >= 4.08.0, nothing otherwise (** Let operators on OCaml >= 4.08.0, nothing otherwise
@since 2.8 *) @since 2.8
@inline *)
include CCShimsMkLet_.S2 with type ('a,'e) t_let2 := ('a,'e) t include CCShimsMkLet_.S2 with type ('a,'e) t_let2 := ('a,'e) t