prepare for 0.20

This commit is contained in:
Simon Cruanes 2016-10-14 11:33:53 +02:00
parent 81ca239ccc
commit bc7967054f
9 changed files with 34 additions and 20 deletions

View file

@ -1,5 +1,19 @@
= Changelog
== 0.20
- bugfix in `CCArray.equal`
- fix `CCString.*_ascii`; add `CCChar.{upper,lower}case_ascii`
- add functions in `CCArray`: fold2,iter2,map2
- add `CCArray.rev`
- add `CCFloat.round`
- add `CCVector.append_gen`
- add `CCList.{head_opt,last_opt}`
- add `CCInt.{print_binary,to_string_binary}` + tests (thanks @gsg)
- more general types for `CCArray.{for_all2,exists2}`
- more general type for `CCResult.map_or`
== 0.19
- add regression test for #75

4
_oasis
View file

@ -1,6 +1,6 @@
OASISFormat: 0.4
Name: containers
Version: 0.19
Version: 0.20
Homepage: https://github.com/c-cube/ocaml-containers
Authors: Simon Cruanes
License: BSD-2-clause
@ -179,7 +179,7 @@ Executable run_qtest
containers.io, containers.advanced, containers.sexp,
containers.bigarray, containers.unix, containers.thread,
containers.data,
sequence, gen, unix, oUnit, qcheck
sequence, gen, unix, oUnit, qcheck
Test all
Command: ./run_qtest.native

View file

@ -97,24 +97,24 @@ module type S = sig
val for_all2 : ('a -> 'b -> bool) -> 'a t -> 'b t -> bool
(** Forall on pairs of arrays.
@raise Invalid_argument if they have distinct lengths
allow different types @since NEXT_RELEASE *)
allow different types @since 0.20 *)
val exists : ('a -> bool) -> 'a t -> bool
val exists2 : ('a -> 'b -> bool) -> 'a t -> 'b t -> bool
(** Exists on pairs of arrays.
@raise Invalid_argument if they have distinct lengths
allow different types @since NEXT_RELEASE *)
allow different types @since 0.20 *)
val fold2 : ('acc -> 'a -> 'b -> 'acc) -> 'acc -> 'a t -> 'b t -> 'acc
(** Fold on two arrays stepwise.
@raise Invalid_argument if they have distinct lengths
@since NEXT_RELEASE *)
@since 0.20 *)
val iter2 : ('a -> 'b -> unit) -> 'a t -> 'b t -> unit
(** Iterate on two arrays stepwise.
@raise Invalid_argument if they have distinct lengths
@since NEXT_RELEASE *)
@since 0.20 *)
val shuffle : 'a t -> unit
(** Shuffle randomly the array, in place *)

View file

@ -99,24 +99,24 @@ module type S = sig
val for_all2 : ('a -> 'b -> bool) -> 'a t -> 'b t -> bool
(** Forall on pairs of arrays.
@raise Invalid_argument if they have distinct lengths
allow different types @since NEXT_RELEASE *)
allow different types @since 0.20 *)
val exists : ('a -> bool) -> 'a t -> bool
val exists2 : ('a -> 'b -> bool) -> 'a t -> 'b t -> bool
(** Exists on pairs of arrays.
@raise Invalid_argument if they have distinct lengths
allow different types @since NEXT_RELEASE *)
allow different types @since 0.20 *)
val fold2 : ('acc -> 'a -> 'b -> 'acc) -> 'acc -> 'a t -> 'b t -> 'acc
(** Fold on two arrays stepwise.
@raise Invalid_argument if they have distinct lengths
@since NEXT_RELEASE *)
@since 0.20 *)
val iter2 : ('a -> 'b -> unit) -> 'a t -> 'b t -> unit
(** Iterate on two arrays stepwise.
@raise Invalid_argument if they have distinct lengths
@since NEXT_RELEASE *)
@since 0.20 *)
val shuffle : 'a t -> unit
(** Shuffle randomly the array, in place *)
@ -158,11 +158,11 @@ val map : ('a -> 'b) -> 'a t -> 'b t
val map2 : ('a -> 'b -> 'c) -> 'a t -> 'b t -> 'c t
(** Map on two arrays stepwise.
@raise Invalid_argument if they have distinct lengths
@since NEXT_RELEASE *)
@since 0.20 *)
val rev : 'a t -> 'a t
(** Copy + reverse in place
@since NEXT_RELEASE *)
@since 0.20 *)
val filter : ('a -> bool) -> 'a t -> 'a t
(** Filter elements out of the array. Only the elements satisfying

View file

@ -11,11 +11,11 @@ val compare : t -> t -> int
val lowercase_ascii : t -> t
(** See {!Char}
@since NEXT_RELEASE *)
@since 0.20 *)
val uppercase_ascii : t -> t
(** See {!Char}
@since NEXT_RELEASE *)
@since 0.20 *)
val pp : Buffer.t -> t -> unit
val print : Format.formatter -> t -> unit

View file

@ -60,7 +60,7 @@ val fsign : t -> t
val round : t -> t
(** [round f] returns the closest integer value, either above or below
@since NEXT_RELEASE *)
@since 0.20 *)
exception TrapNaN of string
val sign_exn : t -> int

View file

@ -42,10 +42,10 @@ val of_string : string -> t option
val print_binary : t formatter
(** prints as "0b00101010".
@since NEXT_RELEASE *)
@since 0.20 *)
val to_string_binary : t -> string
(** @since NEXT_RELEASE *)
(** @since 0.20 *)
val min : t -> t -> t
(** @since 0.17 *)

View file

@ -136,11 +136,11 @@ val last : int -> 'a t -> 'a t
val head_opt : 'a t -> 'a option
(** First element.
@since NEXT_RELEASE *)
@since 0.20 *)
val last_opt : 'a t -> 'a option
(** Last element.
@since NEXT_RELEASE *)
@since 0.20 *)
val find_pred : ('a -> bool) -> 'a t -> 'a option
(** [find_pred p l] finds the first element of [l] that satisfies [p],

View file

@ -86,7 +86,7 @@ val append_list : ('a, rw) t -> 'a list -> unit
val append_gen : ('a, rw) t -> 'a gen -> unit
(** Append content of generator
@since NEXT_RELEASE *)
@since 0.20 *)
val equal : 'a equal -> ('a,_) t equal