#1928: Confusing type error message
-------------------------------------+--------------------------------------
Reporter: josef | Owner:
Type: bug | Status: new
Priority: low | Milestone: _|_
Component: Compiler (Type checker) | Version: 6.8.1
Severity: normal | Resolution:
Keywords: | Difficulty: Unknown
Testcase: | Architecture: Unknown
Os: Unknown |
-------------------------------------+--------------------------------------
Changes (by claus):
* cc: claus (added)
Comment:
I now seem to be running into similarly sub-optimal type error messages
more and more often. My first suggestion for improving these messages
would be to include full types for the expressions mentioned in the error
context (here: `bind_op`, `run_state`, `k`, `s`, `(k s)`, `run_state (k s)
s`). That is nearly always the information I'm looking for in these
incidents, and it is slightly frustrating that GHC's type error messages
elide most of this information - there is too much focussing, not enough
context (or rather, the context is type-free, in terms of expressions and
source references).
If that makes default error messages too long, I'd be happy with a flag
(`-verbose-type-errors`), possibly with numeric levels (0: current
behaviour; n: n levels of contexts are type annotated, context beyond that
remains type-free as now).
possibly related: #2360
--
Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/1928#comment:2>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
_______________________________________________
Glasgow-haskell-bugs mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs