1884 \end{railoutput} |
1884 \end{railoutput} |
1885 |
1885 |
1886 |
1886 |
1887 \begin{description} |
1887 \begin{description} |
1888 |
1888 |
1889 \item \hyperlink{command.HOL.setup-lifting}{\mbox{\isa{\isacommand{setup{\isaliteral{5F}{\isacharunderscore}}lifting}}}} Sets up the Lifting package to work with |
1889 \item \hyperlink{command.HOL.setup-lifting}{\mbox{\isa{\isacommand{setup{\isaliteral{5F}{\isacharunderscore}}lifting}}}} Sets up the Lifting package |
1890 a user-defined type. The user must provide either a quotient |
1890 to work with a user-defined type. The user must provide either a |
1891 theorem \isa{{\isaliteral{22}{\isachardoublequote}}Quotient\ R\ Abs\ Rep\ T{\isaliteral{22}{\isachardoublequote}}} or a type_definition theorem |
1891 quotient theorem \isa{{\isaliteral{22}{\isachardoublequote}}Quotient\ R\ Abs\ Rep\ T{\isaliteral{22}{\isachardoublequote}}} or a |
1892 \isa{{\isaliteral{22}{\isachardoublequote}}type{\isaliteral{5F}{\isacharunderscore}}definition\ Rep\ Abs\ A{\isaliteral{22}{\isachardoublequote}}}. |
1892 type_definition theorem \isa{{\isaliteral{22}{\isachardoublequote}}type{\isaliteral{5F}{\isacharunderscore}}definition\ Rep\ Abs\ A{\isaliteral{22}{\isachardoublequote}}}. The |
1893 The package configures |
1893 package configures transfer rules for equality and quantifiers on |
1894 transfer rules for equality and quantifiers on the type, and sets |
1894 the type, and sets up the \indexdef{HOL}{command}{lift\_definition}\hypertarget{command.HOL.lift-definition}{\hyperlink{command.HOL.lift-definition}{\mbox{\isa{\isacommand{lift{\isaliteral{5F}{\isacharunderscore}}definition}}}}} |
1895 up the \indexdef{HOL}{command}{lift\_definition}\hypertarget{command.HOL.lift-definition}{\hyperlink{command.HOL.lift-definition}{\mbox{\isa{\isacommand{lift{\isaliteral{5F}{\isacharunderscore}}definition}}}}} command to work with the type. |
1895 command to work with the type. In the case of a quotient theorem, |
1896 In the case of a quotient theorem, |
1896 an optional theorem \isa{{\isaliteral{22}{\isachardoublequote}}reflp\ R{\isaliteral{22}{\isachardoublequote}}} can be provided as a second |
1897 an optional theorem \isa{{\isaliteral{22}{\isachardoublequote}}reflp\ R{\isaliteral{22}{\isachardoublequote}}} can be provided as a second argument. |
1897 argument. This allows the package to generate stronger transfer |
1898 This allows the package to generate stronger transfer rules. |
1898 rules. |
1899 |
1899 |
1900 \hyperlink{command.HOL.setup-lifting}{\mbox{\isa{\isacommand{setup{\isaliteral{5F}{\isacharunderscore}}lifting}}}} is called automatically if a quotient type |
1900 \hyperlink{command.HOL.setup-lifting}{\mbox{\isa{\isacommand{setup{\isaliteral{5F}{\isacharunderscore}}lifting}}}} is called automatically if a |
1901 is defined by the command \hyperlink{command.HOL.quotient-type}{\mbox{\isa{\isacommand{quotient{\isaliteral{5F}{\isacharunderscore}}type}}}} from the Quotient package. |
1901 quotient type is defined by the command \hyperlink{command.HOL.quotient-type}{\mbox{\isa{\isacommand{quotient{\isaliteral{5F}{\isacharunderscore}}type}}}} from the Quotient package. |
1902 |
1902 |
1903 If \hyperlink{command.HOL.setup-lifting}{\mbox{\isa{\isacommand{setup{\isaliteral{5F}{\isacharunderscore}}lifting}}}} is called with a type_definition theorem, |
1903 If \hyperlink{command.HOL.setup-lifting}{\mbox{\isa{\isacommand{setup{\isaliteral{5F}{\isacharunderscore}}lifting}}}} is called with a |
1904 the abstract type implicitly defined by the theorem is declared as an abstract type in |
1904 type_definition theorem, the abstract type implicitly defined by |
1905 the code generator. This allows \hyperlink{command.HOL.lift-definition}{\mbox{\isa{\isacommand{lift{\isaliteral{5F}{\isacharunderscore}}definition}}}} to register |
1905 the theorem is declared as an abstract type in the code |
1906 (generated) code certificate theorems as abstract code equations in the code generator. |
1906 generator. This allows \hyperlink{command.HOL.lift-definition}{\mbox{\isa{\isacommand{lift{\isaliteral{5F}{\isacharunderscore}}definition}}}} to |
1907 The option \isa{{\isaliteral{22}{\isachardoublequote}}no{\isaliteral{5F}{\isacharunderscore}}abs{\isaliteral{5F}{\isacharunderscore}}code{\isaliteral{22}{\isachardoublequote}}} of the command \hyperlink{command.HOL.setup-lifting}{\mbox{\isa{\isacommand{setup{\isaliteral{5F}{\isacharunderscore}}lifting}}}} |
1907 register (generated) code certificate theorems as abstract code |
1908 can turn off that behavior and causes that code certificate theorems generated |
1908 equations in the code generator. The option \isa{{\isaliteral{22}{\isachardoublequote}}no{\isaliteral{5F}{\isacharunderscore}}abs{\isaliteral{5F}{\isacharunderscore}}code{\isaliteral{22}{\isachardoublequote}}} |
1909 by \hyperlink{command.HOL.lift-definition}{\mbox{\isa{\isacommand{lift{\isaliteral{5F}{\isacharunderscore}}definition}}}} are not registred as abstract code equations. |
1909 of the command \hyperlink{command.HOL.setup-lifting}{\mbox{\isa{\isacommand{setup{\isaliteral{5F}{\isacharunderscore}}lifting}}}} can turn off that |
1910 |
1910 behavior and causes that code certificate theorems generated by |
1911 \item \hyperlink{command.HOL.lift-definition}{\mbox{\isa{\isacommand{lift{\isaliteral{5F}{\isacharunderscore}}definition}}}} \isa{{\isaliteral{22}{\isachardoublequote}}f\ {\isaliteral{3A}{\isacharcolon}}{\isaliteral{3A}{\isacharcolon}}\ {\isaliteral{5C3C7461753E}{\isasymtau}}\ is\ t{\isaliteral{22}{\isachardoublequote}}} |
1911 \hyperlink{command.HOL.lift-definition}{\mbox{\isa{\isacommand{lift{\isaliteral{5F}{\isacharunderscore}}definition}}}} are not registred as abstract |
1912 Defines a new function \isa{f} with an abstract type \isa{{\isaliteral{5C3C7461753E}{\isasymtau}}} in |
1912 code equations. |
1913 terms of a corresponding operation \isa{t} on a representation type. |
1913 |
1914 The term \isa{t} doesn't have to be necessarily a constant but it can |
1914 \item \hyperlink{command.HOL.lift-definition}{\mbox{\isa{\isacommand{lift{\isaliteral{5F}{\isacharunderscore}}definition}}}} \isa{{\isaliteral{22}{\isachardoublequote}}f\ {\isaliteral{3A}{\isacharcolon}}{\isaliteral{3A}{\isacharcolon}}\ {\isaliteral{5C3C7461753E}{\isasymtau}}\ is\ t{\isaliteral{22}{\isachardoublequote}}} |
1915 be any term. |
1915 Defines a new function \isa{f} with an abstract type \isa{{\isaliteral{5C3C7461753E}{\isasymtau}}} |
|
1916 in terms of a corresponding operation \isa{t} on a |
|
1917 representation type. The term \isa{t} doesn't have to be |
|
1918 necessarily a constant but it can be any term. |
1916 |
1919 |
1917 Users must discharge a respectfulness proof obligation when each |
1920 Users must discharge a respectfulness proof obligation when each |
1918 constant is defined. For a type copy, i.e. a typedef with \isa{UNIV}, |
1921 constant is defined. For a type copy, i.e. a typedef with \isa{UNIV}, the proof is discharged automatically. The obligation is |
1919 the proof is discharged automatically. The obligation is |
|
1920 presented in a user-friendly, readable form. A respectfulness |
1922 presented in a user-friendly, readable form. A respectfulness |
1921 theorem in the standard format \isa{f{\isaliteral{2E}{\isachardot}}rsp} and a transfer rule \isa{f{\isaliteral{2E}{\isachardot}}tranfer} |
1923 theorem in the standard format \isa{f{\isaliteral{2E}{\isachardot}}rsp} and a transfer rule |
1922 for the Transfer package are generated by the package. |
1924 \isa{f{\isaliteral{2E}{\isachardot}}tranfer} for the Transfer package are generated by the |
|
1925 package. |
1923 |
1926 |
1924 Integration with code_abstype: For typedefs (e.g. subtypes |
1927 Integration with code_abstype: For typedefs (e.g. subtypes |
1925 corresponding to a datatype invariant, such as dlist), |
1928 corresponding to a datatype invariant, such as dlist), \hyperlink{command.HOL.lift-definition}{\mbox{\isa{\isacommand{lift{\isaliteral{5F}{\isacharunderscore}}definition}}}} generates a code certificate theorem |
1926 \hyperlink{command.HOL.lift-definition}{\mbox{\isa{\isacommand{lift{\isaliteral{5F}{\isacharunderscore}}definition}}}} |
1929 \isa{f{\isaliteral{2E}{\isachardot}}rep{\isaliteral{5F}{\isacharunderscore}}eq} and sets up code generation for each constant. |
1927 generates a code certificate theorem \isa{f{\isaliteral{2E}{\isachardot}}rep{\isaliteral{5F}{\isacharunderscore}}eq} and sets up |
|
1928 code generation for each constant. |
|
1929 |
1930 |
1930 \item \hyperlink{command.HOL.print-quotmaps}{\mbox{\isa{\isacommand{print{\isaliteral{5F}{\isacharunderscore}}quotmaps}}}} prints stored quotient map |
1931 \item \hyperlink{command.HOL.print-quotmaps}{\mbox{\isa{\isacommand{print{\isaliteral{5F}{\isacharunderscore}}quotmaps}}}} prints stored quotient map |
1931 theorems. |
1932 theorems. |
1932 |
1933 |
1933 \item \hyperlink{command.HOL.print-quotients}{\mbox{\isa{\isacommand{print{\isaliteral{5F}{\isacharunderscore}}quotients}}}} prints stored quotient theorems. |
1934 \item \hyperlink{command.HOL.print-quotients}{\mbox{\isa{\isacommand{print{\isaliteral{5F}{\isacharunderscore}}quotients}}}} prints stored quotient |
1934 |
1935 theorems. |
1935 \item \hyperlink{attribute.HOL.quot-map}{\mbox{\isa{quot{\isaliteral{5F}{\isacharunderscore}}map}}} registers a quotient map theorem. For examples see |
1936 |
1936 \verb|~~/src/HOL/Library/Quotient_List.thy| or other Quotient_*.thy files. |
1937 \item \hyperlink{attribute.HOL.quot-map}{\mbox{\isa{quot{\isaliteral{5F}{\isacharunderscore}}map}}} registers a quotient map |
1937 |
1938 theorem. For examples see \verb|~~/src/HOL/Library/Quotient_List.thy| or other Quotient_*.thy |
1938 \item \hyperlink{attribute.HOL.invariant-commute}{\mbox{\isa{invariant{\isaliteral{5F}{\isacharunderscore}}commute}}} registers a theorem which shows a relationship |
1939 files. |
1939 between the constant \isa{Lifting{\isaliteral{2E}{\isachardot}}invariant} (used for internal encoding of proper subtypes) |
1940 |
1940 and a relator. |
1941 \item \hyperlink{attribute.HOL.invariant-commute}{\mbox{\isa{invariant{\isaliteral{5F}{\isacharunderscore}}commute}}} registers a theorem which |
1941 Such theorems allows the package to hide \isa{Lifting{\isaliteral{2E}{\isachardot}}invariant} from a user |
1942 shows a relationship between the constant \isa{Lifting{\isaliteral{2E}{\isachardot}}invariant} (used for internal encoding of proper subtypes) |
1942 in a user-readable form of a respectfulness theorem. For examples see |
1943 and a relator. Such theorems allows the package to hide \isa{Lifting{\isaliteral{2E}{\isachardot}}invariant} from a user in a user-readable form of a |
1943 \verb|~~/src/HOL/Library/Quotient_List.thy| or other Quotient_*.thy files. |
1944 respectfulness theorem. For examples see \verb|~~/src/HOL/Library/Quotient_List.thy| or other Quotient_*.thy |
1944 |
1945 files. |
1945 |
1946 |
1946 \end{description}% |
1947 \end{description}% |
1947 \end{isamarkuptext}% |
1948 \end{isamarkuptext}% |
1948 \isamarkuptrue% |
1949 \isamarkuptrue% |
1949 % |
1950 % |
2679 |
2680 |
2680 \item[\isa{locale}] specifies how to process conjectures in |
2681 \item[\isa{locale}] specifies how to process conjectures in |
2681 a locale context, i.e., they can be interpreted or expanded. |
2682 a locale context, i.e., they can be interpreted or expanded. |
2682 The option is a whitespace-separated list of the two words |
2683 The option is a whitespace-separated list of the two words |
2683 \isa{interpret} and \isa{expand}. The list determines the |
2684 \isa{interpret} and \isa{expand}. The list determines the |
2684 order they are employed. The default setting is to first use |
2685 order they are employed. The default setting is to first use |
2685 interpretations and then test the expanded conjecture. |
2686 interpretations and then test the expanded conjecture. |
2686 The option is only provided as attribute declaration, but not |
2687 The option is only provided as attribute declaration, but not |
2687 as parameter to the command. |
2688 as parameter to the command. |
2688 |
2689 |
2689 \item[\isa{timeout}] sets the time limit in seconds. |
2690 \item[\isa{timeout}] sets the time limit in seconds. |
2690 |
2691 |
2691 \item[\isa{default{\isaliteral{5F}{\isacharunderscore}}type}] sets the type(s) generally used to |
2692 \item[\isa{default{\isaliteral{5F}{\isacharunderscore}}type}] sets the type(s) generally used to |
2692 instantiate type variables. |
2693 instantiate type variables. |
3389 module name onto another. |
3390 module name onto another. |
3390 |
3391 |
3391 \item \hyperlink{command.HOL.code-reflect}{\mbox{\isa{\isacommand{code{\isaliteral{5F}{\isacharunderscore}}reflect}}}} without a ``\isa{{\isaliteral{22}{\isachardoublequote}}file{\isaliteral{22}{\isachardoublequote}}}'' |
3392 \item \hyperlink{command.HOL.code-reflect}{\mbox{\isa{\isacommand{code{\isaliteral{5F}{\isacharunderscore}}reflect}}}} without a ``\isa{{\isaliteral{22}{\isachardoublequote}}file{\isaliteral{22}{\isachardoublequote}}}'' |
3392 argument compiles code into the system runtime environment and |
3393 argument compiles code into the system runtime environment and |
3393 modifies the code generator setup that future invocations of system |
3394 modifies the code generator setup that future invocations of system |
3394 runtime code generation referring to one of the ``\isa{{\isaliteral{22}{\isachardoublequote}}datatypes{\isaliteral{22}{\isachardoublequote}}}'' or ``\isa{{\isaliteral{22}{\isachardoublequote}}functions{\isaliteral{22}{\isachardoublequote}}}'' entities use these precompiled |
3395 runtime code generation referring to one of the ``\isa{{\isaliteral{22}{\isachardoublequote}}datatypes{\isaliteral{22}{\isachardoublequote}}}'' or ``\isa{{\isaliteral{22}{\isachardoublequote}}functions{\isaliteral{22}{\isachardoublequote}}}'' entities use these |
3395 entities. With a ``\isa{{\isaliteral{22}{\isachardoublequote}}file{\isaliteral{22}{\isachardoublequote}}}'' argument, the corresponding code |
3396 precompiled entities. With a ``\isa{{\isaliteral{22}{\isachardoublequote}}file{\isaliteral{22}{\isachardoublequote}}}'' argument, the |
3396 is generated into that specified file without modifying the code |
3397 corresponding code is generated into that specified file without |
3397 generator setup. |
3398 modifying the code generator setup. |
3398 |
3399 |
3399 \item \hyperlink{command.HOL.code-pred}{\mbox{\isa{\isacommand{code{\isaliteral{5F}{\isacharunderscore}}pred}}}} creates code equations for a predicate |
3400 \item \hyperlink{command.HOL.code-pred}{\mbox{\isa{\isacommand{code{\isaliteral{5F}{\isacharunderscore}}pred}}}} creates code equations for a |
3400 given a set of introduction rules. Optional mode annotations determine |
3401 predicate given a set of introduction rules. Optional mode |
3401 which arguments are supposed to be input or output. If alternative |
3402 annotations determine which arguments are supposed to be input or |
3402 introduction rules are declared, one must prove a corresponding elimination |
3403 output. If alternative introduction rules are declared, one must |
3403 rule. |
3404 prove a corresponding elimination rule. |
3404 |
3405 |
3405 \end{description}% |
3406 \end{description}% |
3406 \end{isamarkuptext}% |
3407 \end{isamarkuptext}% |
3407 \isamarkuptrue% |
3408 \isamarkuptrue% |
3408 % |
3409 % |