Definition Lsh  : Share.t := fst (Share.split Share.top).Definition Rsh  : Share.t := snd (Share.split Share.top).Definition splice (a b: t) : t := Share.lub (rel Lsh a) (rel Rsh b).

(* Specifications: *)
Lemma mkCanon_Leaf : forall b , mkCanon (Leaf b) = Leaf b.
Lemma mkCanon_double : forall t, mkCanon (mkCanon t) = mkCanon t.
Lemma mkCanon_split : forall t1 t2 t1' t2', mkCanon (Node t1 t2) = Node t1' t2' -> mkCanon t1 = t1' /\ mkCanon t2 = t2'.
Lemma mkCanon_Leaf_split : forall t1 t2 b, Leaf b = mkCanon (Node t1 t2) -> mkCanon t1 = Leaf b /\ mkCanon t2 = Leaf b.
Lemma mkCanon_union : forall t1 t2, mkCanon (union_tree (mkCanon t1) (mkCanon t2)) = mkCanon (union_tree t1 t2).
Lemma splice_rewrite: forall a b, splice a b = exist (fun t0 => canonicalTree t0) (mkCanon (Node (proj1_sig a) (proj1_sig b))) (mkCanon_correct _).
Lemma canonTree_check: forall x y, canonicalTree x -> canonicalTree y -> (exists b, x = Leaf b /\ y = Leaf b) \/ (canonicalTree (Node x y)).
Lemma unrel_splice_L: forall a b, unrel Lsh (splice a b) = a.
Lemma unrel_splice_R: forall a b, unrel Rsh (splice a b) = b.
Lemma contains_Lsh_e: forall sh, join_sub Lsh sh -> unrel Lsh sh = top.
Lemma contains_Rsh_e: forall sh, join_sub Rsh sh -> unrel Rsh sh = top.