diff --git a/src/core/CCInt64.ml b/src/core/CCInt64.ml index 6ab45005..8bb45ead 100644 --- a/src/core/CCInt64.ml +++ b/src/core/CCInt64.ml @@ -2,8 +2,13 @@ include Int64 +[@@@iflt 4.13] + let min : t -> t -> t = Stdlib.min let max : t -> t -> t = Stdlib.max + +[@@@endif] + let sign i = compare i zero (* use FNV: diff --git a/src/core/CCInt64.mli b/src/core/CCInt64.mli index 94e32323..05055328 100644 --- a/src/core/CCInt64.mli +++ b/src/core/CCInt64.mli @@ -18,6 +18,8 @@ include module type of struct include Int64 end +[@@@iflt 4.13] + val min : t -> t -> t (** [min x y] returns the minimum of the two integers [x] and [y]. @since 3.0 *) @@ -26,10 +28,15 @@ val max : t -> t -> t (** [max x y] returns the maximum of the two integers [x] and [y]. @since 3.0 *) +[@@@endif] +[@@@iflt 5.1] + val hash : t -> int (** [hash x] computes the hash of [x], a non-negative integer. Uses FNV since 3.10 *) +[@@@endif] + val hash_to_int64 : t -> t (** Like {!hash} but does not truncate. Uses FNV.