equal
deleted
inserted
replaced
337 Isabelle types and terms. Locally fixed parameters in toplevel |
337 Isabelle types and terms. Locally fixed parameters in toplevel |
338 theorem statements, locale specifications etc.\ also admit mixfix |
338 theorem statements, locale specifications etc.\ also admit mixfix |
339 annotations. |
339 annotations. |
340 |
340 |
341 @{rail " |
341 @{rail " |
342 @{syntax_def mixfix}: '(' ( |
342 @{syntax_def mixfix}: '(' mfix ')' |
343 @{syntax string} prios? @{syntax nat}? | |
343 ; |
|
344 @{syntax_def struct_mixfix}: '(' ( mfix | @'structure' ) ')' |
|
345 ; |
|
346 |
|
347 mfix: @{syntax string} prios? @{syntax nat}? | |
344 (@'infix' | @'infixl' | @'infixr') @{syntax string} @{syntax nat} | |
348 (@'infix' | @'infixl' | @'infixr') @{syntax string} @{syntax nat} | |
345 @'binder' @{syntax string} prios? @{syntax nat} ) ')' |
349 @'binder' @{syntax string} prios? @{syntax nat} |
346 ; |
350 ; |
347 @{syntax_def struct_mixfix}: @{syntax mixfix} | '(' @'structure' ')' |
|
348 ; |
|
349 |
|
350 prios: '[' (@{syntax nat} + ',') ']' |
351 prios: '[' (@{syntax nat} + ',') ']' |
351 "} |
352 "} |
352 |
353 |
353 Here the @{syntax string} specifications refer to the actual mixfix |
354 Here the @{syntax string} specifications refer to the actual mixfix |
354 template, which may include literal text, spacing, blocks, and |
355 template, which may include literal text, spacing, blocks, and |
494 |
495 |
495 \item @{command "write"} is similar to @{command "notation"}, but |
496 \item @{command "write"} is similar to @{command "notation"}, but |
496 works within an Isar proof body. |
497 works within an Isar proof body. |
497 |
498 |
498 \end{description} |
499 \end{description} |
499 |
|
500 Note that the more primitive commands @{command "syntax"} and |
|
501 @{command "no_syntax"} (\secref{sec:syn-trans}) provide raw access |
|
502 to the syntax tables of a global theory. |
|
503 *} |
500 *} |
504 |
501 |
505 |
502 |
506 section {* The Pure syntax \label{sec:pure-syntax} *} |
503 section {* The Pure syntax \label{sec:pure-syntax} *} |
507 |
504 |