src/HOL/Tools/inductive.ML
changeset 56249 0fda98dd2c93
parent 56245 84fc7dfa3cd4
child 56334 6b3739fee456
equal deleted inserted replaced
56247:1ad01f98dc3e 56249:0fda98dd2c93
   998 fun gen_add_inductive_i mk_def
   998 fun gen_add_inductive_i mk_def
   999     (flags as {quiet_mode, verbose, alt_name, coind, no_elim, no_ind, skip_mono})
   999     (flags as {quiet_mode, verbose, alt_name, coind, no_elim, no_ind, skip_mono})
  1000     cnames_syn pnames spec monos lthy =
  1000     cnames_syn pnames spec monos lthy =
  1001   let
  1001   let
  1002     val thy = Proof_Context.theory_of lthy;
  1002     val thy = Proof_Context.theory_of lthy;
  1003     val _ = Theory.requires thy "Inductive" (coind_prefix coind ^ "inductive definitions");
  1003     val _ =
       
  1004       Theory.requires thy (Context.theory_name @{theory})
       
  1005         (coind_prefix coind ^ "inductive definitions");
  1004 
  1006 
  1005 
  1007 
  1006     (* abbrevs *)
  1008     (* abbrevs *)
  1007 
  1009 
  1008     val (_, ctxt1) = Variable.add_fixes (map (Binding.name_of o fst o fst) cnames_syn) lthy;
  1010     val (_, ctxt1) = Variable.add_fixes (map (Binding.name_of o fst o fst) cnames_syn) lthy;