(******************************************************************************)
(* This file contains several lemmas automated with canonical structures to   *)
(* verify programs with HTT                                                   *)
(******************************************************************************)


(*************************************************************************)
(* First, the mechanism for search-and-replace for the overloaded lemas, *)
(* pattern-matching on heap expressions.                                 *)
(*************************************************************************)

Structure tagged_heap := Tag {untag :> heap}.(******************************************************************************)
(* This file contains several lemmas automated with canonical structures to   *)
(* verify programs with HTT                                                   *)
(******************************************************************************)


(*************************************************************************)
(* First, the mechanism for search-and-replace for the overloaded lemas, *)
(* pattern-matching on heap expressions.                                 *)
(*************************************************************************)

Structure tagged_heap := Tag {untag :> heap}.(******************************************************************************)
(* This file contains several lemmas automated with canonical structures to   *)
(* verify programs with HTT                                                   *)
(******************************************************************************)


(*************************************************************************)
(* First, the mechanism for search-and-replace for the overloaded lemas, *)
(* pattern-matching on heap expressions.                                 *)
(*************************************************************************)

Structure tagged_heap := Tag {untag :> heap}.Definition right_tag := Tag.Definition left_tag := right_tag.Canonical Structure found_tag i := left_tag i.Structure update (k r : heap) :=
  Update {heap_of :> tagged_heap;
        _ : update_axiom k r heap_of}.Structure update (k r : heap) :=
  Update {heap_of :> tagged_heap;
        _ : update_axiom k r heap_of}.Structure update (k r : heap) :=
  Update {heap_of :> tagged_heap;
        _ : update_axiom k r heap_of}.

(* Specifications: *)
Lemma found_pf k : update_axiom k empty (found_tag k).