Re: Parallel list comprehensions

2006-02-04 Thread Andrew Pimlott
On Sat, Feb 04, 2006 at 06:31:56PM +, Jon Fairbairn wrote: > There ought to be a list_product somewhere (I mean [1..] > `list_product` [4..] == > [(1,4),(2,4),(1,5),(3,4),(2,5),(1,6),...]). Is there? This is called "fair conjunction" in "Backtracking, Interleaving, and Terminating Monad Transf

Re: Test performance impact (was: The dreaded M-R)

2006-02-02 Thread Andrew Pimlott
On Thu, Feb 02, 2006 at 12:34:30PM -, Simon Marlow wrote: > Still, you could argue that it doesn't actually tell you the cause of > the problem: namely that i&j are being evaluated twice as often as you > might expect by looking at the code. Would not the "entries" count in the profile tip you

Re: The dreaded M-R

2006-02-01 Thread Andrew Pimlott
On Wed, Feb 01, 2006 at 10:32:26AM -, Simon Marlow wrote: > On 31 January 2006 17:48, Andrew Pimlott wrote: > > This indicates that the warning "wouldn't happen much" _when you want > > sharing_. But it would happen all the time when you don't want > >

Re: The dreaded M-R

2006-01-31 Thread Andrew Pimlott
On Tue, Jan 31, 2006 at 10:17:57AM -, Simon Marlow wrote: > On 30 January 2006 21:49, Andrew Pimlott wrote: > > In the present case, people aren't (only) opposing the M-R out of > > principle, but because they actually use overloaded variable > > definitions and (a

Re: The dreaded M-R

2006-01-30 Thread Andrew Pimlott
On Tue, Jan 31, 2006 at 12:52:51AM +, Neil Mitchell wrote: > > Second, a warning about "loss of sharing" may befuddle beginners (who > > are usually not taught to write type signatures at the start). > > Are standards documents the place for prescribing which warnings > should be raised, and u

Re: The dreaded M-R

2006-01-30 Thread Andrew Pimlott
On Tue, Jan 31, 2006 at 12:57:18AM +0100, [EMAIL PROTECTED] wrote: > Quoting Andrew Pimlott <[EMAIL PROTECTED]>: > > >On Mon, Jan 30, 2006 at 11:06:29PM +0100, [EMAIL PROTECTED] wrote: > >>So I envisage that you'd turn off the warning in the same way as > >

Re: The dreaded M-R

2006-01-30 Thread Andrew Pimlott
On Mon, Jan 30, 2006 at 11:06:29PM +0100, [EMAIL PROTECTED] wrote: > Quoting Andrew Pimlott <[EMAIL PROTECTED]>: > >In the present case, people aren't (only) opposing the M-R out of > >principle, but because they actually use overloaded variable definitions > >

Re: The dreaded M-R

2006-01-30 Thread Andrew Pimlott
On Mon, Jan 30, 2006 at 04:45:56PM -, Simon Marlow wrote: > Given the new evidence that it's actually rather hard to demonstrate any > performance loss in the absence of the M-R with GHC, I'm attracted to > the option of removing it in favour of a warning. I caution against the hope that warni

Re: Removal candidates in patterns

2006-01-27 Thread Andrew Pimlott
On Thu, Jan 26, 2006 at 11:03:01PM +, Ian Lynagh wrote: > On Thu, Jan 26, 2006 at 07:35:42PM +, Olaf Chitil wrote: > > If Haskell had a type for natural numbers I'd be in favour of n+k and k > > patterns (working only for this type, not any other numerical type). > > Haskell (FSVO "Haskel

Re: The dreaded M-R

2006-01-27 Thread Andrew Pimlott
On Fri, Jan 27, 2006 at 07:04:43PM +0100, Benjamin Franksen wrote: > All normal bindings (i.e. using '=') should be as polymorphic and > general as possible. I agree with the position in the Ben's email. Also, especially since much of the discussion has considered the impact on beginners, I want