src/Pure/Tools/codegen_package.ML
changeset 21388 9d8344cf029f
parent 21161 ba4a40552f06
child 21463 42dd50268c8b
equal deleted inserted replaced
21387:5d3d340cb783 21388:9d8344cf029f
   600 fun get_root_module thy =
   600 fun get_root_module thy =
   601   Code.get thy;
   601   Code.get thy;
   602 
   602 
   603 fun eval_term thy (ref_spec, t) =
   603 fun eval_term thy (ref_spec, t) =
   604   let
   604   let
   605     val _ = Term.fold_atyps (fn _ =>
   605     val _ = (Term.fold_types o Term.fold_atyps) (fn _ =>
   606       error ("Term" ^ Sign.string_of_term thy t ^ "is polymorhpic"))
   606       error ("Term" ^ Sign.string_of_term thy t ^ "is polymorhpic"))
   607       (Term.fastype_of t);
   607       t;
   608     val t' = codegen_term thy t;
   608     val t' = codegen_term thy t;
   609   in CodegenSerializer.eval_term thy (ref_spec, t') (Code.get thy) end;
   609   in CodegenSerializer.eval_term thy (ref_spec, t') (Code.get thy) end;
   610 
   610 
   611 
   611 
   612 
   612