src/Doc/Codegen/Computations.thy
changeset 76987 4c275405faae
parent 76659 2afbd514b654
child 78795 f7e972d567f3
equal deleted inserted replaced
76986:1e31ddcab458 76987:4c275405faae
   261 subsection \<open>Computations using the \<open>computation_conv\<close> antiquotation\<close>
   261 subsection \<open>Computations using the \<open>computation_conv\<close> antiquotation\<close>
   262 
   262 
   263 text \<open>
   263 text \<open>
   264   Computations are a device to implement fast proof procedures.
   264   Computations are a device to implement fast proof procedures.
   265   Then results of a computation are often assumed to be trustable
   265   Then results of a computation are often assumed to be trustable
   266   and thus wrapped in oracles (see @{cite "isabelle-isar-ref"}),
   266   and thus wrapped in oracles (see \<^cite>\<open>"isabelle-isar-ref"\<close>),
   267   as in the following example:\footnote{
   267   as in the following example:\footnote{
   268   The technical details how numerals are dealt with are given later in
   268   The technical details how numerals are dealt with are given later in
   269   \secref{sec:literal_input}.}
   269   \secref{sec:literal_input}.}
   270 \<close>
   270 \<close>
   271 
   271 
   293 \<close>
   293 \<close>
   294 
   294 
   295 text \<open>
   295 text \<open>
   296     \<^item> Antiquotation @{ML_antiquotation computation_conv} basically yields
   296     \<^item> Antiquotation @{ML_antiquotation computation_conv} basically yields
   297       a conversion of type \<^ML_type>\<open>Proof.context -> cterm -> thm\<close>
   297       a conversion of type \<^ML_type>\<open>Proof.context -> cterm -> thm\<close>
   298       (see further @{cite "isabelle-implementation"}).
   298       (see further \<^cite>\<open>"isabelle-implementation"\<close>).
   299 
   299 
   300     \<^item> The antiquotation expects one functional argument to bridge the
   300     \<^item> The antiquotation expects one functional argument to bridge the
   301       \qt{untrusted gap};  this can be done e.g.~using an oracle.  Since that oracle
   301       \qt{untrusted gap};  this can be done e.g.~using an oracle.  Since that oracle
   302       will only yield \qt{valid} results in the context of that particular
   302       will only yield \qt{valid} results in the context of that particular
   303       computation, the implementor must make sure that it does not leave
   303       computation, the implementor must make sure that it does not leave