[Haskell-beginners] Fwd: Strange behavior

Luca Ciciriello luca_ciciriello at hotmail.com
Mon Aug 29 15:52:16 CEST 2011



Begin forwarded message:

> From: Luca Ciciriello <luca_ciciriello at hotmail.com>
> Subject: Re: [Haskell-beginners] Strange behavior
> Date: August 29, 2011 3:43:39 PM GMT+02:00
> To: Daniel Fischer <daniel.is.fischer at googlemail.com>
> 
> I'm very sorry. My mistake.
> foldP works as expected as shown by the code below:
> 
> {-# LANGUAGE PArr, ParallelListComp #-}
> {-# OPTIONS -fdph-seq #-}
> 
> module Test where
> 
> import GHC.PArr
> 
> 
> boolArr = [: False, False, False :]
> 
> isTrue :: Bool
> isTrue = foldP (||) False [: x | x <- boolArr :]
> 
> Here the result of "isTrue" is False, as expected.
> So, seems that the only problem is about "elemP"
> 
> Sorry again.
> 
> Luca.
> 
> 
> On Aug 29, 2011, at 3:28 PM, Daniel Fischer wrote:
> 
>> Hi Luca,
>> 
>> On Monday 29 August 2011, 11:57:05, you wrote:
>>> Ok, Thanks.
>>> This works fine. I found out that also mapP and sumP are working as
>>> expected, but elemP and foldP do not behave correctly.
>> 
>> Have you a short example of foldP behaving wrongly?
>> The dph people will have it easier to find the bug if they have one.
>> 
>> Cheers,
>> Daniel
>> 
> 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.haskell.org/pipermail/beginners/attachments/20110829/f491190a/attachment.htm>


More information about the Beginners mailing list