[Haskell-beginners] DPH help

Jasper Lievisse Adriaanse jasper at humppa.nl
Thu Dec 9 18:18:31 CET 2010


On Thu, Dec 09, 2010 at 05:52:09PM +0100, Luca Ciciriello wrote:
> Hi All.
> 
> I'm trying to load in GHCi the following code:
> 
> 
> {-# LANGUAGE Arrows #-}
> {-# LANGUAGE PArr, ParallelListComp #-}
> 
> module Test where
> 
> import Control.Arrow
> import Control.Parallel
> 
> dotp :: Num a => [:a:] -> [:a:] -> a
> dotp xs ys = sumP [:x * y | x <- xs | y <- ys:]
> 
> ......
> 
> 
> Then I get the error: 
> 
> Not in scope 'sumP'.
> 
> What I have to import to avoid this error? Where is defined sumP?
> 
> Thanks in advance for any answer.
> 
> Luca
> 
> _______________________________________________
> Beginners mailing list
> Beginners at haskell.org
> http://www.haskell.org/mailman/listinfo/beginners
Hi,

It seems you'll need Data.Array.Parallel.Prelude.Double, according to
http://www.haskell.org/ghc/docs/6.12-latest/html/libraries/dph-par-0.4.0/Data-Array-Parallel-Prelude-Double.html

this page has more info on using DPH
http://www.haskell.org/haskellwiki/Data_Parallel_Haskell .

-- 
Cheers,
Jasper

"Capable, generous men do not create victims, they nurture them."



More information about the Beginners mailing list