aboutsummaryrefslogtreecommitdiff
path: root/lib/cMap.mli
diff options
context:
space:
mode:
authorppedrot2013-11-13 15:37:23 +0000
committerppedrot2013-11-13 15:37:23 +0000
commit2fff9290c2da7e815606673bd532a8755fe66dee (patch)
tree950420222cde691276cf466999cf1a7e4ee8a595 /lib/cMap.mli
parent5cea75bd0f028fcea20b7cb4a058202187f5ddcd (diff)
Adding an unsafe mapping function to maps.
git-svn-id: svn+ssh://scm.gforge.inria.fr/svn/coq/trunk@17085 85f007b7-540e-0410-9357-904b9bb8a0f7
Diffstat (limited to 'lib/cMap.mli')
-rw-r--r--lib/cMap.mli8
1 files changed, 8 insertions, 0 deletions
diff --git a/lib/cMap.mli b/lib/cMap.mli
index 6e5f3bcfdd..6b61782b05 100644
--- a/lib/cMap.mli
+++ b/lib/cMap.mli
@@ -39,6 +39,14 @@ sig
(** [bind f s] transform the set [x1; ...; xn] into [x1 := f x1; ...;
xn := f xn]. *)
+ module Unsafe :
+ sig
+ val map : (key -> 'a -> key * 'b) -> 'a t -> 'b t
+ (** As the usual [map], but also allows to modify the key of a binding.
+ It is required that the mapping function [f] preserves key equality,
+ i.e.: for all (k : key) (x : 'a), compare (fst (f k x)) k = 0. *)
+ end
+
end
module Make(M : Map.OrderedType) : ExtS with