<table cellspacing="0" cellpadding="0" border="0" ><tr><td valign="top" style="font: inherit;">Thanks, Brandon, but Ryan gave me what I was looking for.<br><br>Michael<br><br>--- On <b>Tue, 8/31/10, Brandon S Allbery KF8NH <i>&lt;allbery@ece.cmu.edu&gt;</i></b> wrote:<br><blockquote style="border-left: 2px solid rgb(16, 16, 255); margin-left: 5px; padding-left: 5px;"><br>From: Brandon S Allbery KF8NH &lt;allbery@ece.cmu.edu&gt;<br>Subject: Re: [Haskell-cafe] On to applicative<br>To: haskell-cafe@haskell.org<br>Date: Tuesday, August 31, 2010, 4:35 PM<br><br><div class="plainMail">-----BEGIN PGP SIGNED MESSAGE-----<br>Hash: SHA1<br><br>On 8/31/10 13:27 , michael rice wrote:<br>&gt; So it's a type constructor, not a type? Could you please provide a simple<br>&gt; example of its usage?<br><br>Assuming you don't mean the trivial use in defining functions, see<br>Control.Monad.Instances:<br><br>&gt; instance Functor ((-&gt;) r) where<br>&gt;&nbsp; &nbsp;
 &nbsp; &nbsp;&nbsp;&nbsp;fmap = (.)<br>&gt; <br>&gt; instance Monad ((-&gt;) r) where<br>&gt;&nbsp; &nbsp; &nbsp; &nbsp;&nbsp;&nbsp;return = const<br>&gt;&nbsp; &nbsp; &nbsp; &nbsp;&nbsp;&nbsp;f &gt;&gt;= k = \ r -&gt; k (f r) r<br><br>(The above is the primitive reader functor/monad, see Control.Monad.Reader<br>for more information.)<br><br>- -- <br>brandon s. allbery&nbsp; &nbsp;&nbsp;&nbsp;[linux,solaris,freebsd,perl]&nbsp; &nbsp; &nbsp; <a ymailto="mailto:allbery@kf8nh.com" href="/mc/compose?to=allbery@kf8nh.com">allbery@kf8nh.com</a><br>system administrator&nbsp; [openafs,heimdal,too many hats]&nbsp; <a ymailto="mailto:allbery@ece.cmu.edu" href="/mc/compose?to=allbery@ece.cmu.edu">allbery@ece.cmu.edu</a><br>electrical and computer engineering, carnegie mellon university&nbsp; &nbsp; &nbsp; KF8NH<br>-----BEGIN PGP SIGNATURE-----<br>Version: GnuPG v2.0.10 (Darwin)<br>Comment: Using GnuPG with Mozilla - <a href="http://enigmail.mozdev.org/"
 target="_blank">http://enigmail.mozdev.org/</a><br><br>iEYEARECAAYFAkx9Z4EACgkQIn7hlCsL25WgrwCgvFQlObavv1fNOaKDjB/qbk8t<br>8+IAoLUrenXFzZFfJoYYvSy00uPctnaE<br>=ljiY<br>-----END PGP SIGNATURE-----<br>_______________________________________________<br>Haskell-Cafe mailing list<br><a ymailto="mailto:Haskell-Cafe@haskell.org" href="/mc/compose?to=Haskell-Cafe@haskell.org">Haskell-Cafe@haskell.org</a><br><a href="http://www.haskell.org/mailman/listinfo/haskell-cafe" target="_blank">http://www.haskell.org/mailman/listinfo/haskell-cafe</a><br></div></blockquote></td></tr></table><br>