mirror of
https://github.com/c-cube/iter.git
synced 2025-12-06 03:05:29 -05:00
prepare for 1.0
This commit is contained in:
parent
eb56b70417
commit
98aa228655
4 changed files with 15 additions and 15 deletions
|
|
@ -25,13 +25,13 @@ To get an overview of sequence, its origins and why it was created,
|
|||
you can start with http://cedeela.fr/~simon/talks/sequence.pdf[the slides of a talk]
|
||||
I (@c-cube) made at some OCaml meeting.
|
||||
|
||||
See https://c-cube.github.io/sequence/api/[the online API]
|
||||
See https://c-cube.github.io/sequence/[the online API]
|
||||
for more details on the set of available functions.
|
||||
|
||||
== Build
|
||||
|
||||
1. via opam `opam install sequence`
|
||||
2. manually (need OCaml >= 3.12): `make all install`
|
||||
2. manually (need OCaml >= 4.02.0): `make all install`
|
||||
|
||||
If you have https://github.com/vincent-hugot/iTeML[qtest] installed,
|
||||
you can build and run tests with
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
opam-version: "1.2"
|
||||
name: "sequence"
|
||||
version: "0.11"
|
||||
version: "1.0"
|
||||
author: "Simon Cruanes"
|
||||
maintainer: "simon.cruanes.2007@m4x.org"
|
||||
license: "BSD-2-clauses"
|
||||
|
|
|
|||
|
|
@ -37,7 +37,7 @@ type +'a t = ('a -> unit) -> unit
|
|||
type +'a sequence = 'a t
|
||||
|
||||
(** {b NOTE} Type [('a, 'b) t2 = ('a -> 'b -> unit) -> unit]
|
||||
has been removed and subsumed by [('a * 'b) t] @since NEXT_RELEASE *)
|
||||
has been removed and subsumed by [('a * 'b) t] @since 1.0 *)
|
||||
|
||||
type 'a equal = 'a -> 'a -> bool
|
||||
type 'a hash = 'a -> int
|
||||
|
|
@ -226,7 +226,7 @@ val filter_mapi : (int -> 'a -> 'b option) -> 'a t -> 'b t
|
|||
|
||||
val filter_count : ('a -> bool) -> 'a t -> int
|
||||
(** Count how many elements satisfy the given predicate
|
||||
@since NEXT_RELEASE *)
|
||||
@since 1.0 *)
|
||||
|
||||
val intersperse : 'a -> 'a t -> 'a t
|
||||
(** Insert the single element between every element of the sequence *)
|
||||
|
|
@ -234,15 +234,15 @@ val intersperse : 'a -> 'a t -> 'a t
|
|||
val keep_some : 'a option t -> 'a t
|
||||
(** [filter_some l] retains only elements of the form [Some x].
|
||||
Same as [filter_map (fun x->x)]
|
||||
@since NEXT_RELEASE *)
|
||||
@since 1.0 *)
|
||||
|
||||
val keep_ok : ('a, _) Result.result t -> 'a t
|
||||
(** [keep_ok l] retains only elements of the form [Ok x].
|
||||
@since NEXT_RELEASE *)
|
||||
@since 1.0 *)
|
||||
|
||||
val keep_error : (_, 'e) Result.result t -> 'e t
|
||||
(** [keep_error l] retains only elements of the form [Error x].
|
||||
@since NEXT_RELEASE *)
|
||||
@since 1.0 *)
|
||||
|
||||
(** {2 Caching} *)
|
||||
|
||||
|
|
@ -485,7 +485,7 @@ val rev : 'a t -> 'a t
|
|||
|
||||
val zip_i : 'a t -> (int * 'a) t
|
||||
(** Zip elements of the sequence with their index in the sequence.
|
||||
Changed type @since NEXT_RELEASE to just give a sequence of pairs *)
|
||||
Changed type @since 1.0 to just give a sequence of pairs *)
|
||||
|
||||
val fold2 : ('c -> 'a -> 'b -> 'c) -> 'c -> ('a * 'b) t -> 'c
|
||||
|
||||
|
|
|
|||
|
|
@ -15,7 +15,7 @@ type +'a t = ('a -> unit) -> unit
|
|||
type +'a sequence = 'a t
|
||||
|
||||
(** {b NOTE} Type [('a, 'b) t2 = ('a -> 'b -> unit) -> unit]
|
||||
has been removed and subsumed by [('a * 'b) t] @since NEXT_RELEASE *)
|
||||
has been removed and subsumed by [('a * 'b) t] @since 1.0 *)
|
||||
|
||||
type 'a equal = 'a -> 'a -> bool
|
||||
type 'a hash = 'a -> int
|
||||
|
|
@ -199,7 +199,7 @@ val seq_list_map : f:('a -> 'b t) -> 'a list -> 'b list t
|
|||
|
||||
val filter_count : f:('a -> bool) -> 'a t -> int
|
||||
(** Count how many elements satisfy the given predicate
|
||||
@since NEXT_RELEASE *)
|
||||
@since 1.0 *)
|
||||
|
||||
val intersperse : x:'a -> 'a t -> 'a t
|
||||
(** Insert the single element between every element of the sequence *)
|
||||
|
|
@ -207,15 +207,15 @@ val intersperse : x:'a -> 'a t -> 'a t
|
|||
val keep_some : 'a option t -> 'a t
|
||||
(** [filter_some l] retains only elements of the form [Some x].
|
||||
Same as [filter_map (fun x->x)]
|
||||
@since NEXT_RELEASE *)
|
||||
@since 1.0 *)
|
||||
|
||||
val keep_ok : ('a, _) Result.result t -> 'a t
|
||||
(** [keep_ok l] retains only elements of the form [Ok x].
|
||||
@since NEXT_RELEASE *)
|
||||
@since 1.0 *)
|
||||
|
||||
val keep_error : (_, 'e) Result.result t -> 'e t
|
||||
(** [keep_error l] retains only elements of the form [Error x].
|
||||
@since NEXT_RELEASE *)
|
||||
@since 1.0 *)
|
||||
|
||||
(** {2 Caching} *)
|
||||
|
||||
|
|
@ -457,7 +457,7 @@ val rev : 'a t -> 'a t
|
|||
|
||||
val zip_i : 'a t -> (int * 'a) t
|
||||
(** Zip elements of the sequence with their index in the sequence.
|
||||
Changed type @since NEXT_RELEASE to just give a sequence of pairs *)
|
||||
Changed type @since 1.0 to just give a sequence of pairs *)
|
||||
|
||||
val fold2 : f:('c -> 'a -> 'b -> 'c) -> init:'c -> ('a * 'b) t -> 'c
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue