src/Tools/Haskell/Haskell.thy
changeset 69280 e1d01b351724
parent 69278 30f6e8d2cd96
child 69287 0fde0dca6744
equal deleted inserted replaced
69279:e6997512ef6c 69280:e1d01b351724
    31 {-  Title:      Tools/Haskell/Library.hs
    31 {-  Title:      Tools/Haskell/Library.hs
    32     Author:     Makarius
    32     Author:     Makarius
    33     LICENSE:    BSD 3-clause (Isabelle)
    33     LICENSE:    BSD 3-clause (Isabelle)
    34 
    34 
    35 Basic library of Isabelle idioms.
    35 Basic library of Isabelle idioms.
       
    36 
       
    37 See also \<^file>\<open>$ISABELLE_HOME/src/Pure/General/basics.ML\<close>, \<^file>\<open>$ISABELLE_HOME/src/Pure/library.ML\<close>.
    36 -}
    38 -}
    37 
    39 
    38 module Isabelle.Library (
    40 module Isabelle.Library (
    39   (|>), (|->), (#>), (#->),
    41   (|>), (|->), (#>), (#->),
    40 
    42 
   120 {-  Title:      Haskell/Tools/Value.hs
   122 {-  Title:      Haskell/Tools/Value.hs
   121     Author:     Makarius
   123     Author:     Makarius
   122     LICENSE:    BSD 3-clause (Isabelle)
   124     LICENSE:    BSD 3-clause (Isabelle)
   123 
   125 
   124 Plain values, represented as string.
   126 Plain values, represented as string.
       
   127 
       
   128 See also \<^file>\<open>$ISABELLE_HOME/src/Pure/General/value.ML\<close>.
   125 -}
   129 -}
   126 
   130 
   127 module Isabelle.Value
   131 module Isabelle.Value
   128   (print_bool, parse_bool, print_int, parse_int, print_real, parse_real)
   132   (print_bool, parse_bool, print_int, parse_int, print_real, parse_real)
   129 where
   133 where
   171 {-  Title:      Tools/Haskell/Buffer.hs
   175 {-  Title:      Tools/Haskell/Buffer.hs
   172     Author:     Makarius
   176     Author:     Makarius
   173     LICENSE:    BSD 3-clause (Isabelle)
   177     LICENSE:    BSD 3-clause (Isabelle)
   174 
   178 
   175 Efficient text buffers.
   179 Efficient text buffers.
       
   180 
       
   181 See also \<^file>\<open>$ISABELLE_HOME/src/Pure/General/buffer.ML\<close>.
   176 -}
   182 -}
   177 
   183 
   178 module Isabelle.Buffer (T, empty, add, content)
   184 module Isabelle.Buffer (T, empty, add, content)
   179 where
   185 where
   180 
   186 
   195 {-  Title:      Tools/Haskell/Properties.hs
   201 {-  Title:      Tools/Haskell/Properties.hs
   196     Author:     Makarius
   202     Author:     Makarius
   197     LICENSE:    BSD 3-clause (Isabelle)
   203     LICENSE:    BSD 3-clause (Isabelle)
   198 
   204 
   199 Property lists.
   205 Property lists.
       
   206 
       
   207 See also \<^file>\<open>$ISABELLE_HOME/src/Pure/General/properties.ML\<close>.
   200 -}
   208 -}
   201 
   209 
   202 module Isabelle.Properties (Entry, T, defined, get, put, remove)
   210 module Isabelle.Properties (Entry, T, defined, get, put, remove)
   203 where
   211 where
   204 
   212 
   227 {-  Title:      Haskell/Tools/Markup.hs
   235 {-  Title:      Haskell/Tools/Markup.hs
   228     Author:     Makarius
   236     Author:     Makarius
   229     LICENSE:    BSD 3-clause (Isabelle)
   237     LICENSE:    BSD 3-clause (Isabelle)
   230 
   238 
   231 Quasi-abstract markup elements.
   239 Quasi-abstract markup elements.
       
   240 
       
   241 See also \<^file>\<open>$ISABELLE_HOME/src/Pure/PIDE/markup.ML\<close>.
   232 -}
   242 -}
   233 
   243 
   234 module Isabelle.Markup (
   244 module Isabelle.Markup (
   235   T, empty, is_empty, properties,
   245   T, empty, is_empty, properties,
   236 
   246 
   519 generate_haskell_file "File.hs" = \<open>
   529 generate_haskell_file "File.hs" = \<open>
   520 {-  Title:      Tools/Haskell/File.hs
   530 {-  Title:      Tools/Haskell/File.hs
   521     Author:     Makarius
   531     Author:     Makarius
   522     LICENSE:    BSD 3-clause (Isabelle)
   532     LICENSE:    BSD 3-clause (Isabelle)
   523 
   533 
   524 File-system operations
   534 File-system operations.
       
   535 
       
   536 See also \<^file>\<open>$ISABELLE_HOME/src/Pure/General/file.ML\<close>.
   525 -}
   537 -}
   526 
   538 
   527 module Isabelle.File (setup, read, write, append) where
   539 module Isabelle.File (setup, read, write, append) where
   528 
   540 
   529 import Prelude hiding (read)
   541 import Prelude hiding (read)
   553 {-  Title:      Tools/Haskell/XML.hs
   565 {-  Title:      Tools/Haskell/XML.hs
   554     Author:     Makarius
   566     Author:     Makarius
   555     LICENSE:    BSD 3-clause (Isabelle)
   567     LICENSE:    BSD 3-clause (Isabelle)
   556 
   568 
   557 Untyped XML trees and representation of ML values.
   569 Untyped XML trees and representation of ML values.
       
   570 
       
   571 See also \<^file>\<open>$ISABELLE_HOME/src/Pure/PIDE/xml.ML\<close>.
   558 -}
   572 -}
   559 
   573 
   560 module Isabelle.XML (Attributes, Body, Tree(..), wrap_elem, unwrap_elem, content_of)
   574 module Isabelle.XML (Attributes, Body, Tree(..), wrap_elem, unwrap_elem, content_of)
   561 where
   575 where
   562 
   576 
   630 {-  Title:      Tools/Haskell/XML/Encode.hs
   644 {-  Title:      Tools/Haskell/XML/Encode.hs
   631     Author:     Makarius
   645     Author:     Makarius
   632     LICENSE:    BSD 3-clause (Isabelle)
   646     LICENSE:    BSD 3-clause (Isabelle)
   633 
   647 
   634 XML as data representation language.
   648 XML as data representation language.
       
   649 
       
   650 See also \<^file>\<open>$ISABELLE_HOME/src/Pure/PIDE/xml.ML\<close>.
   635 -}
   651 -}
   636 
   652 
   637 module Isabelle.XML.Encode (
   653 module Isabelle.XML.Encode (
   638   A, T, V,
   654   A, T, V,
   639 
   655 
   714 {-  Title:      Tools/Haskell/XML/Decode.hs
   730 {-  Title:      Tools/Haskell/XML/Decode.hs
   715     Author:     Makarius
   731     Author:     Makarius
   716     LICENSE:    BSD 3-clause (Isabelle)
   732     LICENSE:    BSD 3-clause (Isabelle)
   717 
   733 
   718 XML as data representation language.
   734 XML as data representation language.
       
   735 
       
   736 See also \<^file>\<open>$ISABELLE_HOME/src/Pure/PIDE/xml.ML\<close>.
   719 -}
   737 -}
   720 
   738 
   721 module Isabelle.XML.Decode (
   739 module Isabelle.XML.Decode (
   722   A, T, V,
   740   A, T, V,
   723 
   741 
   823 {-  Title:      Tools/Haskell/Pretty.hs
   841 {-  Title:      Tools/Haskell/Pretty.hs
   824     Author:     Makarius
   842     Author:     Makarius
   825     LICENSE:    BSD 3-clause (Isabelle)
   843     LICENSE:    BSD 3-clause (Isabelle)
   826 
   844 
   827 Generic pretty printing module.
   845 Generic pretty printing module.
       
   846 
       
   847 See also \<^file>\<open>$ISABELLE_HOME/src/Pure/General/pretty.ML\<close>.
   828 -}
   848 -}
   829 
   849 
   830 module Isabelle.Pretty (
   850 module Isabelle.Pretty (
   831   T, symbolic, formatted, unformatted,
   851   T, symbolic, formatted, unformatted,
   832 
   852 
   976     Author:     Makarius
   996     Author:     Makarius
   977     LICENSE:    BSD 3-clause (Isabelle)
   997     LICENSE:    BSD 3-clause (Isabelle)
   978 
   998 
   979 Efficient text representation of XML trees.  Suitable for direct
   999 Efficient text representation of XML trees.  Suitable for direct
   980 inlining into plain text.
  1000 inlining into plain text.
       
  1001 
       
  1002 See also \<^file>\<open>$ISABELLE_HOME/src/Pure/PIDE/yxml.ML\<close>.
   981 -}
  1003 -}
   982 
  1004 
   983 module Isabelle.YXML (charX, charY, strX, strY, detect, output_markup,
  1005 module Isabelle.YXML (charX, charY, strX, strY, detect, output_markup,
   984   buffer_body, buffer, string_of_body, string_of, parse_body, parse)
  1006   buffer_body, buffer, string_of_body, string_of, parse_body, parse)
   985 where
  1007 where
  1101 {-  Title:      Tools/Haskell/Term.hs
  1123 {-  Title:      Tools/Haskell/Term.hs
  1102     Author:     Makarius
  1124     Author:     Makarius
  1103     LICENSE:    BSD 3-clause (Isabelle)
  1125     LICENSE:    BSD 3-clause (Isabelle)
  1104 
  1126 
  1105 Lambda terms, types, sorts.
  1127 Lambda terms, types, sorts.
       
  1128 
       
  1129 See also \<^file>\<open>$ISABELLE_HOME/src/Pure/term.scala\<close>.
  1106 -}
  1130 -}
  1107 
  1131 
  1108 module Isabelle.Term (
  1132 module Isabelle.Term (
  1109   Indexname,
  1133   Indexname,
  1110 
  1134 
  1146 {-  Title:      Tools/Haskell/Term_XML/Encode.hs
  1170 {-  Title:      Tools/Haskell/Term_XML/Encode.hs
  1147     Author:     Makarius
  1171     Author:     Makarius
  1148     LICENSE:    BSD 3-clause (Isabelle)
  1172     LICENSE:    BSD 3-clause (Isabelle)
  1149 
  1173 
  1150 XML data representation of lambda terms.
  1174 XML data representation of lambda terms.
       
  1175 
       
  1176 See also \<^file>\<open>$ISABELLE_HOME/src/Pure/term_xml.ML\<close>.
  1151 -}
  1177 -}
  1152 
  1178 
  1153 {-# LANGUAGE LambdaCase #-}
  1179 {-# LANGUAGE LambdaCase #-}
  1154 
  1180 
  1155 module Isabelle.Term_XML.Encode (sort, typ, term)
  1181 module Isabelle.Term_XML.Encode (sort, typ, term)
  1186 {-  Title:      Tools/Haskell/Term_XML/Decode.hs
  1212 {-  Title:      Tools/Haskell/Term_XML/Decode.hs
  1187     Author:     Makarius
  1213     Author:     Makarius
  1188     LICENSE:    BSD 3-clause (Isabelle)
  1214     LICENSE:    BSD 3-clause (Isabelle)
  1189 
  1215 
  1190 XML data representation of lambda terms.
  1216 XML data representation of lambda terms.
       
  1217 
       
  1218 See also \<^file>\<open>$ISABELLE_HOME/src/Pure/term_xml.ML\<close>.
  1191 -}
  1219 -}
  1192 
  1220 
  1193 module Isabelle.Term_XML.Decode (sort, typ, term)
  1221 module Isabelle.Term_XML.Decode (sort, typ, term)
  1194 where
  1222 where
  1195 
  1223