[Haskell-cafe] IDE?

Claus Reinke claus.reinke at talk21.com
Sat Jun 16 19:49:25 EDT 2007


> I wish to have an editor that ran GHC[I] every few seconds or so, and 
> underlined sites of syntax errors in red.  This would save me a lot of 
> back-and-forth.  If an editor did this, I would switch (from kate) in a 
> heartbeat.

in vim, that's called quickfix mode, and vim is certainly not the only
editor to provide such a feature. you need to specify the format of
GHC error messages, and how to call GHCi, then ':make' will call
GHCi on the current file, store and parse any error messages, and
provide them in a quickfix window (:help quickfix). from each error,
you can jump directly to the corresponding source location, or you
can jump through the list or errors, with the current error message
shown in the quickfix window.

http://vimdoc.sourceforge.net/htmldoc/quickfix.html#quickfix

i wouldn't recommend running that kind of check automatically at
arbitrary moments in your editing process, but you can if you want, 
using autocommands (:help :autocmd), and since the list of error 
locations is available (:help getqflist()), you could highlight them 
directly in the source as well if you wanted to..

claus



More information about the Haskell-Cafe mailing list