Report unused pattern bindings
Henning says: recently, I was a bit suprised that GHC didn't warn about useless
where definitions such as the following when using
-Wall (and I
couldn't find a respective warning GHC CLI flag which would have
enabled reporting a warning in this case -- unless I missed it)
module Foo where foo :: Int -> Int foo n = n + 1 where Nothing = Just n
I think that there should be a warning for the unused pattern binding.