elm-language-server: [CoC/neovim] Go to definition fails for some functions
Expected Behavior
I expect “go to definition” to work regardless of the context.
Current Behavior
For some functions, whether they are in the same file or not, I instead get an error from CoC:
[coc.nvim] Definition not found
Looking into the log with :CocInfo, this is what I see:
[Info - 1:54:25 PM] A definition was requested
[Error - 1:54:25 PM] Request textDocument/definition failed.
Message: Request textDocument/definition failed with message: anonymousFunctionExprNodes.flatMap is not a function
Code: -32603
Possible Solution
I have none, sorry!
Steps to Reproduce (for bugs)¶
I don’t have an SSCCE, sorry, but i’ve had the bug occur on my latest pet project, which consists of one Main.elm file, so I figure it’s OK to use it to showcase the issue? Let me know if it is not.
git clone --single-branch --branch animation-test git@github.com:Augustin82/0h-n0- open
./0h-n0/src/Main.elm - go to the use of
toColor(l.135) and try to go to definition: it works - go to the use of
fromColor(l.140) and try to go to definition: it does not work
Context
Going to the definition would be peachy!
Your Environment
- Version used: 1.7.1
- Editor used: neovim
- Environment name and version (e.g. node.js 5.4): nodejs 10.20.1
- Operating System and version: Ubuntu Gnome 18.04
About this issue
- Original URL
- State: closed
- Created 4 years ago
- Comments: 33 (23 by maintainers)
https://github.com/elm-tooling/elm-language-server/tree/workaround-flatmap might help
Ok, I’ll try to install it and check.