src/HOL/datatype.ML
changeset 1360 6bdee79ef125
parent 1279 f59b4f9f2cdc
child 1455 52a0271621f3
equal deleted inserted replaced
1359:71124bd19b40 1360:6bdee79ef125
   402 	  then add_defs_i [defpairT] thy
   402 	  then add_defs_i [defpairT] thy
   403 	  else error("Primrec definition error: \ntype of " ^ fname 
   403 	  else error("Primrec definition error: \ntype of " ^ fname 
   404 		     ^ " is not instance of type deduced from equations")
   404 		     ^ " is not instance of type deduced from equations")
   405 	end;
   405 	end;
   406 
   406 
   407     in 
   407     in
   408       (thy
   408       store_datatype (tname, map (fn (x,_,_) => x) cons_list');
   409       |> add_types types
   409       (thy |> add_types types
   410       |> add_arities arities
   410            |> add_arities arities
   411       |> add_consts consts
   411            |> add_consts consts
   412       |> add_trrules xrules
   412            |> add_trrules xrules
   413       |> add_axioms rules,add_primrec)
   413            |> add_axioms rules, add_primrec)
   414     end
   414     end
   415 end
   415 end
   416 end
   416 end
   417 
   417 
   418 (*
   418 (*