src/Doc/Isar_Ref/Spec.thy
changeset 63180 ddfd021884b4
parent 63178 b9e1d53124f5
child 63182 b065b4833092
equal deleted inserted replaced
63179:231e261fd6bc 63180:ddfd021884b4
   283   a certain form (see also \secref{sec:overloading}), or outside of it as
   283   a certain form (see also \secref{sec:overloading}), or outside of it as
   284   rewrite system on abstract syntax. The second form is called
   284   rewrite system on abstract syntax. The second form is called
   285   ``abbreviation''.
   285   ``abbreviation''.
   286 
   286 
   287   @{rail \<open>
   287   @{rail \<open>
   288     @@{command definition} (decl @'where')? @{syntax thmdecl}? @{syntax prop}
   288     @@{command definition} decl? definition
   289     ;
   289     ;
   290     @@{command abbreviation} @{syntax mode}? \<newline>
   290     @@{command abbreviation} @{syntax mode}? decl? abbreviation
   291       (decl @'where')? @{syntax prop}
       
   292     ;
       
   293     decl: @{syntax name} ('::' @{syntax type})? @{syntax mixfix}?
       
   294     ;
   291     ;
   295     @@{command print_abbrevs} ('!'?)
   292     @@{command print_abbrevs} ('!'?)
       
   293     ;
       
   294     decl: @{syntax name} ('::' @{syntax type})? @{syntax mixfix}? @'where'
       
   295     ;
       
   296     definition: @{syntax thmdecl}? @{syntax prop} prems @{syntax for_fixes}
       
   297     ;
       
   298     prems: (@'if' ((@{syntax prop}+) + @'and'))?
       
   299     ;
       
   300     abbreviation: @{syntax prop} @{syntax for_fixes}
   296   \<close>}
   301   \<close>}
   297 
   302 
   298   \<^descr> \<^theory_text>\<open>definition c where eq\<close> produces an internal definition \<open>c \<equiv> t\<close> according
   303   \<^descr> \<^theory_text>\<open>definition c where eq\<close> produces an internal definition \<open>c \<equiv> t\<close> according
   299   to the specification given as \<open>eq\<close>, which is then turned into a proven fact.
   304   to the specification given as \<open>eq\<close>, which is then turned into a proven fact.
   300   The given proposition may deviate from internal meta-level equality
   305   The given proposition may deviate from internal meta-level equality