haskell-mode icon indicating copy to clipboard operation
haskell-mode copied to clipboard

haskell-process-load-file on a file with a relative import and a type error fails with "Unexpected response from haskell process" instead of showing the error

Open rntz opened this issue 5 years ago • 0 comments

How to replicate: Make a directory with two files, A.hs and B.hs, like so:

-- In A.hs:
module A where {}
-- In B.hs:
import A
x = unbound -- or any other code that shouldn't typecheck

Then visit B.hs and run C-c C-l, that is, haskell-process-load-file.

Expected result: I get a nice error message in *haskell* telling me Variable not in scope: unbound.

Actual result: I get a message in the minibuffer saying: Haskell process command errored with: (error "Unexpected response from haskell process."), and no error message in *haskell*, so I am left not knowing what went wrong or how to fix it.

rntz avatar Apr 05 '19 18:04 rntz