<table cellspacing="0" cellpadding="0" border="0" ><tr><td valign="top" style="font: inherit;">Yeah, I figured as much, but the code is copied right off the referenced page.<br><br>Michael<br><br><br>--- On <b>Thu, 8/26/10, Ivan Lazar Miljenovic <i><ivan.miljenovic@gmail.com></i></b> wrote:<br><blockquote style="border-left: 2px solid rgb(16, 16, 255); margin-left: 5px; padding-left: 5px;"><br>From: Ivan Lazar Miljenovic <ivan.miljenovic@gmail.com><br>Subject: Re: [Haskell-cafe] On to applicative<br>To: "michael rice" <nowgate@yahoo.com><br>Cc: haskell-cafe@haskell.org<br>Date: Thursday, August 26, 2010, 2:02 AM<br><br><div class="plainMail">On 26 August 2010 15:56, michael rice <<a ymailto="mailto:nowgate@yahoo.com" href="/mc/compose?to=nowgate@yahoo.com">nowgate@yahoo.com</a>> wrote:<br>><br>> From: <a href="http://en.wikibooks.org/wiki/Haskell/Applicative_Functors"
target="_blank">http://en.wikibooks.org/wiki/Haskell/Applicative_Functors</a><br>><br>> =============================<br>> import Control.Applicative<br>><br>> f :: (a -> b -> c)<br>> fmap :: Functor f => (d -> e) -> f d -> f e<br>> fmap f :: Functor f => f a -> f (b -> c) -- Identify d with a, and e with (b -> c)<br>><br>> sumsqr :: Int -> Int -> Int -- my f<br>> sumsqr i j = i*i+j*j<br>> =============================<br><br>The line with the error is the one beginning with "fmap f :: ..."; you<br>can't provide a variable/parameter on the left hand side of the ::<br><br>Also, why are you trying to re-define fmap?<br><br>--<br>Ivan Lazar Miljenovic<br><a ymailto="mailto:Ivan.Miljenovic@gmail.com" href="/mc/compose?to=Ivan.Miljenovic@gmail.com">Ivan.Miljenovic@gmail.com</a><br>IvanMiljenovic.wordpress.com<br></div></blockquote></td></tr></table><br>