module BatBounded:sig..end
This module implements values which must fall within given bounds.
Author(s): Hezekiah M. Carty
Since 2.0
type'abound_t =[ `c of 'a | `o of 'a | `u ]
`open or `closed or `unbounded boundstype('a, 'b)bounding_f =bounds:'a bound_t * 'a bound_t -> 'a -> 'b
boundsval bounding_of_ord : default_low:'b ->
default_high:'b ->
('a -> 'b) -> ('a -> 'a -> BatOrd.order) -> ('a, 'b) bounding_fbounding_of_ord ~default_low ~default_high conv ord will returning a
bounding function using ord for value comparison and default_low and
default_high for values which fall outside of the requested range.
conv is used to convert values which are in-range to the result type.val bounding_of_ord_chain : low:('a -> 'b) ->
high:('a -> 'b) ->
('a -> 'b) -> ('a -> 'a -> BatOrd.order) -> ('a, 'b) bounding_fbounding_oF_ord_chain ?low ?high ord is like BatBounded.bounding_of_ord except
that functions are used to handle out of range values rather than single
default values.val saturate_of_ord : bounds:'a bound_t * 'a bound_t ->
('a -> 'a -> BatOrd.order) -> 'a -> 'asaturate_of_ord ~bounds:(low, high) ord will returning a bounding
function using ord for value comparison and low and high for values
which fall outside of the requested range.val opt_of_ord : bounds:'a bound_t * 'a bound_t ->
('a -> 'a -> BatOrd.order) -> 'a -> 'a optionopt_of_ord ~bounds:(low, high) ord will returning a bounding function
using ord for value comparison and None for values which fall outside
of the requested range.module type BoundedType =sig..end
module type BoundedNumericType =sig..end
module type S =sig..end
module type NumericSig =sig..end
module Make:functor (M:BoundedType) ->Swith type base_u = M.base_twith type u = M.twith type t = private M.t
M
module MakeNumeric:functor (M:BoundedNumericType) ->NumericSigwith type base_u = M.base_twith type u = M.twith type t = private M.t