X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;f=Text%2FParserCombinators%2FParsec%2Fexamples%2Fwhile%2FWhileAS.hs;fp=Text%2FParserCombinators%2FParsec%2Fexamples%2Fwhile%2FWhileAS.hs;h=0000000000000000000000000000000000000000;hb=6b42ff99c867e8eb18b22d1d50e914f1fc532dd5;hp=fade981bdeb76b3d8d4d450123dd54490943d6ce;hpb=b21d4af465d575d0072ddf97e178e0e9545f77ba;p=ghc-base.git diff --git a/Text/ParserCombinators/Parsec/examples/while/WhileAS.hs b/Text/ParserCombinators/Parsec/examples/while/WhileAS.hs deleted file mode 100644 index fade981..0000000 --- a/Text/ParserCombinators/Parsec/examples/while/WhileAS.hs +++ /dev/null @@ -1,39 +0,0 @@ -module WhileAS where - -type VarIdent = String -type Label = Int --- type Selector = String - -type Prog = Stat --- type Prog = Prog [Dec] [Stat] - --- Contains name, a list of input vars, output var, body respectively and of course --- the two labels ln and lx -data Dec = Proc [VarIdent] VarIdent VarIdent Label Stat Label - -data AExp - = Var VarIdent - | IntLit Integer - | AOp String AExp AExp --- | Var VarIdent (Maybe Selector) --- | Nil - | Dummy - deriving (Eq, Show) - -data BExp - = BUnOp String BExp - | BoolLit Bool - | BOp String BExp BExp - | RelOp String AExp AExp --- | POp VarIdent (Maybe Selector) - deriving (Eq, Show) - -data Stat - = Assign VarIdent AExp Label - | Skip Label - | Seq [Stat] - | If BExp Label Stat Stat - | While BExp Label Stat --- | Call VarIdent [AExp] VarIdent Label Label --- | Malloc VarIdent (Maybe Selector) Label - deriving (Show, Eq)