src/HOL/Tools/datatype_package.ML
changeset 19925 3f9341831812
parent 19874 cc4b2b882e4c
child 20054 24d176b8f240
equal deleted inserted replaced
19924:ee3c4ec1d652 19925:3f9341831812
   797       |> fold_map apply_theorems raw_distinct
   797       |> fold_map apply_theorems raw_distinct
   798       ||>> fold_map apply_theorems raw_inject
   798       ||>> fold_map apply_theorems raw_inject
   799       ||>> apply_theorems [raw_induction];
   799       ||>> apply_theorems [raw_induction];
   800     val sign = Theory.sign_of thy1;
   800     val sign = Theory.sign_of thy1;
   801 
   801 
   802     val induction' = Thm.freezeT induction;
   802     val ([induction'], _) = Variable.importT [induction] (Variable.thm_context induction);
   803 
   803 
   804     fun err t = error ("Ill-formed predicate in induction rule: " ^
   804     fun err t = error ("Ill-formed predicate in induction rule: " ^
   805       Sign.string_of_term sign t);
   805       Sign.string_of_term sign t);
   806 
   806 
   807     fun get_typ (t as _ $ Var (_, Type (tname, Ts))) =
   807     fun get_typ (t as _ $ Var (_, Type (tname, Ts))) =