-
Notifications
You must be signed in to change notification settings - Fork 175
Better library interface? #696
Comments
I would like to start seeing these kind of types coming back: https://github.com/haskell/haskell-ide-engine/blob/master/hie-plugin-api/Haskell/Ide/Engine/SemanticTypes.hs#L23 See also https://ghc.haskell.org/trac/ghc/ticket/8809, which will hopefully result in properly typed errors in time. |
@alanz, in all honesty I would prefer |
I am fine with TypeResult being updated to that, main point is that we are already starting to impose structure on results from ghc-mod, makes more sense for that to happen inside ghc-mod. For types that make sense, as you want. |
@lierdakil you have to think about where all these Now of course we could parse ghc's log messages and expose a more useful representation but I think given that GHC HQ is working/thinking about adding more semantic info to the pretty printer this might be wasted effort. |
|
If we coordinate things right, we can start the types off here, and migrate them into GHC in time, when that work actually happens. |
@DanielG, at the very least GHC returns |
Yeah you're right of course. Looks like I didn't read your question properly ;) Anyways if you (or anyone else) feels like cleaning that up feel free. |
So... I've been thinking about improving interactive interface, and I've got a question.
Are there any plans to make library interface more typeful? As it is, it mostly returns
String
s and[String]
s. While this is ok for raw terminal output, re-parsing e.g. error messages back into severity, point and message seems more than a bit weird, does it not? Besides, things like(Int, Int, Int, Int)
just don't make sense to me.Am I missing something? Or is it just a legacy thing?
The text was updated successfully, but these errors were encountered: