CspCASL_Keywords.hs revision ac5ec613b786cd05f495b568ab5214c31a333e67
8a77240a809197c92c0736c431b4b88947a7bac1Christian Maeder{- |
8a77240a809197c92c0736c431b4b88947a7bac1Christian MaederModule : $Id$
6ea54752d184beb92c92fbae17ae9f7dd065d988Christian MaederDescription : CspCASL keywords to be used for parsing and printing
306763c67bb99228487345b32ab8c5c6cd41f23cChristian MaederCopyright : (c) Andy Gimblett and Swansea University 2006
3a6c7a7ff823616f56cd3d205fc44664a683effdChristian MaederLicense : similar to LGPL, see HetCATS/LICENSE.txt or LIZENZ.txt
6ea54752d184beb92c92fbae17ae9f7dd065d988Christian Maeder
98890889ffb2e8f6f722b00e265a211f13b5a861Corneliu-Claudiu ProdescuMaintainer : a.m.gimblett@swan.ac.uk
2eeec5240b424984e3ee26296da1eeab6c6d739eChristian MaederStability : provisional
306763c67bb99228487345b32ab8c5c6cd41f23cChristian MaederPortability : portable
306763c67bb99228487345b32ab8c5c6cd41f23cChristian Maeder
f3a94a197960e548ecd6520bb768cb0d547457bbChristian MaederString constants for CspCASL keywords to be used for parsing and
9f87aabedf02d74917d94fe1ac0300e07d3d4bc2Christian Maederprinting.
44fb55f639914f4f531641f32dd4904f15c510a4Till Mossakowski
e9249d3ecd51a2b6a966a58669953e58d703adc6Till Mossakowski-}
e9249d3ecd51a2b6a966a58669953e58d703adc6Till Mossakowski
af0cbe339851fc558d2b18cde3666981325e667cTill Mossakowskimodule CspCASL.CspCASL_Keywords where
e9249d3ecd51a2b6a966a58669953e58d703adc6Till Mossakowski
e9249d3ecd51a2b6a966a58669953e58d703adc6Till Mossakowskiimport Common.Token (casl_reserved_words)
1bc5dccbf0083a620ae1181c717fea75e4af5e5cChristian Maeder
556f473448dfcceee22afaa89ed7a364489cdbbbChristian Maeder-- | Keywords identifying beginning of channel declaration part.
1bc5dccbf0083a620ae1181c717fea75e4af5e5cChristian MaederchannelS, channelsS :: String
1bc5dccbf0083a620ae1181c717fea75e4af5e5cChristian MaederchannelS = "channel"
1bc5dccbf0083a620ae1181c717fea75e4af5e5cChristian MaederchannelsS = "channels"
1bc5dccbf0083a620ae1181c717fea75e4af5e5cChristian Maeder
1bc5dccbf0083a620ae1181c717fea75e4af5e5cChristian Maeder-- | Keyword identifying beginning of process equation part.
1bc5dccbf0083a620ae1181c717fea75e4af5e5cChristian MaederprocessS :: String
556f473448dfcceee22afaa89ed7a364489cdbbbChristian MaederprocessS = "process"
1bc5dccbf0083a620ae1181c717fea75e4af5e5cChristian Maeder
1bc5dccbf0083a620ae1181c717fea75e4af5e5cChristian Maeder-- | interleaving parallel operator
1bc5dccbf0083a620ae1181c717fea75e4af5e5cChristian MaederinterleavingS :: String
1bc5dccbf0083a620ae1181c717fea75e4af5e5cChristian MaederinterleavingS = "|||"
556f473448dfcceee22afaa89ed7a364489cdbbbChristian Maeder
556f473448dfcceee22afaa89ed7a364489cdbbbChristian Maeder-- | synchronous parallel operator
556f473448dfcceee22afaa89ed7a364489cdbbbChristian MaedersynchronousS :: String
556f473448dfcceee22afaa89ed7a364489cdbbbChristian MaedersynchronousS = "||"
556f473448dfcceee22afaa89ed7a364489cdbbbChristian Maeder
556f473448dfcceee22afaa89ed7a364489cdbbbChristian Maeder-- | Open generalised parallel
556f473448dfcceee22afaa89ed7a364489cdbbbChristian Maedergeneral_parallel_openS :: String
1bc5dccbf0083a620ae1181c717fea75e4af5e5cChristian Maedergeneral_parallel_openS = "[|"
e9249d3ecd51a2b6a966a58669953e58d703adc6Till Mossakowski
e9249d3ecd51a2b6a966a58669953e58d703adc6Till Mossakowski-- | Close generalised parallel
922819b1c2d383a0fa5d70e1c4aa76667e2f1ca3Christian Maedergeneral_parallel_closeS :: String
27166b063721ef1a2efd8f00ab3d9bc820b315fbChristian Maedergeneral_parallel_closeS = "|]"
19298cbfd6ee2abd904f3181af7760b965b822c3Christian Maeder
9f87aabedf02d74917d94fe1ac0300e07d3d4bc2Christian Maeder-- | Open alpabetised parallel
9f87aabedf02d74917d94fe1ac0300e07d3d4bc2Christian Maederalpha_parallel_openS :: String
27166b063721ef1a2efd8f00ab3d9bc820b315fbChristian Maederalpha_parallel_openS = "["
24a0fbb77b860bc28d25be37ba555fd5746cb6d6Christian Maeder
27166b063721ef1a2efd8f00ab3d9bc820b315fbChristian Maeder-- | Separator in alpabetised parallel
27166b063721ef1a2efd8f00ab3d9bc820b315fbChristian Maederalpha_parallel_sepS :: String
27166b063721ef1a2efd8f00ab3d9bc820b315fbChristian Maederalpha_parallel_sepS = "||"
1a38107941725211e7c3f051f7a8f5e12199f03acmaeder
27166b063721ef1a2efd8f00ab3d9bc820b315fbChristian Maeder-- | Close alpabetised parallel
63324a97283728a30932828a612c7b0b0f687624Christian Maederalpha_parallel_closeS :: String
e9249d3ecd51a2b6a966a58669953e58d703adc6Till Mossakowskialpha_parallel_closeS = "]"
59fa9b1349ae1e001d996da732c4ac805c2938e2Christian Maeder
e9249d3ecd51a2b6a966a58669953e58d703adc6Till Mossakowski-- | External choice
e9249d3ecd51a2b6a966a58669953e58d703adc6Till Mossakowskiexternal_choiceS :: String
e9249d3ecd51a2b6a966a58669953e58d703adc6Till Mossakowskiexternal_choiceS = "[]"
e9249d3ecd51a2b6a966a58669953e58d703adc6Till Mossakowski
53310804002cd9e3c9c5844db3b984abcf001788Christian Maeder-- | Internal choice
e9249d3ecd51a2b6a966a58669953e58d703adc6Till Mossakowskiinternal_choiceS :: String
e9249d3ecd51a2b6a966a58669953e58d703adc6Till Mossakowskiinternal_choiceS = "|~|"
e9249d3ecd51a2b6a966a58669953e58d703adc6Till Mossakowski
e9249d3ecd51a2b6a966a58669953e58d703adc6Till Mossakowski-- | Prefix processes
e9249d3ecd51a2b6a966a58669953e58d703adc6Till MossakowskiprefixS :: String
e9249d3ecd51a2b6a966a58669953e58d703adc6Till MossakowskiprefixS = "->"
3a87487c048b275c56e502c4a933273788e8d0bbChristian Maeder
2b565fe5cfb9f99857fd25b52304758d8544e266Mihai Codescu-- | External prefix opener
2b565fe5cfb9f99857fd25b52304758d8544e266Mihai Codescuexternal_prefixS :: String
2b565fe5cfb9f99857fd25b52304758d8544e266Mihai Codescuexternal_prefixS = "[]"
e9249d3ecd51a2b6a966a58669953e58d703adc6Till Mossakowski
b5056cf24da461ee868c4be7b803a76b677fa21dChristian Maeder-- | Internal prefix opener
b5056cf24da461ee868c4be7b803a76b677fa21dChristian Maederinternal_prefixS :: String
4184cb191a9081cb2a9cf3ef5f060f56f0ca5922Till Mossakowskiinternal_prefixS = "|~|"
8731f7b93b26083dc34a2c0937cd6493b42f2c2cTill Mossakowski
d97cb7d1c9beadc4d9102738da0a88c4efcf8fddChristian Maeder-- | Hiding
24a0fbb77b860bc28d25be37ba555fd5746cb6d6Christian MaederhidingS :: String
24a0fbb77b860bc28d25be37ba555fd5746cb6d6Christian MaederhidingS = "\\"
4184cb191a9081cb2a9cf3ef5f060f56f0ca5922Till Mossakowski
b5056cf24da461ee868c4be7b803a76b677fa21dChristian Maeder-- | Open a renaming
b5056cf24da461ee868c4be7b803a76b677fa21dChristian Maederrenaming_openS :: String
bba825b39570777866d560bfde3807731131097eKlaus Luettichrenaming_openS = "[["
d97cb7d1c9beadc4d9102738da0a88c4efcf8fddChristian Maeder
b5056cf24da461ee868c4be7b803a76b677fa21dChristian Maeder-- | Close a renaming
b5056cf24da461ee868c4be7b803a76b677fa21dChristian Maederrenaming_closeS :: String
b5056cf24da461ee868c4be7b803a76b677fa21dChristian Maederrenaming_closeS = "]]"
b5056cf24da461ee868c4be7b803a76b677fa21dChristian Maeder
fd496ec12c6be2731410ea84111f1ff88d8b6384Christian Maeder-- | "RUN" primitive process
fd496ec12c6be2731410ea84111f1ff88d8b6384Christian MaederrunS :: String
f23641ce10de2d58493d41a4b39c64d904e5b534Christian MaederrunS = "RUN"
f23641ce10de2d58493d41a4b39c64d904e5b534Christian Maeder
f23641ce10de2d58493d41a4b39c64d904e5b534Christian Maeder-- | "CHAOS" primitive process
f23641ce10de2d58493d41a4b39c64d904e5b534Christian MaederchaosS :: String
f23641ce10de2d58493d41a4b39c64d904e5b534Christian MaederchaosS = "CHAOS"
f23641ce10de2d58493d41a4b39c64d904e5b534Christian Maeder
a89e661aad28f1b39f4fc9f9f9a4d46074234123Christian Maeder-- | "div" primitive process
3d86f079b07a6a058cdd6c112d287e01a69d9c0cChristian MaederdivS :: String
a89e661aad28f1b39f4fc9f9f9a4d46074234123Christian MaederdivS = "div"
b5056cf24da461ee868c4be7b803a76b677fa21dChristian Maeder
b5056cf24da461ee868c4be7b803a76b677fa21dChristian Maeder-- | "SKIP" primitive process
b5056cf24da461ee868c4be7b803a76b677fa21dChristian MaederskipS :: String
b60a22e76e983e8129c5dae4d713fe2794ed7054Christian MaederskipS = "SKIP"
83b3260413a3b1b7dee1f9c4d3249dec994a875cMihai Codescu
b60a22e76e983e8129c5dae4d713fe2794ed7054Christian Maeder-- | "STOP" primitive process
a975722baf6fee1ca3e67df170c732c4abd0a945Christian MaederstopS :: String
a975722baf6fee1ca3e67df170c732c4abd0a945Christian MaederstopS = "STOP"
a975722baf6fee1ca3e67df170c732c4abd0a945Christian Maeder
a975722baf6fee1ca3e67df170c732c4abd0a945Christian Maederchan_event_openS :: String
63324a97283728a30932828a612c7b0b0f687624Christian Maederchan_event_openS = "{|"
fd496ec12c6be2731410ea84111f1ff88d8b6384Christian Maeder
a98fd29a06e80e447af26d898044c23497adbc73Mihai Codescuchan_event_closeS :: String
b5056cf24da461ee868c4be7b803a76b677fa21dChristian Maederchan_event_closeS = "|}"
b5056cf24da461ee868c4be7b803a76b677fa21dChristian Maeder
b5056cf24da461ee868c4be7b803a76b677fa21dChristian Maederchan_sendS :: String
b5056cf24da461ee868c4be7b803a76b677fa21dChristian Maederchan_sendS = "!"
b5056cf24da461ee868c4be7b803a76b677fa21dChristian Maeder
f2c050360525df494e6115073b0edc4c443a847cMihai Codescuchan_receiveS :: String
b60a22e76e983e8129c5dae4d713fe2794ed7054Christian Maederchan_receiveS = "?"
f2c050360525df494e6115073b0edc4c443a847cMihai Codescu
b60a22e76e983e8129c5dae4d713fe2794ed7054Christian Maedersvar_sortS :: String
f2c050360525df494e6115073b0edc4c443a847cMihai Codescusvar_sortS = "::"
0e51a998b1b213654c7a9eca451562041971f100Till Mossakowski
0e51a998b1b213654c7a9eca451562041971f100Till Mossakowski-- | Reserved keywords specific to CSP-CASL.
b60a22e76e983e8129c5dae4d713fe2794ed7054Christian Maedercsp_casl_keywords :: [String]
b60a22e76e983e8129c5dae4d713fe2794ed7054Christian Maedercsp_casl_keywords = casl_reserved_words ++
a0951ecefe9f0733f3bbb6039bf66af7d72b3944mcodescu [ channelS,
a0951ecefe9f0733f3bbb6039bf66af7d72b3944mcodescu channelsS,
a0951ecefe9f0733f3bbb6039bf66af7d72b3944mcodescu processS,
a0951ecefe9f0733f3bbb6039bf66af7d72b3944mcodescu interleavingS,
a0951ecefe9f0733f3bbb6039bf66af7d72b3944mcodescu synchronousS,
a0951ecefe9f0733f3bbb6039bf66af7d72b3944mcodescu general_parallel_openS,
e9249d3ecd51a2b6a966a58669953e58d703adc6Till Mossakowski general_parallel_closeS,
5c358300e78157f4bfaf5415c70e1096a9205b61Christian Maeder alpha_parallel_openS,
5c358300e78157f4bfaf5415c70e1096a9205b61Christian Maeder alpha_parallel_sepS,
5c358300e78157f4bfaf5415c70e1096a9205b61Christian Maeder alpha_parallel_closeS,
5c358300e78157f4bfaf5415c70e1096a9205b61Christian Maeder external_choiceS,
5c358300e78157f4bfaf5415c70e1096a9205b61Christian Maeder internal_choiceS,
5c358300e78157f4bfaf5415c70e1096a9205b61Christian Maeder prefixS,
27166b063721ef1a2efd8f00ab3d9bc820b315fbChristian Maeder external_prefixS,
27166b063721ef1a2efd8f00ab3d9bc820b315fbChristian Maeder internal_prefixS,
5c358300e78157f4bfaf5415c70e1096a9205b61Christian Maeder hidingS,
f23641ce10de2d58493d41a4b39c64d904e5b534Christian Maeder renaming_openS,
19298cbfd6ee2abd904f3181af7760b965b822c3Christian Maeder renaming_closeS,
19298cbfd6ee2abd904f3181af7760b965b822c3Christian Maeder runS,
19298cbfd6ee2abd904f3181af7760b965b822c3Christian Maeder chaosS,
19298cbfd6ee2abd904f3181af7760b965b822c3Christian Maeder divS,
19298cbfd6ee2abd904f3181af7760b965b822c3Christian Maeder skipS,
fd496ec12c6be2731410ea84111f1ff88d8b6384Christian Maeder stopS,
fd496ec12c6be2731410ea84111f1ff88d8b6384Christian Maeder chan_event_openS,
19298cbfd6ee2abd904f3181af7760b965b822c3Christian Maeder chan_event_closeS,
5c358300e78157f4bfaf5415c70e1096a9205b61Christian Maeder chan_sendS,
5c358300e78157f4bfaf5415c70e1096a9205b61Christian Maeder chan_receiveS,
5c358300e78157f4bfaf5415c70e1096a9205b61Christian Maeder svar_sortS
5c358300e78157f4bfaf5415c70e1096a9205b61Christian Maeder ]
5c358300e78157f4bfaf5415c70e1096a9205b61Christian Maeder