diff options
| author | Pierre-Marie Pédrot | 2014-03-05 20:14:51 +0100 |
|---|---|---|
| committer | Pierre-Marie Pédrot | 2014-03-05 20:15:04 +0100 |
| commit | 4e5747adfd7b5c83cac2c4bb242d85fd3cb6fdd0 (patch) | |
| tree | eb1bc399ecbdd9e147839492f5418e70695d2198 /lib/hMap.ml | |
| parent | 450628742c1c5ef5391b0a16acfc99ad23205094 (diff) | |
Fixing previous commit. Forgot to include some code.
Diffstat (limited to 'lib/hMap.ml')
| -rw-r--r-- | lib/hMap.ml | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/lib/hMap.ml b/lib/hMap.ml index cf5d0dfbcd..73cfbd0c71 100644 --- a/lib/hMap.ml +++ b/lib/hMap.ml @@ -258,6 +258,10 @@ struct let max_binding _ = assert false (** Cannot be implemented efficiently *) + let fold_left _ _ _ = assert false (** Cannot be implemented efficiently *) + + let fold_right _ _ _ = assert false (** Cannot be implemented efficiently *) + let choose s = let (_, m) = Int.Map.choose s in Map.choose m @@ -295,4 +299,19 @@ struct let m = Map.update k x m in Int.Map.update h m s + let smartmap f s = + let fs m = Map.smartmap f m in + Int.Map.smartmap fs s + + let smartmapi f s = + let fs m = Map.smartmapi f m in + Int.Map.smartmap fs s + + module Unsafe = + struct + let map f s = + let fs m = Map.Unsafe.map f m in + Int.Map.map fs s + end + end |
