Improve the error message for case statements
Fixes #39