src/HOL/Tools/Ctr_Sugar/ctr_sugar_util.ML
changeset 55535 10194808430d
parent 55480 59cc4a8bc28a
child 56254 a2dd9200854d
equal deleted inserted replaced
55534:b18bdcbda41b 55535:10194808430d
    38   val variant_tfrees: string list -> Proof.context -> typ list * Proof.context
    38   val variant_tfrees: string list -> Proof.context -> typ list * Proof.context
    39 
    39 
    40   val typ_subst_nonatomic: (typ * typ) list -> typ -> typ
    40   val typ_subst_nonatomic: (typ * typ) list -> typ -> typ
    41   val subst_nonatomic_types: (typ * typ) list -> term -> term
    41   val subst_nonatomic_types: (typ * typ) list -> term -> term
    42 
    42 
    43   val lhs_heads_of : thm -> term list
    43   val lhs_head_of : thm -> term
    44 
    44 
    45   val mk_predT: typ list -> typ
    45   val mk_predT: typ list -> typ
    46   val mk_pred1T: typ -> typ
    46   val mk_pred1T: typ -> typ
    47 
    47 
    48   val mk_disjIN: int -> int -> thm
    48   val mk_disjIN: int -> int -> thm
   180     in subst end;
   180     in subst end;
   181 
   181 
   182 fun subst_nonatomic_types [] = I
   182 fun subst_nonatomic_types [] = I
   183   | subst_nonatomic_types inst = map_types (typ_subst_nonatomic inst);
   183   | subst_nonatomic_types inst = map_types (typ_subst_nonatomic inst);
   184 
   184 
   185 fun lhs_heads_of thm =
   185 fun lhs_head_of thm = Term.head_of (fst (HOLogic.dest_eq (HOLogic.dest_Trueprop (prop_of thm))));
   186   [Term.head_of (fst (HOLogic.dest_eq (HOLogic.dest_Trueprop (prop_of thm))))];
       
   187 
   186 
   188 fun mk_predT Ts = Ts ---> HOLogic.boolT;
   187 fun mk_predT Ts = Ts ---> HOLogic.boolT;
   189 fun mk_pred1T T = mk_predT [T];
   188 fun mk_pred1T T = mk_predT [T];
   190 
   189 
   191 fun mk_disjIN 1 1 = @{thm TrueE[OF TrueI]}
   190 fun mk_disjIN 1 1 = @{thm TrueE[OF TrueI]}