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

Compile error navigation not working as advertised.

Open capn-freako opened this issue 7 years ago • 5 comments

I'm attempting to use the Haskell compile error navigation features advertised in Sec. 13.1 of this document, but it's not working. I have two problems:

  1. The advertised key bindings (i.e. - M-n, M-p, and C-c M-p) don't appear to be in force.
  2. When I use the equivalent commands (via M-x), I'm told, "No more notes from Haskell compiler," despite the fact that there are some compile errors occurring.

capn-freako avatar Nov 02 '18 23:11 capn-freako

  1. The advertised key bindings (i.e. - M-n, M-p, and C-c M-p) don't appear to be in force.

I don't think these commands are broken. I have used them for years without issues. To debug the problem, I think more information is needed.

If you're in a haskell source file, and you have a *haskell* session opened for it.

  • What command are you running to load the source file into the repl?

  • What warnings or errors are in the repl at the time you are running the haskell error goto next/previous commands?

  1. When I use the equivalent commands (via M-x), I'm told, "No more notes from Haskell compiler," despite the fact that there are some compile errors occurring.

Testing this now. The only time I see this is when there are no errors or warnings in my interactive-haskell buffer.

creichert avatar Nov 03 '18 22:11 creichert

Hi Christopher,

Thanks for responding!

I’ve put my replies in-line, below, for context preservation.

-db

On Nov 3, 2018, at 3:31 PM, Christopher Reichert [email protected] wrote:

  1. The advertised key bindings (i.e. - M-n, M-p, and C-c M-p) don't appear to be in force.

I don't think these commands are broken. I have used them for years without issues. To debug the problem, I think more information is needed.

If you're in a haskell source file, and you have a *haskell* session opened for it.

  • What command are you running to load the source file into the repl? C-c C-l, which appears to be mapped to: haskell-process-load-file.

  • What warnings or errors are in the repl at the time you are running the haskell error goto next/previous commands? Here’s a silly simple example:

Adding this line of Haskell source to the end of the file:

temp = Proveded

Yields this error, in the haskell-process-log buffer:

/Users/a594349/Documents/Projects/HaskellMisc/singletons/Ex.hs:239:8-15: error: • Data constructor not in scope: Proveded • Perhaps you meant ‘Proved’ (imported from Data.Singletons.TH) | 239 | temp = Proveded | ^^^^^^^^ Fail <- ed, no modules loaded.

  1. When I use the equivalent commands (via M-x), I'm told, "No more notes from Haskell compiler," despite the fact that there are some compile errors occurring.

Testing this now. The only time I see this is when there are no errors or warnings in my interactive-haskell buffer. I get it for the case above. — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/haskell/haskell-mode/issues/1621#issuecomment-435625994, or mute the thread https://github.com/notifications/unsubscribe-auth/AA_7muSTMKvG_tt9RZ3ZlrkCbbyB7-OHks5urhlBgaJpZM4YMgrb.

capn-freako avatar Nov 03 '18 23:11 capn-freako

Is there any further debugging info I can generate, to get this moving again?

Also, any thoughts on that my compile errors show up in my haskell-process-log window, as opposed to my haskell GHCi session window?

Thanks!

capn-freako avatar Dec 13 '18 20:12 capn-freako

I also experience this, using cabal new-repl. The key thing seems to be that haskell-mode isn't classifying the error. This is the log msg I get on compile errors:

Unexpected response from haskell process. Haskell process command errored with: (error "Unexpected response from haskell process.")

And as such no highlighting occurs.

cfraz89 avatar Jan 25 '19 17:01 cfraz89

I think @cfraz89 's issue may be connected to https://github.com/haskell/haskell-mode/issues/1642. Not sure about the OP's issue.

rntz avatar Sep 11 '24 07:09 rntz