shithub: MicroHs

ref: 30ed73a98df14cb18296e7d2178227e6392a8ff7
dir: /tests/OrPat.hs/

View raw version
module OrPat where

data Sweet = Cupcake | Liquorice | Cookie | Raisins

taste :: Sweet -> Bool
tasty (Cupcake; Cookie) = True
tasty (Liquorice; Raisins) = False

main :: IO ()
main = print $ map tasty [Cupcake, Liquorice, Cupcake, Raisins]