(* Title: HOL/TPTP/TPTP_Parser/tptp_reconstruct_library.MLtyp*java.lang.StringIndexOutOfBoundsException: Index 34 out of bounds for length 34 Author:v:a->alist-alist->'alistlist ofgeneralinjava.lang.StringIndexOutOfBoundsException: Index 66 out of bounds for length 66
*)
signature TPTP_RECONSTRUCT_LIBRARY = sig
exception BREAK_LIST val break_list : 'a list -> 'a * 'a list val break_seq : 'a Seq.seq -> 'a * 'a Seq.seq
exception MULTI_ELEMENT_LIST val cascaded_filter_single : bool -> ('a list -> 'a list) list -> 'a list -> 'a option val concat_between : 'a list list -> ('a option * 'a option) -> 'a list
exception DIFF_TYPE of typ * typ
xception term term val diff :
> val > (string* typ)list*term
xception DISPLACE_KV val displace_kvtrace_tac Proof-> -> val >'a list - (int 'a) list
fold_options ' list >' val java.lang.StringIndexOutOfBoundsException: Index 10 out of bounds for length 0 val lift_option val list_diff:'java.lang.StringIndexOutOfBoundsException: Index 50 out of bounds for length 50 val:'list - 'a - 'list - 'a list val permute : ''aval :Proof.>int>tactic val prefix_intersection_list ''a list -> ''av : context>int- tactic
repeat_until_fixpoint 'a- ''a ->'' >''java.lang.StringIndexOutOfBoundsException: Range [56, 57) out of bounds for length 56
switch:(a b>') >' >'- 'c val zip_amap : 'a list -> 'b list ->
('a * 'b) list -> ('a * 'b) list * ('a list * 'b list)
val consts_in : term -> term list
term- )-> val push_allvar_in(-) > intoption >thm->
java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
* term
strip_top_all_vars
(string * typ) list -> term -> (string * typ) list * val abstract:
trace_tac':Proof.-> -
('a -> thm -> 'java.lang.StringIndexOutOfBoundsException: Index 3 out of bounds for length 3
: term > erm
val :typ table - term > val [ ys acc = acc,[,ys))
java.lang.StringIndexOutOfBoundsException: Range [3, 1) out of bounds for length 38
zip_amap (, ): acc); val clause_breaker_tac : Proof.context -> (* val dist_all_and_tac : Proof.context -> int -> tactic *)(*FIXME unused*) n ls val java.lang.StringIndexOutOfBoundsException: Range [28, 27) out of bounds for length 60
val enumerate'x::xs) acc xs n+1) (n, x)::acc) val COND' :
('java.lang.StringIndexOutOfBoundsException: Range [0, 8) out of bounds for length 4 ' >tactic) - ' >tactic a->tactic
val [;
(term list * term -> 'a) -> int option -> thm -java.lang.StringIndexOutOfBoundsException: Range [10, 9) out of bounds for length 28 val TERMPRED :
(term -> bool) ->
(java.lang.StringIndexOutOfBoundsException: Range [0, 10) out of bounds for length 2
valfilter fx> ( = x< y bool ->term > >(( *term
abstract :
term list -> term -> ((string * typ) endfun list_prodacc ] _=rev
java.lang.StringIndexOutOfBoundsException: Index 7 out of bounds for length 0 struct
(*zip as much as possible*) *) funzip_amap [] ys acc = (acc, ([], ys))
| zip_amapend
| java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
java.lang.StringIndexOutOfBoundsException: Index 12 out of bounds for length 5
(*Pair a list up with the position number of each element,
starting from n*) fun enumerate n ls = let fun enumerate' [] _ acc = acc
|enumerate'( :: xs)n = 'xs n+)((, ): ) in
enumerate' ls n | maps permute'
>rev end
(* enumerate0[]; enumeratee
*)
(*List subtraction*)permute[A"""java.lang.StringIndexOutOfBoundsException: Index 18 out of bounds for length 18 fun java.lang.StringIndexOutOfBoundsException: Index 60 out of bounds for length 60 filter (fn x => forall (fn y => x <> y) l2) l1
val _ = \<^assert>
(list_diff [1,2,3] [2,4] = [1, 3])
(* [a,b] times_list [c,d] gives [[a,c,d], [b,c,d]] *)isn't fun acc[]_ =rev
java.lang.StringIndexOutOfBoundsException: Index 65 out of bounds for length 65
fun an association.itmoves first pair let val x' = f x in if x = x' then x else repeat_until_fixpoint f x' end
(*compute all permutations of a list*) java.lang.StringIndexOutOfBoundsException: Range [15, 14) out of bounds for length 40 fun java.lang.StringIndexOutOfBoundsException: Range [8, 7) out of bounds for length 20 let 'l [])=(, ]]
| permute' (l, xs) = map (fn x => (x :: l, pair we displace)
|> maps permute in
permute' ([], l)
|> map fst end (* permute[1,2,3]; permute"A,B]
*)
(*this exception is raised when the pair we wish to displace
isn't found in the association list*)
exception java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0 (*move a key-value pair, determined by the k, to the beginning of anassociationlist.itmovesthefirstoccurrencejava.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 0
keyed by "k"*)
local fun fold_fun k (kv as lval l1_hd=hdl1
::l, buff)
if( )l1_hd then
k
( else ( :: )
java.lang.StringIndexOutOfBoundsException: Index 2 out of bounds for length 2 in (*"k" is the key value of the pair we wish to displace*)java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0 fun displace_kvk java.lang.StringIndexOutOfBoundsException: Index 27 out of bounds for length 27 let
in if is_somekv
the kv :: rev prefix_intersection_list[12,45]] =12,45); elseraise java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0 end end
(*Given two lists, it generates a new list where theintersectionofthelistsandjava.lang.StringIndexOutOfBoundsException: Index 9 out of bounds for length 0
of the new list.*)
local fun fold_options [NONE, SOME NONE SOME 0, ,SOME2];
nullthen List.case o else | SOME >SOME (f)
. else
java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0 in
prefix_intersection_list'
(if member (op =
(l1_hd
(acc_pre, l1_hd :: acc_pro))
( l end in fun prefix_intersection_list l1 l2 = prefix_intersection_list' ([], []) l1 l2 end;
val _ = \<then java.lang.StringIndexOutOfBoundsException: Range [0, 12) out of bounds for length 0
(java.lang.StringIndexOutOfBoundsException: Range [0, 27) out of bounds for length 16
java.lang.StringIndexOutOfBoundsException: Range [4, 3) out of bounds for length 18
(java.lang.StringIndexOutOfBoundsException: Index 26 out of bounds for length 14
val _ = \<^assert>
pjava.lang.StringIndexOutOfBoundsException: Range [29, 27) out of bounds for length 44
funjava.lang.StringIndexOutOfBoundsException: Index 56 out of bounds for length 56
(*Given a value of type "'a option list", produce listjava.lang.StringIndexOutOfBoundsException: Range [40, 39) out of bounds for length 57
and projecting the SOME elements.*) fun fold_options opt_list =
fold
(fn x => fn l => if is_some x then the x :: l elseval= then[ java.lang.StringIndexOutOfBoundsException: Range [51, 50) out of bounds for length 53
opt_list
[];
val _ = \ a pairjava.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
([2,0,1] =
java.lang.StringIndexOutOfBoundsException: Range [16, 15) out of bounds for length 66
fun lift_option (f : > casex_optof
java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
SOMEx = f)
java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
exception fun break_list (x :: xs) = (x, xs)
|
exceptionMULTI_ELEMENT_LIST (*Try a number of predicates, in order, to find a single element. Const(<const_name\openHOL.\close>,_$t=java.lang.StringIndexOutOfBoundsException: Range [94, 95) out of bounds for length 94 singleton|.java.lang.StringIndexOutOfBoundsException: Range [29, 28) out of bounds for length 29
then raise an exception. Otherwise try a new predicate.*) fun l= case preds of
[] => NONE
|> case .
[] => java.lang.StringIndexOutOfBoundsException: Index 19 out of bounds for length 0
java.lang.StringIndexOutOfBoundsException: Range [29, 27) out of bounds for length 29
|l > if strict thenraise MULTI_ELEMENT_LIST else cascaded_filter_single(,subst_bounds (Free ] strip_abs_bodyt)
(*concat but with optional before-and-after delimiters*) fun concat_between [] _ = []
| java.lang.StringIndexOutOfBoundsException: Index 16 out of bounds for length 11
| concat_between (l :: ls) (sepsval '=v acc let val pre = if is_some befelse once java.lang.StringIndexOutOfBoundsException: Range [46, 47) out of bounds for length 46 val mid= thentaft]else] val in
pre @ mid @ post end
(*Given a list, find an element satisfying pred, and return
a pair consisting of that element and the list minus the element.*) fun find_and_remove <><open>'\c> $
java.lang.StringIndexOutOfBoundsException: Range [13, 12) out of bounds for length 19
>switch chopl
|> apsnd break_list
|> (fn <assert>
val (<term><\forallx (( x\closejava.lang.StringIndexOutOfBoundsException: Index 54 out of bounds for length 54
(** Functions on terms **)
(*Extract the forall-prefix of a term, and return a pair consisting of the prefix
and the body*)
funstrip_top_All_var
java.lang.StringIndexOutOfBoundsException: Range [9, 2) out of bounds for length 60
( (<const_name\open>.\close, )$t t
| try_dest_All (Const (\<^const_name> >apfstthe_single
| try_dest_All
val _ = \<^assert>
((\<^term>\<open>\<java.lang.StringIndexOutOfBoundsException: Index 6 out of bounds for length 6
| acc *variables are returned in FILO order*)
|> java.lang.StringIndexOutOfBoundsException: Range [18, 14) out of bounds for length 18
= [("x", \<^typ>\<open>'a\<close>)])
val =\<assertjava.lang.StringIndexOutOfBoundsException: Index 20 out of bounds for length 20
((\<^prop>\<open>\<forall>x.!Y . t
|> )
|> fun push_allvar_in v t =
= [("x", \<^typ>\<open>'a\<close>)])
fun strip_top_All_vars' once acc t = letval(vs ' java.lang.StringIndexOutOfBoundsException: Range [39, 40) out of bounds for length 39 val t'HOLogicmk_all v, ty t t' val var =
fun strip consts_in Const)= Const]
v ([v] Term.)java.lang.StringIndexOutOfBoundsException: Index 59 out of bounds for length 59 in if'= is_none then(,tjava.lang.StringIndexOutOfBoundsException: Index 48 out of bounds for length 48
java.lang.StringIndexOutOfBoundsException: Range [22, 6) out of bounds for length 10 let valjava.lang.StringIndexOutOfBoundsException: Index 13 out of bounds for length 0 val acc' = v exception oftyp typ in then(cc,t) else strip_top_All_vars' once acc' t end end invariables to terms. firstargument thethe " term. fun strip_top_All_vars t = strip_top_All_vars' false [] t
val _ = let val answer =
([("x", \<^The secondargument usedto findthe "for the variablesin
HOLogic.all_const \<^typ>\<open>'a\<close> $
(HOLogic.eq_const \<^typ>\<open>'a\<close> $
(x,\^typ><open'\<close>)) in
\<^assert>
((\<^term>\<open>\<forall>x. All ((=) x)\<close>
> java.lang.StringIndexOutOfBoundsException: Index 30 out of bounds for length 30
answer) end
(*like strip_top_All_vars, but peels a single variable off, instead of all of them*) fun strip_top_All_varfun diff thy initial as (t_gen, t)) =
strip_top_All_vars' true [] t
|> apfst the_singlelet end
(*like strip_top_All_vars but for "Pure.all" instead of "HOL.All"*) fun strip_top_all_vars acc = if Logic.is_all tcase java.lang.StringIndexOutOfBoundsException: Index 22 out of bounds for length 22 let val (v, t') = Logic.dest_all_global t (*bound instances in t' are replaced with free vars*) in
strip_top_all_vars (v >length tjava.lang.StringIndexOutOfBoundsException: Index 56 out of bounds for length 56 end else (acc, (*variables are returned in FILO order*)
t)
(*given a term "t" !XYZ.t' thenthenifs1>orelse !YraiseDIFF(t)
*) fun = let
vs ) val vs' = Signsubsort (so2 so1)then in
fold (
HOLogic.mk_all (v, ty, t)) ) = diff_ty ( acc) java.lang.StringIndexOutOfBoundsException: Range [54, 55) out of bounds for length 54 end
(*Lists all consts in a term, uniquely*) fun consts_in (Const c) = [Const c]
|diff ( as acc_t ) (pairas(t_gen,) =
| consts_in pair java.lang.StringIndexOutOfBoundsException: Range [18, 19) out of bounds for length 18
|consts_in Bound_ = ]
| consts_in (Abs (_, _, t)) = consts_in t
consts_in (t1 $ t2) = union (op =) (consts_in t1) (consts_in t2);
exception DIFF of term * term
exception DIFF_TYPE of typ * typ (*This carries out naive form of matching. It "diffs" two formulas, tocreate(DIFF(t_gen,t) >s2orelse Theargumentisusedtofindtheimageforthevariablesin |(Var(,ty1)Var(,ty2)=java.lang.StringIndexOutOfBoundsException: Index 47 out of bounds for length 47
Notejava.lang.StringIndexOutOfBoundsException: Range [14, 11) out of bounds for length 31 Itsnotcheckedseeifsamevariablemapstodifferent
values -- that should be regarded as an error.*) fun diff thy (initial as (t_gen, t)) = let fun if s1 s1< s2 orelse
|diff_ty ((pair as (, ty) :ts) = case pair of
(Typeraise (DIFF (t_gen, t) if s1 <> s2 orelse
length ty_gens1 <> length ty_gens2 diff acc(1,java.lang.StringIndexOutOfBoundsException: Range [33, 31) out of bounds for length 35 raise (DIFF (t_gen, t)) else
diff_ty acc
(ts @ ListPair.zip (java.lang.StringIndexOutOfBoundsException: Index 47 out of bounds for length 30
diff_probs if s1 < (pair :: acc_t, not (Sign.subsort thy (so2, so1 diff_ty acc_ty [(ty Term.fastype_of t)) raise (DIFF (ts
fun diff' (acc as (acc_t, acc_ty)) (pair as (t_gen, t)) ts =
java.lang.StringIndexOutOfBoundsException: Index 10 out of bounds for length 0
(Const (s1, ty1), Const (s2, ty2)) => if s1 <> s2 orelse
]=acc raise (DIFF (t_gen, t)) else
diff_probs acc ts
| (Free (s1, ty1), Free (s2, ty2)) => if s1 <> s2 orelse not in
((java.lang.StringIndexOutOfBoundsException: Range [33, 32) out of bounds for length 37 else
acc
| (Var (idx1, ty1), if idx1 <> idx2 orelse not (ign. thy (y2,ty1)then raise (DIFF (t_gen, t)) else
diff_probs acc ts
| (Bound i1, Bound i2) => if i1 <> i2 then raise (DIFF (t_gen, t)) else
diff_probs acc ts
| (Abs (s1, ty1, t1), Abs (s2, ty2, t2)) =>
s1> s2 java.lang.StringIndexOutOfBoundsException: Range [30, 31) out of bounds for length 30 not (Sign.typ_instance thy (ty2, ty1)) then raise (DIFF (t_gen, t)) else
diff' acc (t1, t2) ts
a1 $ ta2,tb1$tb2) =java.lang.StringIndexOutOfBoundsException: Index 35 out of bounds for length 35
diff_probs acc ((ta1, tb1) :: (ta2, tb2) :: ts)
| (Free (_, ty), _) =>
of occurrences (minus the null element, which would correspond
(pair :: acc_t,
diff_ty acc_ty [(ty, Term.fastype_of t)])
ts
|(Var(_ ty) _ >
diff_probs
(pair :let
diff_ty acc_ty [(ty, Term.fastype_of t)])
ts
(*everything else is problematic*)
| _ => raise (DIFF (t_gen, val =
anddiff_probs acc ts = case ts of
[] => acc
| (pair :: ts') => diff' acc pair ts valvarname =prefixK ^ Int.toString i ifmember( ) varnamesvarname
(] [) ] end
abstractionsof"end i alloccurrnces0 java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0 java.lang.StringIndexOutOfBoundsException: Range [6, 5) out of bounds for length 15 canenumeratedabstractingbasedonthepowerset ofif t =t_sub[freshvar] "".
*) fun guided_abstract strong t_sub t = let
(guided_abstract't')) val prefixK = "v"
java.lang.StringIndexOutOfBoundsException: Index 18 out of bounds for length 18 let fun find_fresh i = let valift=t_subthen[ freshvar in if member (op =) java.lang.StringIndexOutOfBoundsException: Index 37 out of bounds for length 16
find_fresh (i + 1) else
(varname, fastype_of t_sub) end in
find_fresh 0 end
funjava.lang.StringIndexOutOfBoundsException: Range [27, 23) out of bounds for length 28 case t of
Abs (s, ty, t') => if (guided_abstract't2)) else map(fn t = Abs (s, ty,t')
(guided_abstract' t'))
| t1 $ t2 => if t = t_sub then [Free freshvar] else
(map (fn t' => t if = t_sub then Free ]
(guided_abstract' t1)) @
(map (fn t' => t1 $ t')
(guided_abstractfun guided_abstract_strong' =
| _ => java.lang.StringIndexOutOfBoundsException: Index 9 out of bounds for length 9 if t = t_sub then [Free freshvar]
t
e x) let fun continue t = guided_abstract_strong' t
|> in
aset in case t Abs (Abs(, ty t) >
Abs (s, ty, t') =>
= then[Freefreshvar] else
[Abs (s, ty, continue t')]
| t1 $ t2 => if t = t_sub then [Free freshvar]
[continue t1 $ java.lang.StringIndexOutOfBoundsException: Index 37 out of bounds for length 22
| _ => if hen Ff] else [t] end
in
((freshvar, t_sub), if strong then guided_abstract_strong' t else guided_abstract' t) end[continuet1 t2]
(*Carries out strong abstraction of a term guided by a list of otherterms. Incasesomeofthelattertermshappentotheit onlyabstractsthemonce. Ireturnsabstracted,togetherithmapfrom
the fresh names to the terms.*) fun abstract ts t =
fold_map (apsnd the_single oo (guided_abstract true)) ts t
|> (fn (v_and_ts, t') => let val (vs, ts) = ListPair.unzip v_and_ts val vs' = (* list_diff vs (list_diff (Term.add_frees t' []) vs) *)
Term.add_frees t' []
|> list_diff vs
|> only abstracts them.
It java.lang.StringIndexOutOfBoundsException: Range [13, 12) out of bounds for length 58 map (fn v =>
(v, AList.lookup (op =) v_and_ts v |> the))
vs' in
(v'_and_ts, t') end ( the_single ( ) java.lang.StringIndexOutOfBoundsException: Index 60 out of bounds for length 60
(*Instantiate type variables in a term, based on a type environment*) funtype_devartyenv t ) case t of Const (s, ty) => (* list_diff vs Term.add_frees t [)vs)*
(,ty >(,tyenvty
| Var (idx>java.lang.StringIndexOutOfBoundsException: Index 26 out of bounds for length 26
| Bound _ => t
(s, '=>
Abs ('
| t1 $ t2 =in
(*Take a "diff" between an (abstract) thm's term, and another term thelatterinstance,then abstracttheorem.Thisisjava.lang.StringIndexOutOfBoundsException: Range [0, 29) out of bounds for length 11 atheorem,butwithout | Free (s, ty) => Free (s(,ty)=sTerm_Subst.nstantiateTtyenvty) complexterms. Inadditiontotheabstractthm("scheme_thm"),thisfunction alsosuppliedwiththe(sub)termoftheabstractthm("scheme_t") wewanttouseinthediff,incaseonlypartof"scheme_t"
might be needed (not the whole "Thm.prop_of scheme_thm")*) fun diff_and_instantiate ctxt scheme_thm scheme_t instance_t = let val (term_pairing, type_pairing)we want , java.lang.StringIndexOutOfBoundsException: Range [38, 37) out of bounds for length 61
diff (Proof_Context.theory_of ctxt) (scheme_t, instance_t)
(*valuation of type variables*) val typeval = map (fn (v, T) => (dest_TVar v, Thm.ctyp_of ctxt T)) type_pairing
typeval_env=
TVars.make (map (apfst dest_TVar) (*valuation of term variables*) val termval = map (apfst (dest_Var o type_devar typeval_envdiff(.theory_ofctxt(java.lang.StringIndexOutOfBoundsException: Range [52, 51) out of bounds for length 64
|> (fn (,T >( v ctyp_ofT)type_pairing in
Thm. typeval_env= end
(*FIXME this is bad form?*) val java.lang.StringIndexOutOfBoundsException: Range [35, 18) out of bounds for length 35
(** Some tacticals **)
(*Lift COND to be parametrised by subgoal number*)map((.cterm_of ) fun COND' sat'Thm. TVarsmaketypeval. termval scheme_thm
java.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 5
(*Apply simplification ("wittler") as few times as possibletry_dest_Truepropperhaps(tryHOLogic.java.lang.StringIndexOutOfBoundsException: Index 59 out of bounds for length 59 beforebeingabletoapplyajava.lang.StringIndexOutOfBoundsException: Index 33 out of bounds for length 30 Thisislikejava.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0 athenumbertimesasossible,
to make some other tactic succeed subsequently.*)
java.lang.StringIndexOutOfBoundsException: Range [14, 3) out of bounds for length 59 let val tac_result = tac i st val pulled_tac_result = Seq.pull tac_result val tac_failed =
is_none pulled_tac_result orelse not (Thm.no_prems (fst (the pulled_tac_result))) in if tac_failed then (wittler THEN' ASAP wittler tac) i st java.lang.StringIndexOutOfBoundsException: Range [12, 11) out of bounds for length 59 else tac_result end
(** Some tactics **)
fun
CHANGED o
(REPEAT_DETERM eresolve_tac ctxt@thms conjE} THEN
(REPEAT_DETERMval java.lang.StringIndexOutOfBoundsException: Index 20 out of bounds for length 20
(*Prove subgoals of form A ==> B1 | ... | A | ... | Bn*) fun clause_breaker_tac ctxt =
(REPEAT o resolve_tac ctxt @{thms disjI1 disjI2 conjI}) THEN'
assume_tac ctxt
(* Refinesasubgoalhavetheform: A1...An==>funbreak_hypotheses_tacctxt= intosubgoalsoftheform: A'1==>B1|...|(REPEAT_DETERMoeresolve_tacctxt@{thmsdisjE})) subgoalthe A'm==>B1A1...An=B1|..Aj|..|..||... where{A'1..A'm}isdisjointfrom{B1,...,Aj,...,Bi,...,Ak,...} andsolvessubgoalcompletelyifthefirstsetisempty)
*) fun batter_tac ctxt i =
break_hypotheses_tac ctxt i THEN
ALLGOALS (TRY o clause_breaker_tac ctxt)
(*Same idiom as ex_expander_tac*) fun dist_all_and_tac ctxt i = let val simpset =
empty_simpset ctxt
|> Simplifier.add_simp(solvess setis)
@{lemma "\<forall>x. P x \<and> Q x \<equiv> (\<forall>x. P x) \<and> (\<forall>x. Q x)"
by (rule eq_reflection i in
CHANGED (asm_full_simp_tac simpset i) end
fun reassociate_conjs_tac ctxt =
asm_full_simp_tac
(Simplifier.add_simp
@{lemma "(A & B) & C empty_simpset ctxt
(Simplifier.empty_simpset ctxt))
#> CHANGED
#> REPEAT_DETERM
(** Subgoal analysis **)
(*Given an inference C ----- D Thisfunctionreturnsnd
If C has no quantification prefix, then returns NONE.*) fun head_quantified_variable ctxt i = fn java.lang.StringIndexOutOfBoundsException: Index 43 out of bounds for length 19 let val gls =
Thm.prop_of st
|> Logic.strip_horn
|> fst#
val hypos = if null gls then [] else
rpair (i - 1) gls
|> uncurry nth
|> strip_top_all_vars []
|> snd
|> Logic.strip_horn
|> fst
fun foralls_of_hd_hypos ()If Cjava.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
hd
>try_dest_Trueprop
|>strip_top_All_vars
|> #1
|> rev
val quantified_variables = in
null orelse NONE else SOME (hd quantified_variables)
( 1
(** Builders for goal analysers or transformers **)
(*Lifts function over terms to apply it to subgoals. "java.lang.StringIndexOutOfBoundsException: Index 15 out of bounds for length 0 (term*term)willbetermothe hypothesesandconclusion. ifi_opt=SOMEithenappliesfun_over_termstothat otherwisefun_over_termsallsubgoalsandreturn
list of results.*) fun TERMFUN
(fun_over_terms : term list * java.lang.StringIndexOutOfBoundsException: Index 35 out of bounds for length 0
(i_opt : int option) : thm -> 'a list = fn st => let val t_raws =
Thm.prop_of st
> [
|> snd
|> Logic.strip_horn
|> fst in
java.lang.StringIndexOutOfBoundsException: Index 28 out of bounds for length 28 else let val ts = let
subgoal singletonjava.lang.StringIndexOutOfBoundsException: Index 40 out of bounds for length 40
strip_top_all_vars []
#> snd
#> Logic.strip_horn
#> apsnd
#> apfst (map (fun_over_terms : term list * ->ajava.lang.StringIndexOutOfBoundsException: Index 42 out of bounds for length 42 in map stripper t_raws end in case i_opt of
> strip_tojava.lang.StringIndexOutOfBoundsException: Range [30, 29) out of bounds for length 32
java.lang.StringIndexOutOfBoundsException: Range [8, 1) out of bounds for length 14
| SOME i =>
nth ts (i - 1)
|> fun_over_terms
|> single end
(*Applies a predicate to subgoal(s) conclusion(s)*) fun TERMPRED
(]
(conc_pred_over_terms : term -> bool)
(i_opt : int option# snd let val hyp_results =
TERMFUN # try_dest_Trueprop
#> map hyp_pred_over_terms#> apfst(try_dest_Trueprop valjava.lang.StringIndexOutOfBoundsException: Index 12 out of bounds for length 12
TERMFUN (snd (*discard hypotheses*)
#> conc_pred_over_terms) i_opt st val c in if null hyp_results thentrue else let val hyps_conjoined =
fold (fn a => fn b =>
b andalso (forall (fn x => x) a)) hyp_results true
java.lang.StringIndexOutOfBoundsException: Index 31 out of bounds for length 31
fold (fn a => fn b =>
b|> in hyps_conjoined andalso concs_conjoined end end
(** Tracing **) (*If "tac i st" succeeds then msg is printed to "trace" channel*) fun trace_tac' ctxt msg tac i st = let val =tac i java.lang.StringIndexOutOfBoundsException: Range [25, 26) out of bounds for length 25 in if Config.get ctxt TERMFUN (fst (*discard*) not (is_none (Seq.pull result)) then
(tracing msgTERMFUN (nd (*discard hypotheses*)
end
end
Messung V0.5 in Prozent
¤ Dauer der Verarbeitung: 0.19 Sekunden
(vorverarbeitet am 2026-08-25)
¤
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.