dhall-haskell/dhall-lsp-server
Frederik Ramcke 7ba33437e2 Fix LSP diagnostics to trailing whitespace (#974)
* dhall-lsp-server: Revert from Relude to standard Prelude

The code so far used Relude in place of the standard Prelude. Reverting
back to the standard Prelude brings dhall-lsp-server in line with the
rest of the dhall-haskell family, while also reducing the barrier to
contribution.

This change causes a number of additional explicit imports; creating a
"Library" module to gather the common imports could perhaps solve both
problems, i.e. reducing overhead while not having to resort to a custom
prelude. (This is left for a future refactoring.)

*  dhall-lsp-server: Exclude trailing whitespace in diagnostics

Dhall's current parser includes trailing whitespace in source range
annotations. Until now, we simply passed these "loose" ranges on to the
LSP client when generating diagnostic messages; this behaviour is fixed
in the present commit.

Previously (assuming funcTion is misspelled):
 funcTion argument
 ~~~~~~~~~

Now:
  funcTion argument
  ~~~~~~~~

* Refactor lines' to return NonEmpty list

Thanks to Gabriel for pointing this out! Since "lines'" always returns at
least a singleton list containing the empty line we can reflect this in
its type; this allows us to get rid of a test for non-emptiness in
"offsetToPosition".
2019-05-29 14:38:02 -07:00
..
app Fix LSP diagnostics to trailing whitespace (#974) 2019-05-29 14:38:02 -07:00
src Fix LSP diagnostics to trailing whitespace (#974) 2019-05-29 14:38:02 -07:00
test Update tests and include dhall-lsp-server in appveyor (#889) 2019-04-11 16:47:07 -07:00
ChangeLog.md LSP. Fix import errors location. Minor clean-up. Add tests for backend/diagnostics. (#868) 2019-03-26 13:20:25 +00:00
default.nix Add dhall-lsp-server (#843) 2019-03-06 21:41:38 -08:00
dhall-lsp-server.cabal Fix LSP diagnostics to trailing whitespace (#974) 2019-05-29 14:38:02 -07:00
LICENSE Add dhall-lsp-server (#843) 2019-03-06 21:41:38 -08:00
README.md LSP. Fix import errors location. Minor clean-up. Add tests for backend/diagnostics. (#868) 2019-03-26 13:20:25 +00:00
Setup.hs Add dhall-lsp-server (#843) 2019-03-06 21:41:38 -08:00
shell.nix Add Nix support for dhall-lsp-server project (#849) 2019-03-10 09:43:44 -07:00

dhall-lsp-server

This is a Language Server Protocol server implementation for the Dhall programming language.

For installation or development instructions, see: