Parse_AS.hs revision 2b4130336e941b7d01c78a6da55449a4c6eca609
2ca39b9545cad63df411619615736d9070ad7932Christian MaederModule : $Header$
2ca39b9545cad63df411619615736d9070ad7932Christian MaederCopyright : (c) Till Mossakowski, Wiebke Herding and Uni Bremen 2003
2ca39b9545cad63df411619615736d9070ad7932Christian MaederLicence : All rights reserved.
2ca39b9545cad63df411619615736d9070ad7932Christian MaederMaintainer : hets@tzi.de
2ca39b9545cad63df411619615736d9070ad7932Christian MaederStability : provisional
2ca39b9545cad63df411619615736d9070ad7932Christian MaederPortability : portable
2ca39b9545cad63df411619615736d9070ad7932Christian Maeder Parser for modal logic extension of CASL
2ca39b9545cad63df411619615736d9070ad7932Christian MaederboxKey, diamondKey :: AParser Token
2ca39b9545cad63df411619615736d9070ad7932Christian MaederboxKey = asKey boxS
2ca39b9545cad63df411619615736d9070ad7932Christian MaederdiamondKey = asKey diamondS
2ca39b9545cad63df411619615736d9070ad7932Christian MaedermodalFormula :: [String] -> AParser M_FORMULA
2ca39b9545cad63df411619615736d9070ad7932Christian MaedermodalFormula k =
2ca39b9545cad63df411619615736d9070ad7932Christian Maeder do c <- boxKey
2ca39b9545cad63df411619615736d9070ad7932Christian Maeder f <- primFormula k
2ca39b9545cad63df411619615736d9070ad7932Christian Maeder return (Box None f [tokPos c])
2ca39b9545cad63df411619615736d9070ad7932Christian Maeder do c <- diamondKey
2ca39b9545cad63df411619615736d9070ad7932Christian Maeder f <- primFormula k
2ca39b9545cad63df411619615736d9070ad7932Christian Maeder return (Diamond None f [tokPos c])
2ca39b9545cad63df411619615736d9070ad7932Christian Maederinstance Parsable M_FORMULA where
2ca39b9545cad63df411619615736d9070ad7932Christian Maeder aparser = modalFormula