src/Tools/Code/code_haskell.ML
changeset 31934 004c9a18e699
parent 31889 fb2c8a687529
child 32903 793c993c63aa
equal deleted inserted replaced
31933:cd6511035315 31934:004c9a18e699
   145             fun pr_eq ((ts, t), (thm, _)) =
   145             fun pr_eq ((ts, t), (thm, _)) =
   146               let
   146               let
   147                 val consts = map_filter
   147                 val consts = map_filter
   148                   (fn c => if (is_some o syntax_const) c
   148                   (fn c => if (is_some o syntax_const) c
   149                     then NONE else (SOME o Long_Name.base_name o deresolve) c)
   149                     then NONE else (SOME o Long_Name.base_name o deresolve) c)
   150                     ((fold o Code_Thingol.fold_constnames) (insert (op =)) (t :: ts) []);
   150                     (fold Code_Thingol.add_constnames (t :: ts) []);
   151                 val vars = init_syms
   151                 val vars = init_syms
   152                   |> Code_Printer.intro_vars consts
   152                   |> Code_Printer.intro_vars consts
   153                   |> Code_Printer.intro_vars ((fold o Code_Thingol.fold_unbound_varnames)
   153                   |> Code_Printer.intro_vars ((fold o Code_Thingol.fold_varnames)
   154                        (insert (op =)) ts []);
   154                        (insert (op =)) ts []);
   155               in
   155               in
   156                 semicolon (
   156                 semicolon (
   157                   (str o deresolve_base) name
   157                   (str o deresolve_base) name
   158                   :: map (pr_term tyvars thm vars BR) ts
   158                   :: map (pr_term tyvars thm vars BR) ts