@@ -1631,24 +1631,24 @@ let rec ins : type n. int -> n avl -> (n avl, n succ avl) sum =
16311631 | Leaf -> Inr (Node (Same, Leaf, x, Leaf))
16321632 | Node (bal, a, y, b) ->
16331633 if x = y then Inl t
1634- else if x < y then begin
1635- match ins x a with
1634+ else if x < y then
1635+ begin match ins x a with
16361636 | Inl a -> Inl (Node (bal, a, y, b))
16371637 | Inr a -> (
16381638 match bal with
16391639 | Less -> Inl (Node (Same, a, y, b))
16401640 | Same -> Inr (Node (More, a, y, b))
16411641 | More -> rotr a y b)
1642- end
1643- else begin
1644- match ins x b with
1642+ end
1643+ else
1644+ begin match ins x b with
16451645 | Inl b -> Inl (Node (bal, a, y, b) : n avl)
16461646 | Inr b -> (
16471647 match bal with
16481648 | More -> Inl (Node (Same, a, y, b) : n avl)
16491649 | Same -> Inr (Node (Less, a, y, b) : n succ avl)
16501650 | Less -> rotl a y b)
1651- end
1651+ end
16521652
16531653let insert x (Avl t) = match ins x t with Inl t -> Avl t | Inr t -> Avl t
16541654
@@ -1674,8 +1674,8 @@ let rec del : type n. int -> n avl -> n avl_del =
16741674 match t with
16751675 | Leaf -> Dsame Leaf
16761676 | Node (bal, l, x, r) ->
1677- if x = y then begin
1678- match r with
1677+ if x = y then
1678+ begin match r with
16791679 | Leaf ->
16801680 begin match bal with Same -> Ddecr (Eq, l) | More -> Ddecr (Eq, l)
16811681 end
@@ -1689,9 +1689,9 @@ let rec del : type n. int -> n avl -> n avl_del =
16891689 | Inl t -> Ddecr (Eq, t)
16901690 | Inr t -> Dsame t)
16911691 end
1692- end
1693- else if y < x then begin
1694- match del y l with
1692+ end
1693+ else if y < x then
1694+ begin match del y l with
16951695 | Dsame l -> Dsame (Node (bal, l, x, r))
16961696 | Ddecr (Eq, l) ->
16971697 begin match bal with
@@ -1702,9 +1702,9 @@ let rec del : type n. int -> n avl -> n avl_del =
17021702 | Inl t -> Ddecr (Eq, t)
17031703 | Inr t -> Dsame t)
17041704 end
1705- end
1706- else begin
1707- match del y r with
1705+ end
1706+ else
1707+ begin match del y r with
17081708 | Dsame r -> Dsame (Node (bal, l, x, r))
17091709 | Ddecr (Eq, r) ->
17101710 begin match bal with
@@ -1715,7 +1715,7 @@ let rec del : type n. int -> n avl -> n avl_del =
17151715 | Inl t -> Ddecr (Eq, t)
17161716 | Inr t -> Dsame t)
17171717 end
1718- end
1718+ end
17191719
17201720let delete x (Avl t) =
17211721 match del x t with Dsame t -> Avl t | Ddecr (_, t) -> Avl t
@@ -7077,13 +7077,13 @@ module Bootstrap
70777077 | BE.E -> raise Not_found
70787078 | BE.H (x, p) ->
70797079 if PrimH.isEmpty p then BE.E
7080- else begin
7081- match PrimH.findMin p with
7080+ else
7081+ begin match PrimH.findMin p with
70827082 | BE.H (y, p1) ->
70837083 let p2 = PrimH.deleteMin p in
70847084 BE.H (y, PrimH.merge p1 p2)
70857085 | BE.E -> assert false
7086- end
7086+ end
70877087end
70887088
70897089module LeftistHeap (Element : ORDERED) : HEAP with module Elem = Element =
0 commit comments