45 |
45 |
46 @{rail \<open> |
46 @{rail \<open> |
47 @@{command help} (@{syntax name} * ) |
47 @@{command help} (@{syntax name} * ) |
48 \<close>} |
48 \<close>} |
49 |
49 |
50 \begin{description} |
|
51 |
|
52 \<^descr> @{command "print_commands"} prints all outer syntax keywords |
50 \<^descr> @{command "print_commands"} prints all outer syntax keywords |
53 and commands. |
51 and commands. |
54 |
52 |
55 \<^descr> @{command "help"}~@{text "pats"} retrieves outer syntax |
53 \<^descr> @{command "help"}~@{text "pats"} retrieves outer syntax |
56 commands according to the specified name patterns. |
54 commands according to the specified name patterns. |
57 |
|
58 \end{description} |
|
59 \<close> |
55 \<close> |
60 |
56 |
61 |
57 |
62 subsubsection \<open>Examples\<close> |
58 subsubsection \<open>Examples\<close> |
63 |
59 |
71 section \<open>Lexical matters \label{sec:outer-lex}\<close> |
67 section \<open>Lexical matters \label{sec:outer-lex}\<close> |
72 |
68 |
73 text \<open>The outer lexical syntax consists of three main categories of |
69 text \<open>The outer lexical syntax consists of three main categories of |
74 syntax tokens: |
70 syntax tokens: |
75 |
71 |
76 \begin{enumerate} |
|
77 |
|
78 \<^enum> \emph{major keywords} --- the command names that are available |
72 \<^enum> \emph{major keywords} --- the command names that are available |
79 in the present logic session; |
73 in the present logic session; |
80 |
74 |
81 \<^enum> \emph{minor keywords} --- additional literal tokens required |
75 \<^enum> \emph{minor keywords} --- additional literal tokens required |
82 by the syntax of commands; |
76 by the syntax of commands; |
83 |
77 |
84 \<^enum> \emph{named tokens} --- various categories of identifiers etc. |
78 \<^enum> \emph{named tokens} --- various categories of identifiers etc. |
85 |
79 |
86 \end{enumerate} |
|
87 |
80 |
88 Major keywords and minor keywords are guaranteed to be disjoint. |
81 Major keywords and minor keywords are guaranteed to be disjoint. |
89 This helps user-interfaces to determine the overall structure of a |
82 This helps user-interfaces to determine the overall structure of a |
90 theory text, without knowing the full details of command syntax. |
83 theory text, without knowing the full details of command syntax. |
91 Internally, there is some additional information about the kind of |
84 Internally, there is some additional information about the kind of |
410 existing theorems. Existing theorems are given by @{syntax thmref} |
403 existing theorems. Existing theorems are given by @{syntax thmref} |
411 and @{syntax thmrefs}, the former requires an actual singleton |
404 and @{syntax thmrefs}, the former requires an actual singleton |
412 result. |
405 result. |
413 |
406 |
414 There are three forms of theorem references: |
407 There are three forms of theorem references: |
415 \begin{enumerate} |
|
416 |
408 |
417 \<^enum> named facts @{text "a"}, |
409 \<^enum> named facts @{text "a"}, |
418 |
410 |
419 \<^enum> selections from named facts @{text "a(i)"} or @{text "a(j - k)"}, |
411 \<^enum> selections from named facts @{text "a(i)"} or @{text "a(j - k)"}, |
420 |
412 |
421 \<^enum> literal fact propositions using token syntax @{syntax_ref altstring} |
413 \<^enum> literal fact propositions using token syntax @{syntax_ref altstring} |
422 @{verbatim "`"}@{text "\<phi>"}@{verbatim "`"} or @{syntax_ref cartouche} |
414 @{verbatim "`"}@{text "\<phi>"}@{verbatim "`"} or @{syntax_ref cartouche} |
423 @{text "\<open>\<phi>\<close>"} (see also method @{method_ref fact}). |
415 @{text "\<open>\<phi>\<close>"} (see also method @{method_ref fact}). |
424 |
416 |
425 \end{enumerate} |
|
426 |
417 |
427 Any kind of theorem specification may include lists of attributes |
418 Any kind of theorem specification may include lists of attributes |
428 both on the left and right hand sides; attributes are applied to any |
419 both on the left and right hand sides; attributes are applied to any |
429 immediately preceding fact. If names are omitted, the theorems are |
420 immediately preceding fact. If names are omitted, the theorems are |
430 not stored within the theorem database of the theory or proof |
421 not stored within the theorem database of the theory or proof |
501 |
492 |
502 These commands print certain parts of the theory and proof context. |
493 These commands print certain parts of the theory and proof context. |
503 Note that there are some further ones available, such as for the set |
494 Note that there are some further ones available, such as for the set |
504 of rules declared for simplifications. |
495 of rules declared for simplifications. |
505 |
496 |
506 \begin{description} |
|
507 |
|
508 \<^descr> @{command "print_theory"} prints the main logical content of the |
497 \<^descr> @{command "print_theory"} prints the main logical content of the |
509 background theory; the ``@{text "!"}'' option indicates extra verbosity. |
498 background theory; the ``@{text "!"}'' option indicates extra verbosity. |
510 |
499 |
511 \<^descr> @{command "print_definitions"} prints dependencies of definitional |
500 \<^descr> @{command "print_definitions"} prints dependencies of definitional |
512 specifications within the background theory, which may be constants |
501 specifications within the background theory, which may be constants |
573 or their parents but not in @{text "A\<^sub>1 \<dots> A\<^sub>m"} or their parents and |
562 or their parents but not in @{text "A\<^sub>1 \<dots> A\<^sub>m"} or their parents and |
574 that are never used. |
563 that are never used. |
575 If @{text n} is @{text 0}, the end of the range of theories |
564 If @{text n} is @{text 0}, the end of the range of theories |
576 defaults to the current theory. If no range is specified, |
565 defaults to the current theory. If no range is specified, |
577 only the unused theorems in the current theory are displayed. |
566 only the unused theorems in the current theory are displayed. |
578 |
|
579 \end{description} |
|
580 \<close> |
567 \<close> |
581 |
568 |
582 end |
569 end |