Skip to content

Commit b67edde

Browse files
committed
testing/11.answer.scala, Gen.scala: SGen: map: commented-out line removed
def map[B](f: A => B): SGen[B] = SGen { g(_) map f } - //SGen(g andThen (_ map f))
1 parent 6b1c6f2 commit b67edde

File tree

2 files changed

+0
-2
lines changed

2 files changed

+0
-2
lines changed

answerkey/testing/11.answer.scala

-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@ case class SGen[+A](g: Int => Gen[A]) {
33

44
def map[B](f: A => B): SGen[B] =
55
SGen { g(_) map f }
6-
//SGen(g andThen (_ map f))
76

87
def flatMap[B](f: A => SGen[B]): SGen[B] = {
98
val g2: Int => Gen[B] = n => {

answers/src/main/scala/fpinscala/testing/Gen.scala

-1
Original file line numberDiff line numberDiff line change
@@ -291,7 +291,6 @@ case class SGen[+A](g: Int => Gen[A]) {
291291

292292
def map[B](f: A => B): SGen[B] =
293293
SGen { g(_) map f }
294-
//SGen(g andThen (_ map f))
295294

296295
def flatMap[B](f: A => SGen[B]): SGen[B] = {
297296
val g2: Int => Gen[B] = n => {

0 commit comments

Comments
 (0)