[Pkg-ocaml-maint-commits] [pgocaml] 02/06: Imported Upstream version 2.1

Stéphane Glondu glondu at moszumanska.debian.org
Wed Aug 6 09:59:42 UTC 2014


This is an automated email from the git hooks/post-receive script.

glondu pushed a commit to branch master
in repository pgocaml.

commit 371f62297d6ec62065ffde17f8745ced65d6d362
Author: Stephane Glondu <steph at glondu.net>
Date:   Wed Aug 6 10:51:55 2014 +0200

    Imported Upstream version 2.1
---
 CHANGELOG.txt       |  7 +++++++
 _oasis              |  2 +-
 setup.ml            |  6 +++---
 src/META            |  6 +++---
 src/PGOCaml_aux.ml  | 17 +++++++++++++++++
 src/PGOCaml_aux.mli |  9 +++++++++
 6 files changed, 40 insertions(+), 7 deletions(-)

diff --git a/CHANGELOG.txt b/CHANGELOG.txt
index c32b977..358915a 100644
--- a/CHANGELOG.txt
+++ b/CHANGELOG.txt
@@ -1,3 +1,10 @@
+Release 2.1
+===========
+
+* Dario Teixeira: add List.iteri and List.mapi for compatibility with
+  older versions of OCaml.
+
+
 Release 2.0
 ===========
 
diff --git a/_oasis b/_oasis
index 15fc1db..ed69d46 100644
--- a/_oasis
+++ b/_oasis
@@ -1,6 +1,6 @@
 OASISFormat:		0.3
 Name:			PG'OCaml
-Version:		2.0
+Version:		2.1
 Synopsis:		OCaml bindings for the PostgreSQL database
 Authors:		Richard W. M. Jones et al.
 Maintainers:		Dario Teixeira
diff --git a/setup.ml b/setup.ml
index c437f42..4851e5f 100644
--- a/setup.ml
+++ b/setup.ml
@@ -1,7 +1,7 @@
 (* setup.ml generated for the first time by OASIS v0.3.0~rc6 *)
 
 (* OASIS_START *)
-(* DO NOT EDIT (digest: 4b93f0c77411485ea5ec74d59b82c305) *)
+(* DO NOT EDIT (digest: f74db3e169dd9abe1ee5fa718712b010) *)
 (*
    Regenerated by OASIS v0.4.4
    Visit http://oasis.forge.ocamlcore.org for more information and
@@ -6850,7 +6850,7 @@ let setup_t =
           alpha_features = [];
           beta_features = [];
           name = "PG'OCaml";
-          version = "2.0";
+          version = "2.1";
           license =
             OASISLicense.DEP5License
               (OASISLicense.DEP5Unit
@@ -7212,7 +7212,7 @@ let setup_t =
        };
      oasis_fn = Some "_oasis";
      oasis_version = "0.4.4";
-     oasis_digest = Some "\202 at J\250\157\156\171\1447{T\005N\141w\220";
+     oasis_digest = Some "\251\024\216\184Z\220\235\232\225Z|!AS=9";
      oasis_exec = None;
      oasis_setup_args = [];
      setup_update = false
diff --git a/src/META b/src/META
index 1207ed0..9b388f7 100644
--- a/src/META
+++ b/src/META
@@ -1,6 +1,6 @@
 # OASIS_START
-# DO NOT EDIT (digest: 5cdc3126d1114390058bae37a6f6d641)
-version = "2.0"
+# DO NOT EDIT (digest: cb1509fc9b26fe21e7753dabd32b93d7)
+version = "2.1"
 description = "OCaml bindings for the PostgreSQL database"
 requires = "unix calendar csv pcre"
 archive(byte) = "pgocaml.cma"
@@ -9,7 +9,7 @@ archive(native) = "pgocaml.cmxa"
 archive(native, plugin) = "pgocaml.cmxs"
 exists_if = "pgocaml.cma"
 package "syntax" (
- version = "2.0"
+ version = "2.1"
  description = "Syntax extension for PG'OCaml"
  requires = "pgocaml camlp4"
  archive(syntax, preprocessor) = "pa_pgsql.cma"
diff --git a/src/PGOCaml_aux.ml b/src/PGOCaml_aux.ml
index 75ae155..b1507c1 100644
--- a/src/PGOCaml_aux.ml
+++ b/src/PGOCaml_aux.ml
@@ -50,3 +50,20 @@ struct
     | None -> None
 end
 
+module List =
+struct
+  include List
+
+  let iteri f xs =
+    let rec loop i = function
+      | [] -> ()
+      | hd :: tl -> f i hd; loop (i+1) tl in
+    loop 0 xs
+
+  let mapi f xs =
+    let rec loop i = function
+      | [] -> []
+      | hd :: tl -> let hd' = f i hd in hd' :: loop (i+1) tl in
+    loop 0 xs
+end
+
diff --git a/src/PGOCaml_aux.mli b/src/PGOCaml_aux.mli
index 2b265ba..f9e04ad 100644
--- a/src/PGOCaml_aux.mli
+++ b/src/PGOCaml_aux.mli
@@ -15,3 +15,12 @@ module Option :
     val map : ('a -> 'b) -> 'a option -> 'b option
   end
 
+
+module List :
+  sig
+    include module type of List
+
+    val iteri : (int -> 'a -> unit) -> 'a list -> unit
+    val mapi : (int -> 'a -> 'b) -> 'a list -> 'b list
+  end
+

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-ocaml-maint/packages/pgocaml.git



More information about the Pkg-ocaml-maint-commits mailing list