mirror of
https://github.com/c-cube/ocaml-containers.git
synced 2025-12-06 19:25:28 -05:00
fix in Puf.iter
This commit is contained in:
parent
ff956b9cc2
commit
814aaadab5
1 changed files with 4 additions and 3 deletions
|
|
@ -454,10 +454,11 @@ module Make(X : ID) : S with type elt = X.t = struct
|
||||||
|
|
||||||
let iter uf f =
|
let iter uf f =
|
||||||
PArray.iteri
|
PArray.iteri
|
||||||
(fun i e -> match e with
|
(fun i i' ->
|
||||||
|
if i = i' then match PArray.get uf.data i with
|
||||||
| None -> ()
|
| None -> ()
|
||||||
| Some d -> if d.next = i then f d.elt
|
| Some d -> f d.elt
|
||||||
) uf.data
|
) uf.parent
|
||||||
|
|
||||||
let inconsistent uf = uf.inconsistent
|
let inconsistent uf = uf.inconsistent
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue