Scriptable error messages

Hello Me and a fellow student are taking a course named Frontiers of Programming Languages, and in this course we should do a project with something. A while ago we were at a presentation of Feldspar, a Embedded Domain Specific Language, and one of the negative points of using haskell was that the error messages could be cryptic due to the various ways it was implemented. So we are now looking into the possibility of adding your own error messages to GHC as our project. We have about 8 weeks to implement, either all or some proof of concept. As such we are looking for comments, ideas and suggestions. Is this doable in GHC?, or what is needed. Thanks Daniel Gustafsson Simon Edwardsson Chalmers University of Technology (Gothenburg, Sweden)

So we are now looking into the possibility of adding your own error messages to GHC as our project. We have about 8 weeks to implement, either all or some proof of concept. As such we are looking for comments, ideas and suggestions. Is this doable in GHC?, or what is needed.
For related work, see the publications of Bastiaan Heeren, esp. his PhD thesis. Search the following page for "error:" http://people.cs.uu.nl/bastiaan/ Regards, Sean

GHC doesn't have any way to let you "plug in" new error messages. I imagine you mean in the type inference engine? Can you characterise more precisely what you want, perhaps by example. I do urge you to read the Utrecht work; they have done tremendous stuff on user-defined type rules and associated user-defined error messages. Simon | -----Original Message----- | From: glasgow-haskell-users-bounces@haskell.org [mailto:glasgow-haskell-users- | bounces@haskell.org] On Behalf Of Daniel Gustafsson | Sent: 21 January 2010 18:20 | To: glasgow-haskell-users@haskell.org | Subject: Scriptable error messages | | Hello | | Me and a fellow student are taking a course named Frontiers of | Programming Languages, and in this course we should do a project with | something. A while ago we were at a presentation of Feldspar, a | Embedded Domain Specific Language, and one of the negative points of | using haskell was that the error messages could be cryptic due to the | various ways it was implemented. | | So we are now looking into the possibility of adding your own error | messages to GHC as our project. We have about 8 weeks to implement, | either all or some proof of concept. As such we are looking for | comments, ideas and suggestions. Is this doable in GHC?, or what is | needed. | | Thanks | | Daniel Gustafsson | Simon Edwardsson | Chalmers University of Technology (Gothenburg, Sweden) | _______________________________________________ | Glasgow-haskell-users mailing list | Glasgow-haskell-users@haskell.org | http://www.haskell.org/mailman/listinfo/glasgow-haskell-users

Dear Daniel, The Utrecht work can be found at: http://www.cs.uu.nl/wiki/bin/view/Helium/WebHome. Helium is a Haskell subset that strives to produce more understandable error messages. The theory behind it can be found in http://people.cs.uu.nl/bastiaan/phdthesis/index.html. Regards, Robert ________________________________________ From: glasgow-haskell-users-bounces@haskell.org [glasgow-haskell-users-bounces@haskell.org] On Behalf Of Simon Peyton-Jones [simonpj@microsoft.com] Sent: Friday, January 22, 2010 1:13 PM To: Daniel Gustafsson; glasgow-haskell-users@haskell.org Subject: RE: Scriptable error messages GHC doesn't have any way to let you "plug in" new error messages. I imagine you mean in the type inference engine? Can you characterise more precisely what you want, perhaps by example. I do urge you to read the Utrecht work; they have done tremendous stuff on user-defined type rules and associated user-defined error messages. Simon | -----Original Message----- | From: glasgow-haskell-users-bounces@haskell.org [mailto:glasgow-haskell-users- | bounces@haskell.org] On Behalf Of Daniel Gustafsson | Sent: 21 January 2010 18:20 | To: glasgow-haskell-users@haskell.org | Subject: Scriptable error messages | | Hello | | Me and a fellow student are taking a course named Frontiers of | Programming Languages, and in this course we should do a project with | something. A while ago we were at a presentation of Feldspar, a | Embedded Domain Specific Language, and one of the negative points of | using haskell was that the error messages could be cryptic due to the | various ways it was implemented. | | So we are now looking into the possibility of adding your own error | messages to GHC as our project. We have about 8 weeks to implement, | either all or some proof of concept. As such we are looking for | comments, ideas and suggestions. Is this doable in GHC?, or what is | needed. | | Thanks | | Daniel Gustafsson | Simon Edwardsson | Chalmers University of Technology (Gothenburg, Sweden) | _______________________________________________ | Glasgow-haskell-users mailing list | Glasgow-haskell-users@haskell.org | http://www.haskell.org/mailman/listinfo/glasgow-haskell-users _______________________________________________ Glasgow-haskell-users mailing list Glasgow-haskell-users@haskell.org http://www.haskell.org/mailman/listinfo/glasgow-haskell-users The information contained in this message may be confidential and legally protected under applicable law. The message is intended solely for the addressee(s). If you are not the intended recipient, you are hereby notified that any use, forwarding, dissemination, or reproduction of this message is strictly prohibited and may be unlawful. If you are not the intended recipient, please contact the sender by return e-mail and destroy all copies of the original message.

Daniel,
A while ago we were at a presentation of Feldspar, a Embedded Domain Specific Language, and one of the negative points of using haskell was that the error messages could be cryptic due to the various ways it was implemented.
Incidentally, but actually by no means surprisingly, this very same issue. amongst others, was once more brought up by Jeremy Siek in his invited talk at PEPM 2010, just a few days ago: http://ecee.colorado.edu/~siek/pepm-keynote.pdf . Cheers, Stefan
participants (5)
-
Daniel Gustafsson
-
Herk, Robert van
-
Sean Leather
-
Simon Peyton-Jones
-
Stefan Holdermans