Commits

John Kodumal committed 4b20a89

Fix a few errors and typos

  • Participants
  • Parent commits 1657b23

Comments (0)

Files changed (1)

 		<p>What about a monad instance?</p>	
 		<pre>
 implicit def FunctionMonad[R] = new Monad[({type l[a] = R=>a})#l] {
-	def flatMap[A, B](fa: R => A)(f: A => R => B) : R => B = (x => f(fa(x))(x))
+	def >>=[A, B](fa: R => A)(f: A => R => B) : R => B = (x => f(fa(x))(x))
 	...
 }
 		</pre>
 </pre>
 	</div>
 	<div class="slide">
-		<p>Let's redefine <code>makeAbsolute</code> with <code>Reader</code>:</p>
+		<p>Let's redefine <code>makeAbs</code> with <code>Reader</code>:</p>
 <pre class="scala">
 def makeAbs(url: URL): Reader[AbsURL, AbsURL] = 
 	Reader(base => AbsURL(base + url))
 <section class="slide">
 	<h2>Another take on composing monads</h2>
 	<div class="slide">
-		<p>An alternative formulation of <code>Monad</code> provides some insight into the composition problem. Instead of <code>bind</code>, it's sufficient to implement <code>join</code>:<p>
+		<p>An alternative formulation of <code>Monad</code> provides some insight into the composition problem. Instead of bind (<code>>>=</code>), it's sufficient to implement a method called <code>join</code>:<p>
 		<pre class="scala">
 trait Monad[F[_]] extends Applicative {
 	def join[A](fa: F[F[A]]): F[A]