dhall-lang / dhall-haskell

Maintainable configuration files
https://dhall-lang.org/
BSD 3-Clause "New" or "Revised" License
917 stars 213 forks source link

Support go to definition #1577

Open jvanbruegge opened 4 years ago

jvanbruegge commented 4 years ago

I am using the language server with vim and besides formatting, the feature of a language server I use the most is go to definition. Would be really nice to jump around in your code base

sjakobi commented 4 years ago

Go-to-import should be supported already.

The idea is to extend this to bindings (lets, lambas)?!

jvanbruegge commented 4 years ago

I mean that when I have something like

let utils = ../utils.dhall
in utils.doSomething "foo"

and I invoke textDocument/definition when having the cursor on utils.doSomething that it jumps into the utils file to the let binding that defines doSomething

JohannesRudolph commented 4 years ago

This would be a big improvement for sure, especially for those working with large dhall models (we do, dhall is the primary configuration model for our product).

Gabriella439 commented 4 years ago

Yeah, this is in my list of things to get to. Right now the higher priority thing I'm working on is fixing https://github.com/dhall-lang/dhall-haskell/issues/1511