haskell / haskell/error-messages
Perhaps you meant a :: Maybe Int
Open
status:Composing error message
tool:GHC
type:error-message
- Dominant language
- No language data
- Stars
- 76
- Forks
- 19
- PR merge metrics
- No merged PRs in 30d
Description
Given this code:
```haskell
a :: Just Int
a = Just 5
```
GHC errors with:
```haskell
Not in scope: type constructor or class 'Just'A data constructor of that name is in scope; did you mean DataKinds?
```
A better error message would be:
```haskell
Perhaps you meant a :: Maybe Int?
Not in scope: type constructor or class 'Just'
A data constructor of that name is in scope; did you mean DataKinds?
```
Suggested on reddit: https://www.reddit.com/r/haskell/comments/kgvdon/improving_haskell_ghc_error_messages/gghjajf/?utm_source=reddit&utm_medium=web2x&context=3
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.