1 module Syntax(Name, Expr(..), Command(..)) where 2 3 import Value 4 5 type Name = String 6 7 data Expr 8 = Var Name 9 | Val Value 10 | Uno Op1 Expr 11 | Duo Op2 Expr Expr 12 deriving (Eq, Show) 13 14 data Command 15 = Skip 16 | Name := Expr 17 | Command :-> Command 18 | If Expr Command Command 19 | While Expr Command 20 | Print Expr 21 deriving (Eq)