underscoreio/essential-scala

Errors Reported by Jon Pearce

Closed this issue · 1 comments

  • page 80: Broken links "[JSON][linkjson]" and "[BNF][link-bnf]" in Section 4.7.0.2 JSON
  • page 86: "Empty()" should be replaced with "End()"
  • page 214: "benefited from fold as we remove the duplication" should read "benefited from fold as we remove[d] the duplication"
  • page 100: "final case object EmptyA extends Maybe[A]" should read "final case class EmptyA extends Maybe[A]"; this correction has been made in the subsequent code listing
  • page 100: Two instances of broken links/italics at the very begining of Section 5.5.3 in "[ˆmonads]"
  • page 101: In "val list: LinkedList[Int] = Pair(1, Pair(2, Pair(3, Empty)))", Empty should be "EndInt"
  • Page 121: The code listing at the top of the page contains two duplicate lines i.e. one instance of each of "var mutable = 1" and "mutable = 2" should be deleted
  • Page 124: In the definition of getOrElse for None, the compiler reports the error " error: not found: type A"
  • Page 143: In "method fromLessThan defined the companion object", add "in" before "the companion object"
  • Page 151: Chanage "mne" to "men" in "implemnetation"
  • Page 162: Identifier "res4" isn't consistent with the name ("res") shown in the preceding output
  • Page 162: Five instances of "val" may be deleted from the case class definitions of "User" and "Anonymous"
  • Page 181: In B.6.2.1, one of the two instances of "import scala.collection.mutable" may be deleted
  • Page 222: "Some(123).isEMpty" should read "Some(123).isEmpty"
  • Page 225: In "allFilms.foldLeft(0)((a, b) => a.imdbRating + b.imdbRating) / films.length", "0" should be replaced with "0.0" (Double) and "a.imdbRating" should be replaced with "a" (Double, not Film)
  • Page 226: "We these three pieces we can solve the problem" should be "With these three pieces..."
  • Page 229: In C.5.24, one may need to replace "${director.name}" with "${director.firstName} ${director.lastName}"; in addition, the compiler complains with "error: illegal start of simple pattern" if the comprehension is not assigned to a val (which gets type Unit)
  • Page 244: Something is wrong with the mark-up tags of the code given for "object Positive"

I've addressed all of these except pave 229 in a soon-to-be-merged branch (feature/bugfixes). I believe the page 229 one is because I defined two different versions of Director and Film. The second version has def name on it but readers might end using the first version for this exercise. I think there's a bigger problem here than just the name of that method, but I'm going to merge the low hanging fruit here and factor that one issue out into its own thing.