invoke Variable.export/import_term on the entire formula, to make sure that schematic variables don't get different indices in different subterms;
this resulted in a subtle soundness bug in Sledgehammer -- introduced by the transition to FOF
structure ROOT =
struct
structure Codegen =
struct
fun lookup ((k, v) :: xs) l =
(if ((k : string) = l) then SOME v else lookup xs l)
| lookup [] l = NONE;
end; (*struct Codegen*)
end; (*struct ROOT*)