mirror of
https://github.com/c-cube/ocaml-containers.git
synced 2025-12-06 11:15:31 -05:00
Merge branch 'master' into stable for 2.0 alpha
This commit is contained in:
commit
3de5400579
14 changed files with 74 additions and 56 deletions
|
|
@ -1,6 +1,29 @@
|
|||
= Changelog
|
||||
|
||||
== 1.5.1
|
||||
== 2.0
|
||||
|
||||
=== breaking
|
||||
|
||||
- move to jbuilder (closes #165), requiring at least OCaml 4.02
|
||||
- become defensive w.r.t polymorphic operators:
|
||||
* Internally shadow polymorphic operators and functions from Pervasives
|
||||
by `include CCMonomorphic` in `Containers` module
|
||||
* Shadow the physical equality operator
|
||||
* Shadow polymorphic functions in `CCList`
|
||||
- rename `print` to `pp` for Format printers (closes #153)
|
||||
- remove `CCFlatHashtbl`
|
||||
|
||||
=== others
|
||||
|
||||
- many typos and style fixes (from Fourchaux)
|
||||
- Add `CCList.iteri2` and `CCList.foldi2`
|
||||
- remove `PARAM.min_size` in `CCPool`
|
||||
- Add `CCEqual.physical`
|
||||
- Avoid uses of the polymorphic operators
|
||||
- Add a `CCMonomorphic` module shipped into a `containers.monomorphic` library
|
||||
- make complexity of `Array.lookup` explicit (closes #174)
|
||||
|
||||
== 1.5.1, 1.5.2
|
||||
|
||||
- re-export `Format` types and functions in `CCFormat`
|
||||
|
||||
|
|
|
|||
32
HOWTO.adoc
32
HOWTO.adoc
|
|
@ -1,32 +0,0 @@
|
|||
= HOWTO
|
||||
|
||||
== Make a release
|
||||
|
||||
Beforehand, check `grep deprecated -r src` to see whether some functions
|
||||
can be removed.
|
||||
|
||||
. `make test`
|
||||
. update version in `_oasis`
|
||||
. `make update_next_tag` (to update `@since` comments; be careful not to change symlinks)
|
||||
. check status of modules (`{b status: foo}`) and update if required;
|
||||
removed deprecated functions, etc.
|
||||
. update `CHANGELOG.adoc` (see its end to find the right git command)
|
||||
. commit the changes
|
||||
. `git checkout stable`
|
||||
. `git merge master`
|
||||
. `oasis setup; make test doc`
|
||||
. update `opam` (the version field; remove `oasis` in deps)
|
||||
. tag, and push both to github
|
||||
. `opam pin add containers https://github.com/c-cube/ocaml-containers.git#<release>`
|
||||
. new opam package: `opam publish prepare; opam publish submit`
|
||||
. re-generate doc: `make doc push_doc`
|
||||
|
||||
== List Authors
|
||||
|
||||
`git log --format='%aN' | sort -u`
|
||||
|
||||
== Subtree
|
||||
|
||||
If gen is https://github.com/c-cube/gen.git[this remote]:
|
||||
|
||||
git subtree pull --prefix gen gen master --squash
|
||||
5
Makefile
5
Makefile
|
|
@ -1,3 +1,4 @@
|
|||
|
||||
all: build test
|
||||
|
||||
build:
|
||||
|
|
@ -24,8 +25,8 @@ VERSION=$(shell awk '/^version:/ {print $$2}' containers.opam)
|
|||
|
||||
update_next_tag:
|
||||
@echo "update version to $(VERSION)..."
|
||||
sed -i "s/NEXT_VERSION/$(VERSION)/g" src/*.ml src/*.mli
|
||||
sed -i "s/NEXT_RELEASE/$(VERSION)/g" src/*.ml src/*.mli
|
||||
sed -i "s/NEXT_VERSION/$(VERSION)/g" $(wildcard src/**/*.ml) $(wildcard src/**/*.mli)
|
||||
sed -i "s/NEXT_RELEASE/$(VERSION)/g" $(wildcard src/**/*.ml) $(wildcard src/**/*.mli)
|
||||
|
||||
watch:
|
||||
while find src/ benchs/ -print0 | xargs -0 inotifywait -e delete_self -e modify ; do \
|
||||
|
|
|
|||
26
README.adoc
26
README.adoc
|
|
@ -476,3 +476,29 @@ See link:doc/containers.adoc[the extended documentation] for more examples.
|
|||
|
||||
Powered by image:http://oasis.forge.ocamlcore.org/oasis-badge.png[alt="OASIS", style="border: none;", link="http://oasis.forge.ocamlcore.org/"]
|
||||
|
||||
== HOWTO (for contributors)
|
||||
|
||||
=== Make a release
|
||||
|
||||
Beforehand, check `grep deprecated -r src` to see whether some functions
|
||||
can be removed.
|
||||
|
||||
. `make test`
|
||||
. update version in `_oasis`
|
||||
. `make update_next_tag` (to update `@since` comments; be careful not to change symlinks)
|
||||
. check status of modules (`{b status: foo}`) and update if required;
|
||||
removed deprecated functions, etc.
|
||||
. update `CHANGELOG.adoc` (see its end to find the right git command)
|
||||
. commit the changes
|
||||
. `git checkout stable`
|
||||
. `git merge master`
|
||||
. `oasis setup; make test doc`
|
||||
. update `opam` (the version field; remove `oasis` in deps)
|
||||
. tag, and push both to github
|
||||
. `opam pin add containers https://github.com/c-cube/ocaml-containers.git#<release>`
|
||||
. new opam package: `opam publish prepare; opam publish submit`
|
||||
. re-generate doc: `make doc push_doc`
|
||||
|
||||
=== List Authors
|
||||
|
||||
`git log --format='%aN' | sort -u`
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
opam-version: "1.2"
|
||||
name: "containers"
|
||||
version: "2.0~alpha1"
|
||||
version: "2.0+alpha1"
|
||||
author: "Simon Cruanes"
|
||||
maintainer: "simon.cruanes.2007@m4x.org"
|
||||
build: [
|
||||
|
|
@ -35,5 +35,5 @@ These changes belong to 3 categories:
|
|||
- make most optional arguments relying on polymorphic operators mandatory
|
||||
- improve consistency of printers
|
||||
|
||||
changelog: https://github.com/c-cube/ocaml-containers/blob/2.0~alpha1/CHANGELOG.adoc"
|
||||
changelog: https://github.com/c-cube/ocaml-containers/blob/2.0+alpha1/CHANGELOG.adoc"
|
||||
]
|
||||
|
|
|
|||
|
|
@ -13,7 +13,7 @@ val poly : 'a t
|
|||
|
||||
val physical : 'a t
|
||||
(** Standard physical equality
|
||||
@since NEXT_RELEASE *)
|
||||
@since 2.0 *)
|
||||
|
||||
val int : int t
|
||||
val string : string t
|
||||
|
|
|
|||
|
|
@ -235,7 +235,7 @@ module type S = sig
|
|||
val pp : key printer -> 'a printer -> 'a t printer
|
||||
(** Printer for table
|
||||
@since 0.13
|
||||
Renamed from [print] @since NEXT_RELEASE *)
|
||||
Renamed from [print] @since 2.0 *)
|
||||
end
|
||||
|
||||
(*$inject
|
||||
|
|
|
|||
|
|
@ -105,7 +105,7 @@ module Poly : sig
|
|||
val pp : 'a printer -> 'b printer -> ('a, 'b) Hashtbl.t printer
|
||||
(** Printer for table
|
||||
@since 0.13
|
||||
Renamed from [print] @since NEXT_RELEASE *)
|
||||
Renamed from [print] @since 2.0 *)
|
||||
end
|
||||
|
||||
include module type of Poly
|
||||
|
|
@ -205,7 +205,7 @@ module type S = sig
|
|||
val pp : key printer -> 'a printer -> 'a t printer
|
||||
(** Printer for tables
|
||||
@since 0.13
|
||||
Renamed from {!print} @since NEXT_RELEASE *)
|
||||
Renamed from {!print} @since 2.0 *)
|
||||
end
|
||||
|
||||
module Make(X : Hashtbl.HashedType) :
|
||||
|
|
|
|||
|
|
@ -363,7 +363,7 @@ val iteri : (int -> 'a -> unit) -> 'a t -> unit
|
|||
|
||||
val iteri2 : (int -> 'a -> 'b -> unit) -> 'a t -> 'b t -> unit
|
||||
(** @raise Invalid_argument when lists do not have the same length.
|
||||
@since NEXT_RELEASE *)
|
||||
@since 2.0 *)
|
||||
|
||||
val foldi : ('b -> int -> 'a -> 'b) -> 'b -> 'a t -> 'b
|
||||
(** Fold on list, with index. *)
|
||||
|
|
@ -371,7 +371,7 @@ val foldi : ('b -> int -> 'a -> 'b) -> 'b -> 'a t -> 'b
|
|||
val foldi2 : ('c -> int -> 'a -> 'b -> 'c) -> 'c -> 'a t -> 'b t -> 'c
|
||||
(** Fold on two lists, with index.
|
||||
@raise Invalid_argument when lists do not have the same length.
|
||||
@since NEXT_RELEASE *)
|
||||
@since 2.0 *)
|
||||
|
||||
val get_at_idx : int -> 'a t -> 'a option
|
||||
(** Get by index in the list.
|
||||
|
|
@ -501,7 +501,7 @@ end
|
|||
|
||||
val assoc : eq:('a -> 'a -> bool) -> 'a -> ('a * 'b) t -> 'b
|
||||
(** Same as [Assoc.get_exn].
|
||||
@since NEXT_RELEASE *)
|
||||
@since 2.0 *)
|
||||
|
||||
val assoc_opt : eq:('a -> 'a -> bool) -> 'a -> ('a * 'b) t -> 'b option
|
||||
(** Same as [Assoc.get].
|
||||
|
|
@ -513,11 +513,11 @@ val assq_opt : 'a -> ('a * 'b) t -> 'b option
|
|||
|
||||
val mem_assoc : eq:('a -> 'a -> bool) -> 'a -> ('a * _) t -> bool
|
||||
(** Same as [Assoc.mem].
|
||||
@since NEXT_RELEASE *)
|
||||
@since 2.0 *)
|
||||
|
||||
val remove_assoc : eq:('a -> 'a -> bool) -> 'a -> ('a * 'b) t -> ('a * 'b) t
|
||||
(** Same as [Assoc.remove].
|
||||
@since NEXT_RELEASE *)
|
||||
@since 2.0 *)
|
||||
|
||||
(** {2 References on Lists}
|
||||
@since 0.3.3 *)
|
||||
|
|
|
|||
|
|
@ -374,23 +374,23 @@ end
|
|||
|
||||
val assoc : eq:('a -> 'a -> bool) -> 'a -> ('a * 'b) t -> 'b
|
||||
(** Same as [Assoc.get_exn].
|
||||
@since NEXT_RELEASE *)
|
||||
@since 2.0 *)
|
||||
|
||||
val assoc_opt : eq:('a -> 'a -> bool) -> 'a -> ('a * 'b) t -> 'b option
|
||||
(** Same as [Assoc.get].
|
||||
@since NEXT_RELEASE *)
|
||||
@since 2.0 *)
|
||||
|
||||
val assq_opt : 'a -> ('a * 'b) t -> 'b option
|
||||
(** Safe version of {!assq}.
|
||||
@since NEXT_RELEASE *)
|
||||
@since 2.0 *)
|
||||
|
||||
val mem_assoc : eq:('a -> 'a -> bool) -> 'a -> ('a * _) t -> bool
|
||||
(** Same as [Assoc.mem].
|
||||
@since NEXT_RELEASE *)
|
||||
@since 2.0 *)
|
||||
|
||||
val remove_assoc : eq:('a -> 'a -> bool) -> 'a -> ('a * 'b) t -> ('a * 'b) t
|
||||
(** Same as [Assoc.remove].
|
||||
@since NEXT_RELEASE *)
|
||||
@since 2.0 *)
|
||||
|
||||
(** {2 References on Lists}
|
||||
@since 0.3.3 *)
|
||||
|
|
|
|||
|
|
@ -43,12 +43,12 @@ module type S = sig
|
|||
|
||||
val pp_buf : Buffer.t -> t -> unit
|
||||
(** Renamed from [pp].
|
||||
@since NEXT_RELEASE *)
|
||||
@since 2.0 *)
|
||||
|
||||
val pp : Format.formatter -> t -> unit
|
||||
(** Print the string within quotes.
|
||||
Renamed from [print].
|
||||
@since NEXT_RELEASE *)
|
||||
@since 2.0 *)
|
||||
end
|
||||
|
||||
(** {2 Strings} *)
|
||||
|
|
|
|||
|
|
@ -140,7 +140,7 @@ module type S = sig
|
|||
|
||||
val pp : key printer -> 'a printer -> 'a t printer
|
||||
(** Renamed from [val print].
|
||||
@since NEXT_RELEASE *)
|
||||
@since 2.0 *)
|
||||
|
||||
val as_tree : 'a t -> [`L of int * (key * 'a) list | `N ] ktree
|
||||
(** For debugging purpose: explore the structure of the tree,
|
||||
|
|
|
|||
|
|
@ -128,7 +128,7 @@ module type S = sig
|
|||
|
||||
val pp : key printer -> 'a printer -> 'a t printer
|
||||
(** Renamed from [val print].
|
||||
@since NEXT_RELEASE *)
|
||||
@since 2.0 *)
|
||||
|
||||
(**/**)
|
||||
val node_ : key -> 'a -> 'a t -> 'a t -> 'a t
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
(* This file is free software, part of containers. See file "license" for more details. *)
|
||||
|
||||
(** {1 Shadow unsafe functions and operators from Pervasives} *)
|
||||
(** @since NEXT_RELEASE *)
|
||||
(** @since 2.0 *)
|
||||
|
||||
val (=) : int -> int -> bool
|
||||
val (<>) : int -> int -> bool
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue