Skip to content

Suggest LambdaCase

When I say

module Bug where

foo = \case True -> False
            False -> True

I get

Bug.hs:9:7: error: parse error: naked lambda expression ''

We can do far better. Setting priority to high because it's rather embarrassing to let your lambdas run around naked.

Trac metadata
Trac field Value
Version 7.10.2
Type Bug
TypeOfFailure OtherFailure
Priority high
Resolution Unresolved
Component Compiler (Parser)
Test case
Differential revisions
BlockedBy
Related
Blocking
CC
Operating system
Architecture
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information