haskell / haskell/haskell-language-server
Inlay hints usage
- Dominant language
- Haskell
- Stars
- 3k
- Forks
- 455
- Avg merge
- 2d 19h
- Merged PRs (30d)
- 11
Description
In order to prevent spam, I open a thread to discuss about the inlay hint usage in Haskell.
Previous info is here: https://github.com/haskell/haskell-language-server/issues/2019#issuecomment-1144502854
lsp-3.17 had supported inlay hint, in which can embed some useful info, it wildly used by displaying function parameter names in other languages. But it is not suitable in Haskell since Haskell have a lot of currying, which looks not valid to display parameter name in Haskell.
Sample of inlay hint:

I don't want Haskell missing this straightforward function, so I wrote these to discuss what we can do to use inlay hint best, here are some I'd like:
1. Show type signature for let expressions
```haskell
f = let g {- inlay hint here, should be `:: Bool` -}= True
in g
```
2. Show operator fixity as mentioned in https://github.com/haskell/haskell-language-server/issues/2019#issuecomment-1144499665
All these are initial ideas for discussion, feel free to put forward any suggestions:)
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.