equal
deleted
inserted
replaced
113 fun read_insts thm raw_insts raw_fixes ctxt = |
113 fun read_insts thm raw_insts raw_fixes ctxt = |
114 let |
114 let |
115 val (type_insts, term_insts) = |
115 val (type_insts, term_insts) = |
116 List.partition (fn (((x, _), _), _) => String.isPrefix "'" x) raw_insts; |
116 List.partition (fn (((x, _), _), _) => String.isPrefix "'" x) raw_insts; |
117 |
117 |
118 val tvars = Term_Subst.TVars.build (Thm.fold_terms Term_Subst.add_tvars thm); |
118 val tvars = Term_Subst.TVars.build (Thm.fold_terms {hyps = false} Term_Subst.add_tvars thm); |
119 val vars = Term_Subst.Vars.build (Thm.fold_terms Term_Subst.add_vars thm); |
119 val vars = Term_Subst.Vars.build (Thm.fold_terms {hyps = false} Term_Subst.add_vars thm); |
120 |
120 |
121 (*eigen-context*) |
121 (*eigen-context*) |
122 val (_, ctxt1) = ctxt |
122 val (_, ctxt1) = ctxt |
123 |> Term_Subst.TVars.fold (Variable.declare_internal o Logic.mk_type o TVar o #1) tvars |
123 |> Term_Subst.TVars.fold (Variable.declare_internal o Logic.mk_type o TVar o #1) tvars |
124 |> Term_Subst.Vars.fold (Variable.declare_internal o Var o #1) vars |
124 |> Term_Subst.Vars.fold (Variable.declare_internal o Var o #1) vars |