

module AbsSRLRL where

-- Haskell module generated by the BNF converter




newtype Ident = Ident String deriving (Eq, Ord, Show, Read)
data Var = IVar Ident
  deriving (Eq, Ord, Show, Read)

data Oplus = Plus | Minus | Index
  deriving (Eq, Ord, Show, Read)

data Otime
    = Calc Oplus
    | Time
    | Div
    | Eq
    | Less
    | Greater
    | Less_Eq
    | Greater_Eq
    | Not_Eq
  deriving (Eq, Ord, Show, Read)

data Const = IConst Integer
  deriving (Eq, Ord, Show, Read)

data Exp
    = EConst Const
    | EVar Ident
    | EVar_List Var Exp
    | EExp Exp Otime Exp
    | ETop Var
    | EEmpty Var
  deriving (Eq, Ord, Show, Read)

data Step
    = Oplus_Eq Var Oplus Exp
    | OPlus_Eq_List Var Exp Oplus Exp
    | Push Var Var
    | Pop Var Var
    | Skip
  deriving (Eq, Ord, Show, Read)

data Blk
    = Sstep Step
    | Sif Exp Blk Blk Exp
    | Sblk Blk Blk
    | Sfrom Exp Blk Blk Exp
  deriving (Eq, Ord, Show, Read)

data SRL = ESRL Blk
  deriving (Eq, Ord, Show, Read)

data Label = ELabel Integer
  deriving (Eq, Ord, Show, Read)

data Jump = Rgoto Label | Rif Exp Label Label | Rexit
  deriving (Eq, Ord, Show, Read)

data From = Rfrom Label | Rfi Exp Label Label | Rentry
  deriving (Eq, Ord, Show, Read)

data Rlblk = Rblk1 Label From Jump | Rblk2 Label From Step Jump
  deriving (Eq, Ord, Show, Read)

data Rl = Rl1 | Rl2 Rlblk Rl
  deriving (Eq, Ord, Show, Read)

