Effective Haskell - Chapter 8 runHCat (ePub p 201)

In the first complete version of runHCat (ePub p. 201), that reads a file and prints it to the screen, LambdaCase is used. First, the program won’t compile if the LambdaCase extension isn’t included in the file (ghc will complain but it just suggests to use LambdaCase and a newcomer might not realize that a LANGUAGE pragma is required). Second, it’s probably worthwhile explaining the \case syntax.

1 Like