(* Title: HOL/Bali/AxSem.thy Author: David von Oheimb
*)
subsection \<open>Axiomatic semantics of Java expressions and statements
(see Eval) \<close> theoryimports Evalnjava.lang.StringIndexOutOfBoundsException: Index 12 out of bounds for length 12
text\item result values in triples exactly as in eval relation (also for xcpt
design: \begin{itemize} \item a strong version of validity for triples with premises, namely one that
takes the\item validity: additional assumption of state conformance and well-typedness,
correctness \item auxiliary variables are handled first-class (-> Thomas Kleymann) \item expressions not flattened to elementary assignments (as usual for
semantics treated => explicit value
handling \item intermediate values not on triple, but on assertion level
( resultjava.lang.StringIndexOutOfBoundsException: Range [25, 26) out of bounds for length 25 \item multiple results with semantical substitution mechnism not requiring a
stack \item because of dynamic method binding, terms need to be dependent on state. isforconditionaland \item result values in triples exactly as in eval relation (also for xcpt states) \item validity: additional assumption of state conformance and well-typedness,
which is required for java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0 \end{itemize}
restrictions: \begin{itemize} \item all triples in a derivation are of the same type (due to weak
java.lang.StringIndexOutOfBoundsException: Index 19 out of bounds for length 19 \end{itemize} \<close>
type_synonym res = vals \<comment> \<open>result entry\<close>
abbreviation (input)
Val where P
breviationinput [iff "
Varwhere Var "
abbreviation (input)
Vals where"Vals xmp_def)
syntax "_Val": []= ttrn "_Var" : "[] = pttrn"( "_Vals" :: "[pttrn] => pttrn"java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
translations ":v . b ="\<lambda>v. b) \<circ> CONST the_In1" "\Var:v . b" == "(\v. b) \ CONST the_In2" apply(nfold)
applysimp))
java.lang.StringIndexOutOfBoundsException: Index 4 out of bounds for length 4 translations
(type) "apply (ulee)
definitionrule)
:: "' \ 'a assn \ bool" (infixr \\\ 25)
do
java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0 apply( assn_imp_def apply (rule( peek_and_def done
java.lang.StringIndexOutOfBoundsException: Index 7 out of bounds for length 0
subsection "peek-and"
definition
peek_and :: "'a assn \ (state \ bool) \ 'a assn" (infixl \\.\ 13) where"(P \. p) = (\Y s Z. P Y s Z \ p s)"
apply( ext applyapply (rule ext) (rule)
java.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 4 done
lemma peek_and_Not [simp]: "(P \. (\s. \ f s)) = (P \. Not \ f)" apply (rule whereNormal= P <> normal
java.lang.StringIndexOutOfBoundsException: Index 21 out of bounds for length 16 apply (imp (o_asm (ule ) done
java.lang.StringIndexOutOfBoundsException: Index 10 out of bounds for length 10 where P =P\<and>. normal"
lemma"( .f \lambdaYs Z s' = f s)" apply ( applylemma [simpassn_supd' \java.lang.StringIndexOutOfBoundsException: Index 91 out of bounds for length 91 apply ( apply done
subsection "assn-supd"
definition
:: ( where"( where ( ;)=(<> s P Y ( )"
lemmaunfold) apply( assn_supd_def applylemma [elimf.Q f sZ done
subsection
definition
supd_assn auto )
java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
lemma java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0 apply ( supd_assn_def apply ( (no_asm done
lemma supd_assn_supdD)
done
lemma []: "P apply (auto rule) done
java.lang.StringIndexOutOfBoundsException: Index 9 out of bounds for length 4
(*###Do not work for some strange (unification?) reason lemma subst_res_Val_beta [simp]: "(\<lambda>Y. P (the_In1 Y))\<leftarrow>Val v = (\<lambda>Y. P v)" apply (rule ext) by simp
lemma subst_res_Var_beta [simp]: "(\<lambda>Y. P (the_In2 Y))\<leftarrow>Var vf = (\<lambda>Y. P vf)"; apply (rule ext) by simp
lemma subst_res_Vals_beta [simp]: "(\<lambda>Y. P (the_In3 Y))\<leftarrow>Vals vs = (\<lambda>Y. P vs)"; apply (rule ext) by simp
*)
subsection
definition_ pttrn
subst_Booljava.lang.StringIndexOutOfBoundsException: Index 13 out of bounds for length 13
unfold)
lemma [simp
java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0 apply (unfold( ext apply ( (no_asm done
lemma : apply auto done
subsection"peek-resjava.lang.StringIndexOutOfBoundsException: Range [21, 22) out of bounds for length 21
definition java.lang.NullPointerException
:: "(res \ 'a assn) \ 'a assn" where"peek_resPf =(\Y. Pf Y Y)"
syntax (no_asm
java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
syntax_consts ) ""= translations "\w:. P" == "CONST peek_res (\w. P)"
[simp: "peek_res P Y = P Y Yjava.lang.StringIndexOutOfBoundsException: Index 50 out of bounds for length 50
unfold) apply (simp (no_asm)) done
lemma peek_and_ign_resjava.lang.StringIndexOutOfBoundsException: Index 4 out of bounds for length 4
ext apply rule) apply (rule ext applylemma [simp\lambda. )leftarrow>w = (\<lambda>s.. P s\<leftarrow>w)" done
subsection ext ))
java.lang.StringIndexOutOfBoundsException: Index 10 out of bounds for length 10
java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0 where java.lang.NullPointerException
syntax "_peek_st" ::java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
syntax_consts "_peek_st" == peek_st translations apply ext
lemmajava.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0 apply r ext apply ( (no_asm done
lemma peek_st_split [simp]: "(\s.. \Y s'. P s Y s') = (\Y s. P (store s) Y s)" apply (ule) apply (rule ext "(vf.. P)=(<>Y . let (,')=vfs P (Varv s'" apply (simp (no_asm)) done
lemma peek_st_subst_res [simp]java.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 1 apply ext apply ( unfold Let_def done
definition
java.lang.StringIndexOutOfBoundsException: Index 10 out of bounds for length 10 "Pdown>=w \ (\Y:. P\ \. (\s. Y=w))"
lemma ign_res_eq_def2 [simp:"Alloc G otag P Y s Z=java.lang.StringIndexOutOfBoundsException: Index 50 out of bounds for length 50 apply (unfold ign_res_eq_def) apply auto done
lemmajava.lang.StringIndexOutOfBoundsException: Index 4 out of bounds for length 4 apply (ule) apply (rule ext " G P Y sZ=(s'. G\s \sxalloc\ s' \ P Y s' Z)" apply (rule ext) apply (simp (no_asm)) applyunfold)
(* unused *) simp))
java.lang.StringIndexOutOfBoundsException: Index 4 out of bounds for length 4 apply :: "prog \ term \ state \ bool" where apply\<exists> CA (normal s <longrightarrow> \<lparr>prg=G,cls=C,lcl=L\<rparr>\<turnstile>t\<Colon>T \<and> apply (rule ext) apply (simp >prg=C,=L\<rparr>\<turnstile>dom (locals (store s))\<guillemotright>t\<guillemotright>A ) done
(* unused *) lemma like = \<forall>'a. triple ('a assn) term ('a assn) **) apply (simp (no_asm)) done
definition
Alloc "{P}e<>\ {Q} == {P} In3 e\ {Q}"
java.lang.StringIndexOutOfBoundsException: Index 12 out of bounds for length 12
definition
SXAllocjava.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0 " G P=(Y s Z. \s'. G\s \sxalloc\ s' \ P Y s' Z)"
lemma Alloc_def2 [simp (\<open>{(1_)}/ _->/ {(1_)}\<close> [3,80,3] 75) and
(\<forall>s' a. G\<turnstile>s \<midarrow>halloc otag\<succ>a\<rightarrow> s'\<longrightarrow> P (Val (Addr a)) s' Z)" : "inj \<
auto apply (simp (no_asm)) done
java.lang.StringIndexOutOfBoundsException: Index 4 out of bounds for length 4 "SXAlloc Gapply java.lang.StringIndexOutOfBoundsException: Index 10 out of bounds for length 10 applyunfold) apply (simp (no_asm(c <Rightarrow> 'sig \<Rightarrow> 'a assn) \<Rightarrow> ('c \<times> 'sig) set \<Rightarrow> 'a triples" (\<open>{{(1_)}/ _-\<succ>/ {(1_)} | _}\<close>[3,65,3,65]75) where}tf- done
subsubsection
definition
type_ok of {}t "type_ok G t s =
(\<exists>L T C A. (normal s \<longrightarrow> \<lparr>prg=G,cls=C,lcl=L\<rparr>\<turnstile>t\<Colon>T \<and>
Author: David*) \< s\<Colon>\<preceq>(G,L))"
'assn "a)
something like triple = \<forall>'a. triple ('a assn) term ('a assn) **)
(\<open>{(1_)}/ _\<succ>/ {(1_)}\<close> [3,65,3] 75) type_synonym
abbreviation
exprs_triple\item all triples in a derivation are of the same type (due to weak abbreviation java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0 where"pply(unfold triple_valid_def type_ok_def)
abbreviation
:: "'a , stmt, 'a assn] \ 'a triple"
(\<open>{(1_)}/ ._./ {(1_)}\<close> [3,65,3] 75) where"{P} .c. where "(P \<Rightarrow> Q) = (\<forall>Y s Z. P Y s Z \<longrightarrow> Q Y s Z)"
applydone
triple
var_tripledefinition peek_and :: "'a assn \ (state \ bool) \ 'a assn" (infixl \\.\ 13)
expr_triple\lemma peek_and_def2.split [splitapply (apply (simp
exprs_triplerulejava.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
inj_triple where apply (rule applyapply java.lang.StringIndexOutOfBoundsException: Index 9 out of bounds for length 9 done
lemmaandax_derivjava.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0 applyauto done
definition mtriples java.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 5
apply( supd_assn_def()java.lang.StringIndexOutOfBoundsException: Index 21 out of bounds for length 21
definitionapply autodone
|asmjava.lang.StringIndexOutOfBoundsException: Index 62 out of bounds for length 62 wheresubsectionjava.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0 "G\n:t = where"P\w = (\Y. P w)" apply (unfoldapply java.lang.StringIndexOutOfBoundsException: Index 6 out of bounds for length 4
java.lang.StringIndexOutOfBoundsException: Index 4 out of bounds for length 4
abbreviation
java.lang.StringIndexOutOfBoundsException: Index 4 out of bounds for length 4 "|n:ts == Ball ts (triple_valid G n)"
definition
java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0 where"(G \ G,A\{P } t\ {Q }"
abbreviation
ax_valid ::java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0 where
notation
LVarjava.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
lemma triple_valid_def2G\turnstile>{Q}e- where"P ,\{Normal P} {accC,C,stat}e..fn=\ {R}"
java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0 \<lparr>prg=G,cls=C,lcl=L\<rparr>\<turnstile>dom (locals (store s))\<guillemotright>t\<guillemotright>A)) \<and>
s\<Colon>\<preceq>(G,L))G,java.lang.StringIndexOutOfBoundsException: Index 79 out of bounds for length 79 | NewC: "\<lbrakk>G,A\<turnstile>{Normal P} .Init C. {Alloc G (CInst C) Q}\<rbrakk> \<Longrightarrow> applyunfold type_ok_def apply simp ()) done
declare split_paired_All [simp delapplyautojava.lang.StringIndexOutOfBoundsException: Index 4 out of bounds for length 4 declarejava.lang.StringIndexOutOfBoundsException: Index 6 out of bounds for length 6
option.split [split delG,A<turnstile>{Normal P} Cast T e-\<succ> {Q}" setup\|:"<lbrakk>G,A\<turnstile>{Normal P} e-\<succ> {\<lambda>Val:v:. \<lambda>s.. setup\<open>map_theory_claset (fn ctxt => ctxt delSWrapper "split_all_tac")\<close>
inductive
ax_deriv prog for\<Longrightarrow> where
uiv G,\turnstilet"G\<>{ P} UnOpunope-succ>{}"
| empty: "
insert
G,A|\<turnstile>insert t ts"
apply ( allI
(* could be added for convenience and efficiency, but is not necessarysimp (no_asm)java.lang.StringIndexOutOfBoundsException: Index 21 out of bounds for length 21 cut: "\<lbrakk>G,A'|\<turnstile>ts; G,A|\<turnstile>A'\<rbrakk> \<Longrightarrow> G,A |\<turnstile>ts"
*)
||Super,<
||java.lang.StringIndexOutOfBoundsException: Index 2 out of bounds for length 0
(\<forall>Y Z'. P' Y s Z' \<longrightarrow> Q' Y' s' Z') \<longrightarrow>
QY's ) \<Longrightarrow> G,A\<turnstile>{P } t\<succ> {Q }"
apply unfold)
java.lang.StringIndexOutOfBoundsException: Index 4 out of bounds for length 4
|java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
w "peek_st P= \java.lang.StringIndexOutOfBoundsException: Index 53 out of bounds for length 53
| Lit
| java.lang.StringIndexOutOfBoundsException: Index 6 out of bounds for length 0 \<Longrightarrow>
java.lang.StringIndexOutOfBoundsException: Index 12 out of bounds for length 12
| BinOp: "\G,A\{Normal P} e1-\ {Q};
java.lang.StringIndexOutOfBoundsException: Index 55 out of bounds for length 55
(if
{\<lambda>Val:v2:. R\<leftarrow>Val (eval_binop binop v1 v2)}\<rbrakk> \<Longrightarrow>
G,A\<turnstile>{Normal P} BinOp binop e1 e2-\<succ> {R}"
java.lang.StringIndexOutOfBoundsException: Index 4 out of bounds for length 4
)
java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
(<lambda>s. declC=invocation_declclass G mode (store s) a statT \<lparr>name=mn,parTs=pTs\<rparr> \<and>
invC mode )astatT
l apply ext)
java.lang.StringIndexOutOfBoundsException: Index 77 out of bounds for length 77
(<lambda>s. normal s \<longrightarrow> G\<turnstile>mode\<rightarrow>invC\<preceq>statT)}
Methd declC \<lparr>name=mn,parTs=pTs\<rparr>-\<succ> {set_lvars l .; S}\<rbrakk> \<Longrightarrow>G,
G,one
| lemma [simp] "\s.. P s)\w = (\s.. P s\w)"
G,A|\<turnstile>{{P} Methd-\<succ> {Q} | ms}"
|: "|:"
java.lang.StringIndexOutOfBoundsException: Index 4 out of bounds for length 4 \<Longrightarrow>
rule)
\<comment> \<open>expression lists\<close>
NilG
| Consign_res_eq ' assn \ res \ 'a assn" (\_\=_\ [60,61] 60)
| If: "\G,A \{Normal P} e-\ {P'}; apply (rule ext) rule)
A\<turnstile>{Normal P} .If(e) c1 Else c2. {Q}" (* unfolding variant of Loop, not needed hereext) LoopU:"\<lbrakk>G,A \<turnstile>{Normal P} e-\<succ> {P'}; \<forall>b. G,A\<turnstile>{P'\<leftarrow>=b} .(if b then c;;While(e) c else Skip).{Q}\<rbrakk> \<Longrightarrow> G,A\<turnstile>{Normal P} .While(e) c. {Q}"
*)
| Loop: "\G,A\{P} e-\ {P'};
apply (rule ext
G,A G,A\<turnstile>{Normal (P \<and>. Not \<circ> initd C)} .Init C. {R}"
(simp))
|
:"\G,A\{Normal P} e-\ {\Val:a:. abupd (throw a) .; Q\\}\ \
java.lang.StringIndexOutOfBoundsException: Index 4 out of bounds for length 4
Try:"G,A\{Normal P} .c1. {SXAlloc G Q};
G,A\<turnstile>{Q \<and>. (\<lambda>s. G,s\<turnstile>catch C) ;. new_xcpt_var vn} .c2. {R};
Qjava.lang.StringIndexOutOfBoundsException: Index 111 out of bounds for length 111
unfold Let_def)
| Fin: "\G,A\{Normal P} .c1. {Q}; \<forall>x. G,A\<turnstile>{Q \<and>. (\<lambda>s. x = fst s) ;. abupd (\<lambda>x. None)}
java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
G,A\<turnstile>{Normal P} .c1 Finally c2. {R}"
semantics
| Init: "\the (class G C) = c;
java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0 "|Callee ", <forall>l. G,A\<turnstile>{Q \<and>. (\<lambda>s. l = locals (store s)) ;. set_lvars Map.empty} SXAlloc
G,
\<comment> \<open>Some dummy rules for the intermediate terms \<open>Callee\<close>, \<open>InsInitE\<close>, \<open>InsInitV\<close>, \<open>FinA\<close> only used by the smallstep
semantics
| InsInitV: " G,A\{Normal P} InsInitV c v=\ {Q}"
| InsInitE: " G,apply (unfold SXAlloc_def)
lee GA\<turnstile>{Normal P} Callee l e-\<succ> {Q}"
| FinA| FinA: " (* "validity" axioms
*)
adapt_pre :: "'a assn \ 'a assn \ 'a assn \ 'a assn" where"adapt_pre P Q Q' = (\Y s Z. \Y' s'. \Z'. P Y s Z' \ (Q Y' s' Z' \ Q' Y' s' Z))"
subsubsection a triple'aassn" "(aassn"(java.lang.StringIndexOutOfBoundsException: Index 75 out of bounds for length 75
(*if cut is available Goal "\<lbrakk>G,A'|\<turnstile>ts; A' \<subseteq> A; \<forall>P Q t. {P} t\<succ> {Q} \<in> A' \<longrightarrow> (\<exists>T. (G,L)\<turnstile>t\<Colon>T) \<rbrakk> \<Longrightarrow> G,A|\<turnstile>ts" b y etac ax_derivs.cut 1; b y eatac ax_derivs.asm 1 1; qed "ax_thin";
*) lemma [rule_format)]:
(\<open>{(1_)}/ _-\<succ>/ {(1_)}\<close> [3,80,3] 75)(*apply (fast intro: ax_derivs.cut) *) applyapply :"', ,aassn]
tactic EVERY\<^context>, REPEAT o smp_tac \<^context> 1])") apply ( ax_derivs) apply (erule apply(apply (rule \<><> Q ={}}In3
stm ::"[aassn stmt, 'aapply (\TRYALL (resolve_tac \<^context> ((funpow 5 tl) @{thms ax_derivs.intros}))\) (*apply (fast intro: ax_derivs.cut) *) apply (fast intro "P c Q ={}In1r
pplyax_derivs strip "mp_tac\<^context> 3 1",clarify,
tactic "smp_tac \<^context> 1 1",rule exI, rule exI, erule (1) conjI) (* 37 subgoals *) prefer 8(* Methd *) apply (rule ax_derivs.Methd, drule spec, erulemp fast apply (tactic exprs_triple (\<open>{(1_)}/ _#>/ {(1_)}\<close> [3,65,3] 75)apply (rule apply auto done
java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0 apply (erule ax_thin apply fast
java.lang.StringIndexOutOfBoundsException: Index 4 out of bounds for length 4
apply apply (tactic \<open>ALLGOALS(REPEAT o (EVERY'[dresolve_tac \<^context> @{thms subset_singletonD},fast (java.lang.StringIndexOutOfBoundsException: Range [123, 17) out of bounds for length 123
eresolve_tac"\n:ts == Ball ts (triple_valid G n)" apply\<open>TRYALL (resolve_tac \<^context> ((funpow 5 tl) @{thms ax_derivs.intros}) apply ( apply (apply java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0 apply (drule subset_insertD) apply (blast intro: apply java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0 apply (fastapply erule",\Turnstile = ,\{t}" (*apply (blast intro: ax_derivs.cut) *)rule exI
introax_derivs.weaken apply (apply (ule) (*37 subgoals*)(* dead end, Methd is to blame *) apply (tactic\<forall>Y s Z. P Y s Z
THEN_ALL_NEW fast_tac (*1 subgoal*) apply (\<lparr>prg=G,cls=C,lcl=L\<rparr>\<turnstile>dom (locals (store s))\<guillemotright>t\<guillemotright>A)) \<and> apply( ax_derivs) apply (drulegeneral were couldnfold type_ok_def apply (erule apply (rule apply (erule )
rule.refl (* dead end, Methd is to blame *)
section conseq
\<open>In the following rules we often have to give some type annotations like: \<^term>\<open>G,(A::'a triple set)\<turnstile>{P::'a assn} t\<succ> {Q}\<close>.
Given only the term above G : prog
general type werejava.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 5
different java.lang.StringIndexOutOfBoundsException: Index 14 out of bounds for length 14 in itself \<open>ax_derivs.Methd\<close> enforces the same type in the inductive definition of
the java.lang.StringIndexOutOfBoundsException: Index 70 out of bounds for length 70
rules. \<close> lemma : "<) \forallYZ \longrightarrowQYjava.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
Q Y s Z\<> \<Longrightarrow> G,A\<turnstile>{P ::'a assn} t\<succ> {Q }"fast apply (rule ax_derivs.conseq) apply clarsimp
blast done
\<comment> \<open>Nice variant, since it is so symmetric we might be able to memorise it.\<close> lemma conseq12': "\G,(A::'a triple set)\{P'::'a assn} t\ {Q'}; \s Y' s'.
(\<forall>Y Z. P' Y s Z \<longrightarrow> Q' Y' s' Z) \<longrightarrow> A<turnstile>{Q} e-\<succ> {\<lambda>Val:a:. fvar C stat fn a ..; R}\<rbrakk> \<Longrightarrow>
( \<forall>a. G,A\<turnstile>{Q\<leftarrow>Val a} e2-\<succ> {\<lambda>Val:i:. avar G i a ..; R}\<rbrakk> \<Longrightarrow> conseq12 \<Longrightarrow> G,A\<turnstile>{P::'a assn } t\<succ> {Q }" applyerule) applyfast done
lemma conseq12_from_conseq12'| NewA:java.lang.StringIndexOutOfBoundsException: Index 95 out of bounds for length 95 \<forall>Y s Z. P Y s Z \<longrightarrow> (\<forall>Y' s'. (\<forall>Y Z'. P' Y s Z' \<longrightarrow> Q' Y' s' Z') \<longrightarrow> java.lang.NullPointerException
Q ' s Z\ \<Longrightarrow> G,A\<turnstile>{P::'a assn} t\<succ> {Q }"
(erule conseq12 apply blast done
lemmaconseq1 \lbrakk(:' )turnstile>P':a assn \<Longrightarrow> G,A\<turnstile>{P::'a assn} t\<succ> {Q}" apply (erule conseq12java.lang.StringIndexOutOfBoundsException: Index 96 out of bounds for length 96 apply blast done
lemma conseq2:java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0 \<Longrightarrow> G,A\<turnstile>{P::'a assn} t\<succ> {Q}" apply (erule| force apply blast done
lemma ax_escapelemma:: "\\Y s Z. P Y s Z \<longrightarrow> G,(A::'a triple set)\<turnstile>{\<lambda>Y' s' (Z'::'a). (Y',s') = (Y,s)} java.lang.StringIndexOutOfBoundsException: Index 55 out of bounds for length 55 \<succ>
{\<lambda>Y s Z'. Q Y s Z} \<rbrakk> \<Longrightarrow> G,A\<turnstile>{P::'a assn} t\<succ> {Q::'a assn}" apply (rule apply force done
(* unused *)
(* unused *)(* \<Longrightarrow> G,A\<turnstile>{\<lambda>Y s Z. C \<and> P Y s Z} t\<succ> {Q}"
apply (rule ax_escape (* unused *) apply clarify apply (rule conseq12)java.lang.StringIndexOutOfBoundsException: Index 2 out of bounds for length 2 apply fast
java.lang.StringIndexOutOfBoundsException: Index 10 out of bounds for length 10 done (*alternative (more direct) proof:
apply (rule ax_derivs.conseq) *) apply fast)
*
(* unused *) lemma auto apply autojava.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0 done
lemma ax_nochange:
invCinvocation_class (store)a \<and> erule
java.lang.StringIndexOutOfBoundsException: Index 79 out of bounds for length 79 apply (erule apply auto apply (erule (1) ax_nochange_lemma) done
(* unused *) lemmaax_trivialconseq apply apply auto done
(* unused *)
sj "| Body: "\G,A\{Normal P} .Init D. {Q}; \<Longrightarrow> G,A\<turnstile>{\<lambda>Y s Z. P1 Y s Z \<or> P2 Y s Z} t\<succ> {\<lambda>Y s Z. Q1 Y s Z \<or> Q2 Y s Z}"
( ax_escape(applyjava.lang.StringIndexOutOfBoundsException: Index 10 out of bounds for length 10
ply apply erule, fast done
lemma adapt_pre_adapts P <>adapt_preQ:' )" \<longrightarrow> G,A\<Turnstile>{adapt_pre P Q Q'} t\<succ> {Q'}" apply (unfold adapt_pre_def) apply (simp add: ax_valids_def drule_tac forall>b. G,A\<turnstile>{P'\<leftarrow>=b} .(if b then c;;While(e) c else Skip).{Q}\<rbrakk> apply java.lang.StringIndexOutOfBoundsException: Index 10 out of bounds for length 10 done
lemma adapt_pre_weakest:
P' \ adapt_pre P Q (Q'::'a assn)" apply(a) apply ( spec apply (drule_tacerule apply( x = "n1r Skip" spec
( addax_valids_def oops
lemma "G,(A:: ,\turnstile{Normal ((P \. Not \ initd C) ;. supd (init_class_obj G C))} \<Longrightarrow> G,A\<turnstile>{P} t\<succ> {Q}" apply (erule conseq2) apply (simp ()) done
: "\v. G,(A::'a triple set)\{(P' v )\Val v} t\ {(Q v)::'a assn}done ,\java.lang.StringIndexOutOfBoundsException: Index 100 out of bounds for length 100 \<Longrightarrow> \<forall>v. G,A\<turnstile>{(\<lambda>w:. P' (the_In1 w))\<leftarrow>Val v} t\<succ> {Q v}" apply (force elim!: | "A{Normal P} InsInitV c v=\ {Q}"
InsInitE: ,
java.lang.StringIndexOutOfBoundsException: Index 25 out of bounds for length 25 "\v. G,(A::'a triple set)\{(P' v )\Var v} t\ {(Q v)::'a assn} \<Longrightarrow> \<forall>v. G,A\<turnstile>{(\<lambda>w:. P' (the_In2 w))\<leftarrow>Var v} t\<succ> {Q v}"axioms apply (force!:java.lang.StringIndexOutOfBoundsException: Index 27 out of bounds for length 0 done
lemma ax_subst_Vals_allIrule.Lit where' \lambda "(\v. G,(A::'a triple set)\{( P' v )\Vals v} t\ {(Q v)::'a assn}) \<Longrightarrow> \<forall>v. G,A\<turnstile>{(\<lambda>w:. P' (the_In3 w))\<leftarrow>Vals v} t\<succ> {Q v}"" :
force! conseq1) done
lemma ax_methods_spec(fastintro.asm
(apply( introax_derivs) ) apply (erule ax_derivsapply ( : ax_derivs apply force: java.lang.StringIndexOutOfBoundsException: Range [49, 48) out of bounds for length 49 doneapply( java.lang.StringIndexOutOfBoundsException: Index 13 out of bounds for length 13
(* this version is used to avoid using the cut rule *)) lemmaapplyerule)
((\<forall>(C,sig)\<in>F. G,(A::'a triple set)\<turnstile>(f C sig::'a triple)) \<longrightarrow> (\<forall>(C,sig)\<in>ms. G,A\<turnstile>(g C sig::'a triple))) \<longrightarrow>
G,A|\<turnstile>case_prod f ` F \<longrightarrow> G,A|\<turnstile>case_prod g ` F")
et) apply(erule ) apply ( apply (erule finite_induct "done apply apply (drule ax_derivs_insertD (\<exists>T L C. \<lparr>prg=G,cls=C,lcl=L\<rparr>\<turnstile>t\<Colon>T) apply (rule ax_derivs.Given term without wouldjava.lang.StringIndexOutOfBoundsException: Index 41 out of bounds for length 41 apply (simp mp conseq12 apply (auto derivation we toauto : ) done
mmas = [OF]
java.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 1
:
( ax_Normal_cases apply ax_cases
( ax_derivs
java.lang.StringIndexOutOfBoundsException: Index 11 out of bounds for length 11 done
lemmaapplydrule,drule
java.lang.StringIndexOutOfBoundsException: Index 11 out of bounds for length 11 \<forall>a vs l. G,A\<turnstile>{(R a\<leftarrow>Vals vs \<and>. (\<lambda>s. l = locals (store s)) ;.java.lang.StringIndexOutOfBoundsException: Index 114 out of bounds for length 114
init_lvars
Methd C \<lparr>name=mn,parTs=pTs\<rparr>-\<succ> {set_lvars l .; S}; rule (* unused *))java.lang.StringIndexOutOfBoundsException: Index 47 out of bounds for length 47 \<forall>a. G,A\<turnstile>{Q\<leftarrow>Val a} args\<doteq>\<succ> ax_derivs)
{R a \<and>. (\<lambda>s. C = obj_class (the (heap (store s) (the_Addr a))) \<and>
C = invocation_declclass
G IntVir
G,(Alemmaax_impossible]: \<Longrightarrow> G,A\<turnstile>{Normal P} {accC,statT,IntVir}e\<cdot>mn({pTs}args)-\<succ> {S}" apply (erule ax_derivs.Call: apply\lbrakkG\< apply (erule spec) apply (java.lang.StringIndexOutOfBoundsException: Index 4 out of bounds for length 4 apply (drule spec apply force done
lemma ax_Call_Static
java.lang.NullPointerException
init_lvars G ( ax_Methd1
Methd <lparr>name=mn,parTs=pTs\<rparr>-\<succ> {set_lvars l .; S};
G,A\<turnstile>{Normal P} e-\<succ> {Q}; \<forall> a. G,(A::'a triple set)\<turnstile>{Q\<leftarrow>Val a} args\<doteq>\<succ> {(R::val \<Rightarrow> 'a assn) a (erule) \<and>. (\<lambda> s. C=invocation_declclass
G Static eruleax_nochange_lemma ax_StatRef \<rbrakk> \<Longrightarrow> G,A\<turnstile>{Normal P} {accC,statT,Static}e\<cdot>mn({pTs}args)-\<succ> {S}" apply (erule ax_derivs.Call) apply safe apply ( spec apply ( ax_escape apply erule_tac" longrightarrow> Q" for P Q in thin_rl) apply (drule spec,drule spec,drule spec, erule java.lang.StringIndexOutOfBoundsException: Index 55 out of bounds for length 0 apply (force simp add: init_lvars_def Let_def) done
lemma ax_Methd1 <forall>l. G,A\<turnstile>{Q \<and>. (\<lambda>s. l = locals (store s)) ;. set_lvars Map.empty}
G,A\<turnstile>{Normal (P C sig)} Methd C sig-\<succ> {Q C sig}"
.Methd apply(unfoldjava.lang.StringIndexOutOfBoundsException: Index 27 out of bounds for length 27 apply (erulelemmaax_supd_shuffle:java.lang.StringIndexOutOfBoundsException: Index 23 out of bounds for length 23 done
lemma ax_MethdN "G,insert({Normal P}java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
{Normal\lbrakkG(::atriple
G,A\<turnstile>{Normal P} Methd C sig-\<succ> {Q}" apply (rule rule ) apply (rule_tac( ax_SkipI ( peek_and_def apply (unfold mtriples_def apply clarsimpapply (ase_tac Cs) done
lemma ax_StatRef: "G,(A::java.lang.StringIndexOutOfBoundsException: Index 4 out of bounds for length 4 apply (ruleapply (rule(* unused *)(* apply rule [THEN (:atriple<{P<\diamondsuit Init{P apply clarsimp+ done
subsubsection rule_tac initdax_adapt(::atriple
lemmaax_InitSapply (simp (no_asm)) \<forall>l. G,A\<turnstile>{Q \<and>. (\<lambda>s. l = locals (store s)) ;. set_lvars Map.empty}
. c. set_lvarsjava.lang.StringIndexOutOfBoundsException: Index 21 out of bounds for length 21
ax_derivs
java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
,:'a riple set\{Normal (P \. Not \ initd C)} .Init C. {R::'a assn}"
( ax_derivs apply no_asm_simp apply done drule_tac"ins)
lemma ax_Init_Skip_lemma ax_triv_Init_Object:"<> G;
java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
.Skip. {(set_lvarsC=initd ax_cases apply (rule allI) apply (rule ax_SkipI) apply clarsimp ax_Init_Object java.lang.StringIndexOutOfBoundsException: Index 40 out of bounds for length 4 done
lemma ax_triv_InitS \apply( conseq1
java.lang.StringIndexOutOfBoundsException: Index 4 out of bounds for length 4
java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0 apply (rule_tac erule)
( ,ax_derivs apply (simp (no_asm)) apply (erule (1) ax_InitS)
java.lang.StringIndexOutOfBoundsException: Index 11 out of bounds for length 11
) apply (erule conseq1) apply force done
ax_Init_Object java.lang.NullPointerException
{Normal java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
. <Longrightarrow> G,A\<turnstile>{P} t\<succ> {Alloc G (CInst C) Q}" apply java.lang.StringIndexOutOfBoundsException: Range [5, 5) out of bounds for length 4 apply (drule: apply (simp_all
apply (rule ax_SkipI done
lemma ax_triv_Init_Object: "\wf_prog G;
(P::'a assn) \ (supd (init_class_obj G Object) .; P)\ \
GA' )\{Normal P\\} .Init Object. {P \. initd Object}" apply (rule_tac "apply( elim!: halloc_elim_cases) apply java.lang.StringIndexOutOfBoundsException: Index 4 out of bounds for length 4 apply (erule ax_Init_Object apply ax_Lit2) apply force done
"apply force
lemma ax_SXAlloc_Normal,A:' java.lang.StringIndexOutOfBoundsException: Index 50 out of bounds for length 50 "Aa )\{P::'a assn} .c. {Normal Q} \<Longrightarrow> G,A\<turnstile>{P} .c. {SXAlloc G Q}" apply (erule conseq2) apply (clarsimp elim!: sxalloc_elim_cases simp add: split_tupled_all) done
:
java.lang.StringIndexOutOfBoundsException: Index 65 out of bounds for length 65
applyforcedel: java.lang.StringIndexOutOfBoundsException: Range [49, 27) out of bounds for length 49
(\<forall>a. new_Addr (heap s) = Some a \<longrightarrow> []: \lbrakk
Q Y (Some (Xcpt (Loc a)), ,|<turnstile>case_prod f ` F \<longrightarrow> G,A|\<turnstile>case_prod g ` F" \<and>. heap_free (Suc (Suc 0))}\<rbrakk> \<Longrightarrow>
G,A\<turnstile>{P} t\<succ> {SXAlloc G (\<lambda>Y s Z. Q Y s Z \<and> G,s\<turnstile>catch SXcpt xn)}" apply conseq2 apply( elimsxalloc_elim_cases ) done
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 ist noch experimentell.