doc-src/IsarRef/Thy/HOL_Specific.thy
changeset 45232 eb56e1774c26
parent 45192 008710fff1cc
child 45408 7156f63ce3c2
equal deleted inserted replaced
45231:d85a2fdc586c 45232:eb56e1774c26
  1742     @{command_def (HOL) "export_code"}@{text "\<^sup>*"} & : & @{text "context \<rightarrow>"} \\
  1742     @{command_def (HOL) "export_code"}@{text "\<^sup>*"} & : & @{text "context \<rightarrow>"} \\
  1743     @{attribute_def (HOL) code} & : & @{text attribute} \\
  1743     @{attribute_def (HOL) code} & : & @{text attribute} \\
  1744     @{command_def (HOL) "code_abort"} & : & @{text "theory \<rightarrow> theory"} \\
  1744     @{command_def (HOL) "code_abort"} & : & @{text "theory \<rightarrow> theory"} \\
  1745     @{command_def (HOL) "code_datatype"} & : & @{text "theory \<rightarrow> theory"} \\
  1745     @{command_def (HOL) "code_datatype"} & : & @{text "theory \<rightarrow> theory"} \\
  1746     @{command_def (HOL) "print_codesetup"}@{text "\<^sup>*"} & : & @{text "context \<rightarrow>"} \\
  1746     @{command_def (HOL) "print_codesetup"}@{text "\<^sup>*"} & : & @{text "context \<rightarrow>"} \\
  1747     @{attribute_def (HOL) code_inline} & : & @{text attribute} \\
  1747     @{attribute_def (HOL) code_unfold} & : & @{text attribute} \\
  1748     @{attribute_def (HOL) code_post} & : & @{text attribute} \\
  1748     @{attribute_def (HOL) code_post} & : & @{text attribute} \\
       
  1749     @{attribute_def (HOL) code_unfold_post} & : & @{text attribute} \\
  1749     @{command_def (HOL) "print_codeproc"}@{text "\<^sup>*"} & : & @{text "context \<rightarrow>"} \\
  1750     @{command_def (HOL) "print_codeproc"}@{text "\<^sup>*"} & : & @{text "context \<rightarrow>"} \\
  1750     @{command_def (HOL) "code_thms"}@{text "\<^sup>*"} & : & @{text "context \<rightarrow>"} \\
  1751     @{command_def (HOL) "code_thms"}@{text "\<^sup>*"} & : & @{text "context \<rightarrow>"} \\
  1751     @{command_def (HOL) "code_deps"}@{text "\<^sup>*"} & : & @{text "context \<rightarrow>"} \\
  1752     @{command_def (HOL) "code_deps"}@{text "\<^sup>*"} & : & @{text "context \<rightarrow>"} \\
  1752     @{command_def (HOL) "code_const"} & : & @{text "theory \<rightarrow> theory"} \\
  1753     @{command_def (HOL) "code_const"} & : & @{text "theory \<rightarrow> theory"} \\
  1753     @{command_def (HOL) "code_type"} & : & @{text "theory \<rightarrow> theory"} \\
  1754     @{command_def (HOL) "code_type"} & : & @{text "theory \<rightarrow> theory"} \\
  1788     ;
  1789     ;
  1789 
  1790 
  1790     @@{command (HOL) code_datatype} ( const + )
  1791     @@{command (HOL) code_datatype} ( const + )
  1791     ;
  1792     ;
  1792 
  1793 
  1793     @@{attribute (HOL) code_inline} ( 'del' ) ?
  1794     @@{attribute (HOL) code_unfold} ( 'del' ) ?
  1794     ;
  1795     ;
  1795 
  1796 
  1796     @@{attribute (HOL) code_post} ( 'del' ) ?
  1797     @@{attribute (HOL) code_post} ( 'del' ) ?
       
  1798     ;
       
  1799 
       
  1800     @@{attribute (HOL) code_unfold_post}
  1797     ;
  1801     ;
  1798 
  1802 
  1799     @@{command (HOL) code_thms} ( constexpr + ) ?
  1803     @@{command (HOL) code_thms} ( constexpr + ) ?
  1800     ;
  1804     ;
  1801 
  1805 
  1885   for a logical type.
  1889   for a logical type.
  1886 
  1890 
  1887   \item @{command (HOL) "print_codesetup"} gives an overview on
  1891   \item @{command (HOL) "print_codesetup"} gives an overview on
  1888   selected code equations and code generator datatypes.
  1892   selected code equations and code generator datatypes.
  1889 
  1893 
  1890   \item @{attribute (HOL) code_inline} declares (or with option
  1894   \item @{attribute (HOL) code_unfold} declares (or with option
  1891   ``@{text "del"}'' removes) inlining theorems which are applied as
  1895   ``@{text "del"}'' removes) theorems which are applied as
  1892   rewrite rules to any code equation during preprocessing.
  1896   rewrite rules to any code equation during preprocessing.
  1893 
  1897 
  1894   \item @{attribute (HOL) code_post} declares (or with option ``@{text
  1898   \item @{attribute (HOL) code_post} declares (or with option ``@{text
  1895   "del"}'' removes) theorems which are applied as rewrite rules to any
  1899   "del"}'' removes) theorems which are applied as rewrite rules to any
  1896   result of an evaluation.
  1900   result of an evaluation.
  1897 
  1901 
       
  1902   \item @{attribute (HOL) code_unfold_post} declares equations which are
       
  1903   applied as rewrite rules to any code equation during preprocessing,
       
  1904   and symmetrically to any result of an evaluation.
       
  1905   
  1898   \item @{command (HOL) "print_codeproc"} prints the setup of the code
  1906   \item @{command (HOL) "print_codeproc"} prints the setup of the code
  1899   generator preprocessor.
  1907   generator preprocessor.
  1900 
  1908 
  1901   \item @{command (HOL) "code_thms"} prints a list of theorems
  1909   \item @{command (HOL) "code_thms"} prints a list of theorems
  1902   representing the corresponding program containing all given
  1910   representing the corresponding program containing all given