(** External function specifications and linking *)
Structure external_specification (M E Z : Type) :=
{ ext_spec_type : E -> Type
; ext_spec_pre: forall e: E,
ext_spec_type e -> list typ -> list val -> Z -> M -> Prop
; ext_spec_post: forall e: E,
ext_spec_type e -> option typ -> option val -> Z -> M ->  Prop
; ext_spec_exit: option val -> Z -> M ->  Prop }.
Arguments ext_spec_type {M E Z} _ _.
Arguments ext_spec_pre {M E Z} _ _ _ _ _ _ _.
Arguments ext_spec_post {M E Z} _ _ _ _ _ _ _.
Arguments ext_spec_exit {M E Z} _ _ _ _.
Definition ext_spec := external_specification mem external_function.

(* Specifications: *)
Lemma extfunct_eqdec (ef1 ef2 : external_function) : {ef1=ef2} + {~ef1=ef2}.