RE: GHC's error messages are too verbose?
Two thoughts on this error-message thread. 1. It'd be easy to add a flag to trim the number of levels of context you get. It'd mean yet another flag though. 2. Bryan got a rather long chunk of program text. GHC tries to trim the size of program chunks by printing ... after a certain depth. But this depth mechanism isn't working well for Bryan's example. This should not be at all hard to fix -- it look as it may be to do with do-notation. Simon | -Original Message- | From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On | Behalf Of Neil Mitchell | Sent: 14 April 2007 11:40 | To: Bryan O'Sullivan | Cc: glasgow-haskell-users@haskell.org | Subject: Re: GHC's error messages are too verbose? | | Hi | | I've long wondered why GHC issues such prolix error messages when it | runs into a problem. | | I am primarily a Hugs user, compiling and running only with GHC once | the code works, and only if I really need the speed - which is quite | rare. but I've been hacking a project in GHCi recently (requiring | template haskell), and I found the GHC error messages way too verbose. | | Compilers for other languages seem content with as little as one line of | output per error (which I am not advocating), or a few lines of source | with the problem highlighted, but I rarely see more. Hugs also tends | towards the terse side, but I've never found this to be a problem. | | The most important thing in an error message for me is the line | number. Next I want to see the type of error - syntax, type, instance | etc. Then I want to see just a few lexemes of context so I can find | where to start looking. If after all that I didn't figure out where | the error was, I'd want more context - but I rarely want it with Hugs. | | I much prefer the Hugs error messages, although this may be experience | with Hugs, rather than an issue with GHC. | | Thanks | | Neil | ___ | 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
Re: Happy bug
On 4/16/07, Isaac Dupree [EMAIL PROTECTED] wrote: The code generated by Alex is perfectly good Haskell98+cpp, except: #if __GLASGOW_HASKELL__ = 603 #include ghcconfig.h #else #include config.h #endif If that else is modified to only trigger if we're using GHC at all[1], then plain C pre-processing[2] makes it run fine in Hugs, too. [1] (which I don't know how to do, I actually just deleted the line #include config.h from the generated file) Guarding the whole block with #ifdef __GLASGOW_HASKELL__ should do it. Cheers, Dinko ___ Glasgow-haskell-users mailing list Glasgow-haskell-users@haskell.org http://www.haskell.org/mailman/listinfo/glasgow-haskell-users
RE: diagnostics' identifier quoting style
A reasonable point. It's one of those matters of taste -- there will be people who hate double-quotes too. Yet another flag? Really we should use colours etc. Any volunteers? Simon | -Original Message- | From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On | Behalf Of Isaac Dupree | Sent: 14 April 2007 00:28 | To: GHC Users | Subject: diagnostics' identifier quoting style | | -BEGIN PGP SIGNED MESSAGE- | Hash: SHA1 | | Here's a random message selected from building GHC: | Warning: Defined but not used: `res_ty'' | (the identifier is res_ty{PRIME}, where {PRIME} is the ' mark) | | Note that quotes are left:` (grave accent) and right:' (ASCII single | quote). Besides this being theoretically incorrect, identifiers can | include the ' symbol (generally meaning more like prime than single | quote...), making this look odd. Maybe it should show the | identifier-string so that it just has ordinary double-quotes around it?, | looking like: | Warning: Defined but not used: res_ty' | | | Isaac | -BEGIN PGP SIGNATURE- | Version: GnuPG v1.4.3 (GNU/Linux) | Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org | | iD8DBQFGIBIQHgcxvIWYTTURAt5TAKC7Rkbgqr7RsuGEMgyXsMm7kbiIswCdHGs2 | lJY8FH7CR8YXwJ47g+0gNWw= | =ptnw | -END PGP SIGNATURE- | ___ | 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
Re: GHC's error messages are too verbose?
This reminds me of the (closed) bug report about long error messages: http://hackage.haskell.org/trac/ghc/ticket/719 I'm not convinced the original bug is fixed, and it seems somewhat similar to Bryan's example, being a do-expression. Cheers, Simon Simon Peyton-Jones wrote: Two thoughts on this error-message thread. 1. It'd be easy to add a flag to trim the number of levels of context you get. It'd mean yet another flag though. 2. Bryan got a rather long chunk of program text. GHC tries to trim the size of program chunks by printing ... after a certain depth. But this depth mechanism isn't working well for Bryan's example. This should not be at all hard to fix -- it look as it may be to do with do-notation. Simon | -Original Message- | From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On | Behalf Of Neil Mitchell | Sent: 14 April 2007 11:40 | To: Bryan O'Sullivan | Cc: glasgow-haskell-users@haskell.org | Subject: Re: GHC's error messages are too verbose? | | Hi | | I've long wondered why GHC issues such prolix error messages when it | runs into a problem. | | I am primarily a Hugs user, compiling and running only with GHC once | the code works, and only if I really need the speed - which is quite | rare. but I've been hacking a project in GHCi recently (requiring | template haskell), and I found the GHC error messages way too verbose. | | Compilers for other languages seem content with as little as one line of | output per error (which I am not advocating), or a few lines of source | with the problem highlighted, but I rarely see more. Hugs also tends | towards the terse side, but I've never found this to be a problem. | | The most important thing in an error message for me is the line | number. Next I want to see the type of error - syntax, type, instance | etc. Then I want to see just a few lexemes of context so I can find | where to start looking. If after all that I didn't figure out where | the error was, I'd want more context - but I rarely want it with Hugs. | | I much prefer the Hugs error messages, although this may be experience | with Hugs, rather than an issue with GHC. | | Thanks | | Neil | ___ | 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 ___ Glasgow-haskell-users mailing list Glasgow-haskell-users@haskell.org http://www.haskell.org/mailman/listinfo/glasgow-haskell-users
Release plans
We'd like to solicit comments from the community on our plans for future GHC releases. The current situation is this: - 6.6.1 is nearly ready to go (perhaps this week, please test the RC!) - 6.6.2 has ~35 outstanding tickets - 6.8 has ~150 outstanding tickets the default option would be to work on 6.6.2 and release it in a couple of months, while continuing to work on 6.8 for a release in ~6 months or so. However, there's another option: we could skip 6.6.2 and head straight for 6.8, the idea being to stabilise 6.8 with the existing feature set (plus a few important developments in progress), so that we can get these features out in a release sooner rather than later. The 6.6.2 tickets would be moved to 6.8, and most of the outstanding 6.8 tickets would be pushed to 6.8.1 or later, retaining only the features/bug-fixes that are essential for the 6.8 release. Here's a quick summary of the major developments that we already have in the 6.8 codebase: - Associated data types, and the new FC intermediate language - GHCi debugger (although there's an overhaul of the breakpoint support almost ready to go in) - Coverage (HPC) - GADTs + typeclasses - more packages moved from core to extralibs - GHC API changes, compile to object code inside GHCi - performance improvements: simplifier rewrite, and SpecConstr improvements - standalone deriving declarations - left-to-right impredicative instantiation: runST $ foo Here are the features in progress that we'd like to get into 6.8: - pointer-tagging (15% perf improvement for compiled code) - get external core working again - base package breakup (see discussion on libraries list) - list fusion We think the above feature set makes for a pretty strong 6.8 release. What do you think of this plan? Are there features/bug-fixes that you really want to see in 6.8? Cheers, Simon the GHC Team ___ Glasgow-haskell-users mailing list Glasgow-haskell-users@haskell.org http://www.haskell.org/mailman/listinfo/glasgow-haskell-users
Re: diagnostics' identifier quoting style
If the output messages were in some sort of structured format then a simple post processor could convert them into whatever style is requested. A post-processor that generates the current messages could be tacked-on to the end of the current compile tool-chain for backward compatibility. This would open the door for tools that colorize the output or provide a mechanism for enhanced IDE integration. Simon Peyton-Jones wrote: A reasonable point. It's one of those matters of taste -- there will be people who hate double-quotes too. Yet another flag? Really we should use colours etc. Any volunteers? Simon | -Original Message- | From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On | Behalf Of Isaac Dupree | Sent: 14 April 2007 00:28 | To: GHC Users | Subject: diagnostics' identifier quoting style | | -BEGIN PGP SIGNED MESSAGE- | Hash: SHA1 | | Here's a random message selected from building GHC: | Warning: Defined but not used: `res_ty'' | (the identifier is res_ty{PRIME}, where {PRIME} is the ' mark) | | Note that quotes are left:` (grave accent) and right:' (ASCII single | quote). Besides this being theoretically incorrect, identifiers can | include the ' symbol (generally meaning more like prime than single | quote...), making this look odd. Maybe it should show the | identifier-string so that it just has ordinary double-quotes around it?, | looking like: | Warning: Defined but not used: res_ty' | | | Isaac | -BEGIN PGP SIGNATURE- | Version: GnuPG v1.4.3 (GNU/Linux) | Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org | | iD8DBQFGIBIQHgcxvIWYTTURAt5TAKC7Rkbgqr7RsuGEMgyXsMm7kbiIswCdHGs2 | lJY8FH7CR8YXwJ47g+0gNWw= | =ptnw | -END PGP SIGNATURE- | ___ | 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
Re: Release plans
On 4/16/07, Simon Marlow [EMAIL PROTECTED] wrote: What do you think of this plan? Are there features/bug-fixes that you really want to see in 6.8? I'd rather see ghc 6.8 out early. What about the implementation of associated/indexed type _synonyms_? Cheers, JP. ___ Glasgow-haskell-users mailing list Glasgow-haskell-users@haskell.org http://www.haskell.org/mailman/listinfo/glasgow-haskell-users
Re: diagnostics' identifier quoting style
The messages aren't in a structured format currently; we just use Text.PrettyPrint.HughesPJ (in fact an internal version thereof). However we do paramterise the pretty printer by various things; e.g. whether to qualify identifiers when printing them out, so paramterising by some style options wouldn't be hard. It wouldn't be quite as general as having a type of messages that contained bits of HsSyn, though, but that would require more major refactoring. Cheers, Simon Al Falloon wrote: If the output messages were in some sort of structured format then a simple post processor could convert them into whatever style is requested. A post-processor that generates the current messages could be tacked-on to the end of the current compile tool-chain for backward compatibility. This would open the door for tools that colorize the output or provide a mechanism for enhanced IDE integration. Simon Peyton-Jones wrote: A reasonable point. It's one of those matters of taste -- there will be people who hate double-quotes too. Yet another flag? Really we should use colours etc. Any volunteers? Simon | -Original Message- | From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On | Behalf Of Isaac Dupree | Sent: 14 April 2007 00:28 | To: GHC Users | Subject: diagnostics' identifier quoting style | | -BEGIN PGP SIGNED MESSAGE- | Hash: SHA1 | | Here's a random message selected from building GHC: | Warning: Defined but not used: `res_ty'' | (the identifier is res_ty{PRIME}, where {PRIME} is the ' mark) | | Note that quotes are left:` (grave accent) and right:' (ASCII single | quote). Besides this being theoretically incorrect, identifiers can | include the ' symbol (generally meaning more like prime than single | quote...), making this look odd. Maybe it should show the | identifier-string so that it just has ordinary double-quotes around it?, | looking like: | Warning: Defined but not used: res_ty' | | | Isaac | -BEGIN PGP SIGNATURE- | Version: GnuPG v1.4.3 (GNU/Linux) | Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org | | iD8DBQFGIBIQHgcxvIWYTTURAt5TAKC7Rkbgqr7RsuGEMgyXsMm7kbiIswCdHGs2 | lJY8FH7CR8YXwJ47g+0gNWw= | =ptnw | -END PGP SIGNATURE- | ___ | 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 ___ Glasgow-haskell-users mailing list Glasgow-haskell-users@haskell.org http://www.haskell.org/mailman/listinfo/glasgow-haskell-users
RE: Release plans
| What about the implementation of associated/indexed type _synonyms_? working on it now. I v much hope it'll make the 6.8 release, but I don't want to hold it up for that. Almost certainly *some* variant of indexed type synonyms will be in though. Simon ___ Glasgow-haskell-users mailing list Glasgow-haskell-users@haskell.org http://www.haskell.org/mailman/listinfo/glasgow-haskell-users
Re: Release plans
On 4/16/07, Simon Marlow [EMAIL PROTECTED] wrote: Are there features/bug-fixes that you really want to see in 6.8? How about dynamic libraries? (there are a few 6.8 tickets for that I think) ___ Glasgow-haskell-users mailing list Glasgow-haskell-users@haskell.org http://www.haskell.org/mailman/listinfo/glasgow-haskell-users
Re: Release plans
On Mon, Apr 16, 2007 at 03:54:56PM +0100, Simon Marlow wrote: We'd like to solicit comments from the community on our plans for future GHC releases. The current situation is this: - 6.6.1 is nearly ready to go (perhaps this week, please test the RC!) - 6.6.2 has ~35 outstanding tickets - 6.8 has ~150 outstanding tickets the default option would be to work on 6.6.2 and release it in a couple of months, while continuing to work on 6.8 for a release in ~6 months or so. ... Here's a quick summary of the major developments that we already have in the 6.8 codebase: Could you summarize the major tickets for 6.6.2? I'd tentatively vote for an accelerated 6.8. I'm quite excited about the associated types and the GADT-typeclass interactions. -- David Roundy Department of Physics Oregon State University ___ Glasgow-haskell-users mailing list Glasgow-haskell-users@haskell.org http://www.haskell.org/mailman/listinfo/glasgow-haskell-users
Re: Release plans
I vote for 6.8. Rene. ___ Glasgow-haskell-users mailing list Glasgow-haskell-users@haskell.org http://www.haskell.org/mailman/listinfo/glasgow-haskell-users
Re: Release plans
On Mon, Apr 16, 2007 at 10:00:32AM -0700, David Roundy wrote: Could you summarize the major tickets for 6.6.2? The list milestoned or 6.6.2 is here: http://hackage.haskell.org/trac/ghc/query?status=newstatus=assignedstatus=reopenedmilestone=6.6.2order=priority Not all of them would necessarily be fixed for 6.6.2, of course. Thanks Ian ___ Glasgow-haskell-users mailing list Glasgow-haskell-users@haskell.org http://www.haskell.org/mailman/listinfo/glasgow-haskell-users
Re: Release plans
simonmarhaskell: We'd like to solicit comments from the community on our plans for future GHC releases. The current situation is this: - 6.6.1 is nearly ready to go (perhaps this week, please test the RC!) - 6.6.2 has ~35 outstanding tickets - 6.8 has ~150 outstanding tickets the default option would be to work on 6.6.2 and release it in a couple of months, while continuing to work on 6.8 for a release in ~6 months or so. However, there's another option: we could skip 6.6.2 and head straight for 6.8, the idea being to stabilise 6.8 with the existing feature set (plus a few important developments in progress), so that we can get these features out in a release sooner rather than later. The 6.6.2 tickets would be moved to 6.8, and most of the outstanding 6.8 tickets would be pushed to 6.8.1 or later, retaining only the features/bug-fixes that are essential for the 6.8 release. Here's a quick summary of the major developments that we already have in the 6.8 codebase: - Associated data types, and the new FC intermediate language - GHCi debugger (although there's an overhaul of the breakpoint support almost ready to go in) - Coverage (HPC) - GADTs + typeclasses - more packages moved from core to extralibs - GHC API changes, compile to object code inside GHCi - performance improvements: simplifier rewrite, and SpecConstr improvements - standalone deriving declarations - left-to-right impredicative instantiation: runST $ foo Here are the features in progress that we'd like to get into 6.8: - pointer-tagging (15% perf improvement for compiled code) - get external core working again - base package breakup (see discussion on libraries list) Yes. Along with the new release of bytestring, on top of stream fusion. - list fusion Ok. Still needs some work on GHC's optimiser, but the fusion system itself is done. So this is definitely doable. We think the above feature set makes for a pretty strong 6.8 release. What do you think of this plan? Are there features/bug-fixes that you really want to see in 6.8? Sounds like a good plan. 6.8 here we come! -- Don ___ Glasgow-haskell-users mailing list Glasgow-haskell-users@haskell.org http://www.haskell.org/mailman/listinfo/glasgow-haskell-users
Re: Release plans
On Mon, Apr 16, 2007 at 03:54:56PM +0100, Simon Marlow wrote: - left-to-right impredicative instantiation: runST $ foo This concerns me. With each ad-hoc extension of the type system, I worry that soon the GHC type system will become so byzantine and ill-specified that the type checker can only be cloned, not substantially improved on. I personally have a type checker idea I am working on, but I doubt I will ever be able to implement features such as this, because the type checking abstraction is now leaking badly. Once the Hindley-Damas-Milner algorithm is exposed, I fear programmers will rely on it and progress in Haskell typechecker implementation will be effectively halted. (Yes, I know I'm a bit late in complaining...) - list fusion Nitpick - you did mean stream fusion, right? We think the above feature set makes for a pretty strong 6.8 release. What do you think of this plan? Are there features/bug-fixes that you really want to see in 6.8? Good code generation for loops. I understand they are rare in practice, but it's kinda disheartening to write memset() and see in the asm loop 11 memory references, 9 to the stack (numbers from unreliable memory). I don't mind the plan, either. Stefan ___ Glasgow-haskell-users mailing list Glasgow-haskell-users@haskell.org http://www.haskell.org/mailman/listinfo/glasgow-haskell-users
Re: Release plans
On Apr 16, 2007, at 15:54 , Simon Marlow wrote: - left-to-right impredicative instantiation: runST $ foo Is this really a good idea? This will just make people complain that € (x € f = f x) doesn't work when you do foo € runST (or maybe it does?). -- Lennart ___ Glasgow-haskell-users mailing list Glasgow-haskell-users@haskell.org http://www.haskell.org/mailman/listinfo/glasgow-haskell-users