equal
deleted
inserted
replaced
43 (string * typ) list -> term -> (string * typ) list * term |
43 (string * typ) list -> term -> (string * typ) list * term |
44 val trace_tac' : Proof.context -> string -> |
44 val trace_tac' : Proof.context -> string -> |
45 ('a -> thm -> 'b Seq.seq) -> 'a -> thm -> 'b Seq.seq |
45 ('a -> thm -> 'b Seq.seq) -> 'a -> thm -> 'b Seq.seq |
46 val try_dest_Trueprop : term -> term |
46 val try_dest_Trueprop : term -> term |
47 |
47 |
48 val type_devar : ((indexname * sort) * typ) list -> term -> term |
48 val type_devar : typ Term_Subst.TVars.table -> term -> term |
49 val diff_and_instantiate : Proof.context -> thm -> term -> term -> thm |
49 val diff_and_instantiate : Proof.context -> thm -> term -> term -> thm |
50 |
50 |
51 val batter_tac : Proof.context -> int -> tactic |
51 val batter_tac : Proof.context -> int -> tactic |
52 val break_hypotheses_tac : Proof.context -> int -> tactic |
52 val break_hypotheses_tac : Proof.context -> int -> tactic |
53 val clause_breaker_tac : Proof.context -> int -> tactic |
53 val clause_breaker_tac : Proof.context -> int -> tactic |
543 in |
543 in |
544 (v'_and_ts, t') |
544 (v'_and_ts, t') |
545 end) |
545 end) |
546 |
546 |
547 (*Instantiate type variables in a term, based on a type environment*) |
547 (*Instantiate type variables in a term, based on a type environment*) |
548 fun type_devar (tyenv : ((indexname * sort) * typ) list) (t : term) : term = |
548 fun type_devar tyenv (t : term) : term = |
549 case t of |
549 case t of |
550 Const (s, ty) => Const (s, Term_Subst.instantiateT tyenv ty) |
550 Const (s, ty) => Const (s, Term_Subst.instantiateT tyenv ty) |
551 | Free (s, ty) => Free (s, Term_Subst.instantiateT tyenv ty) |
551 | Free (s, ty) => Free (s, Term_Subst.instantiateT tyenv ty) |
552 | Var (idx, ty) => Var (idx, Term_Subst.instantiateT tyenv ty) |
552 | Var (idx, ty) => Var (idx, Term_Subst.instantiateT tyenv ty) |
553 | Bound _ => t |
553 | Bound _ => t |
571 |
571 |
572 (*valuation of type variables*) |
572 (*valuation of type variables*) |
573 val typeval = map (fn (v, T) => (dest_TVar v, Thm.ctyp_of ctxt T)) type_pairing |
573 val typeval = map (fn (v, T) => (dest_TVar v, Thm.ctyp_of ctxt T)) type_pairing |
574 |
574 |
575 val typeval_env = |
575 val typeval_env = |
576 map (apfst dest_TVar) type_pairing |
576 Term_Subst.TVars.table (map (apfst dest_TVar) type_pairing) |
577 (*valuation of term variables*) |
577 (*valuation of term variables*) |
578 val termval = |
578 val termval = |
579 map (apfst (dest_Var o type_devar typeval_env)) term_pairing |
579 map (apfst (dest_Var o type_devar typeval_env)) term_pairing |
580 |> map (apsnd (Thm.cterm_of ctxt)) |
580 |> map (apsnd (Thm.cterm_of ctxt)) |
581 in |
581 in |