949 While these are anathema for writing proper Isar proof documents, they might |
949 While these are anathema for writing proper Isar proof documents, they might |
950 come in handy for interactive exploration and debugging, or even actual |
950 come in handy for interactive exploration and debugging, or even actual |
951 tactical proof within new-style theories (to benefit from document |
951 tactical proof within new-style theories (to benefit from document |
952 preparation, for example). |
952 preparation, for example). |
953 |
953 |
954 \indexisarcmd{apply}\indexisarcmd{apply-end} |
954 \indexisarcmd{apply}\indexisarcmd{done}\indexisarcmd{apply-end} |
955 \indexisarcmd{defer}\indexisarcmd{prefer}\indexisarcmd{back} |
955 \indexisarcmd{defer}\indexisarcmd{prefer}\indexisarcmd{back} |
956 \indexisarmeth{tactic}\indexisarmeth{insert} |
956 \indexisarmeth{tactic}\indexisarmeth{insert} |
957 \indexisarmeth{res-inst-tac}\indexisarmeth{eres-inst-tac} |
957 \indexisarmeth{res-inst-tac}\indexisarmeth{eres-inst-tac} |
958 \indexisarmeth{dres-inst-tac}\indexisarmeth{forw-inst-tac} |
958 \indexisarmeth{dres-inst-tac}\indexisarmeth{forw-inst-tac} |
959 \indexisarmeth{subgoal-tac} |
959 \indexisarmeth{subgoal-tac} |
960 \begin{matharray}{rcl} |
960 \begin{matharray}{rcl} |
961 \isarcmd{apply}^* & : & \isartrans{proof(prove)}{proof(prove)} \\ |
961 \isarcmd{apply}^* & : & \isartrans{proof(prove)}{proof(prove)} \\ |
|
962 \isarcmd{done}^* & : & \isartrans{proof(prove)}{proof(state)} \\ |
962 \isarcmd{apply_end}^* & : & \isartrans{proof(state)}{proof(state)} \\ |
963 \isarcmd{apply_end}^* & : & \isartrans{proof(state)}{proof(state)} \\ |
963 \isarcmd{defer}^* & : & \isartrans{proof}{proof} \\ |
964 \isarcmd{defer}^* & : & \isartrans{proof}{proof} \\ |
964 \isarcmd{prefer}^* & : & \isartrans{proof}{proof} \\ |
965 \isarcmd{prefer}^* & : & \isartrans{proof}{proof} \\ |
965 \isarcmd{back}^* & : & \isartrans{proof}{proof} \\ |
966 \isarcmd{back}^* & : & \isartrans{proof}{proof} \\ |
966 tactic^* & : & \isarmeth \\ |
967 tactic^* & : & \isarmeth \\ |
1010 \end{rail} |
1013 \end{rail} |
1011 |
1014 |
1012 \begin{descr} |
1015 \begin{descr} |
1013 \item [$\isarkeyword{apply}~(m)$] applies proof method $m$ in initial |
1016 \item [$\isarkeyword{apply}~(m)$] applies proof method $m$ in initial |
1014 position, but unlike $\PROOFNAME$ it retains ``$proof(prove)$'' mode. Thus |
1017 position, but unlike $\PROOFNAME$ it retains ``$proof(prove)$'' mode. Thus |
1015 consecutive method applications may be given just as in tactic scripts. In |
1018 consecutive method applications may be given just as in tactic scripts. |
1016 order to complete the proof properly, any of the actual structured proof |
|
1017 commands (e.g.\ ``$\DOT$'') has to be given eventually. |
|
1018 |
1019 |
1019 Facts are passed to $m$ as indicated by the goal's forward-chain mode, and |
1020 Facts are passed to $m$ as indicated by the goal's forward-chain mode, and |
1020 are \emph{consumed} afterwards. Thus any further $\isarkeyword{apply}$ |
1021 are \emph{consumed} afterwards. Thus any further $\isarkeyword{apply}$ |
1021 command would always work in a purely backward manner. |
1022 command would always work in a purely backward manner. |
|
1023 |
|
1024 \item [$\isarkeyword{done}$] completes a proof script, provided that the |
|
1025 current goal state is solved completely. |
|
1026 |
|
1027 Note that actual structured proof commands (e.g.\ ``$\DOT$'', $\SORRY$) may |
|
1028 be used to conclude proof scripts as well. |
1022 |
1029 |
1023 \item [$\isarkeyword{apply_end}~(m)$] applies proof method $m$ as if in |
1030 \item [$\isarkeyword{apply_end}~(m)$] applies proof method $m$ as if in |
1024 terminal position. Basically, this simulates a multi-step tactic script for |
1031 terminal position. Basically, this simulates a multi-step tactic script for |
1025 $\QEDNAME$, but may be given anywhere within the proof body. |
1032 $\QEDNAME$, but may be given anywhere within the proof body. |
1026 |
1033 |