src/HOL/Import/shuffler.ML
changeset 46218 ecf6375e2abb
parent 46201 afdc69f5156e
child 46803 f8875c15cbe1
equal deleted inserted replaced
46217:7b19666f0e3d 46218:ecf6375e2abb
   150   | swap_bound n (Abs(x,xT,t)) = Abs(x,xT,swap_bound (n+1) t)
   150   | swap_bound n (Abs(x,xT,t)) = Abs(x,xT,swap_bound (n+1) t)
   151   | swap_bound n t = t
   151   | swap_bound n t = t
   152 
   152 
   153 fun rew_th thy (xv as (x,xT)) (yv as (y,yT)) t =
   153 fun rew_th thy (xv as (x,xT)) (yv as (y,yT)) t =
   154     let
   154     let
   155         val lhs = list_all ([xv,yv],t)
   155         val lhs = Logic.list_all ([xv,yv],t)
   156         val rhs = list_all ([yv,xv],swap_bound 0 t)
   156         val rhs = Logic.list_all ([yv,xv],swap_bound 0 t)
   157         val rew = Logic.mk_equals (lhs,rhs)
   157         val rew = Logic.mk_equals (lhs,rhs)
   158         val init = Thm.trivial (cterm_of thy rew)
   158         val init = Thm.trivial (cterm_of thy rew)
   159     in
   159     in
   160         all_comm RS init
   160         all_comm RS init
   161     end
   161     end