The Artima Developer Community


Errata for Programming in Scala, 2nd Edition
Chapter 1: A Scalable Language
Return to errata index.

Page 3 (PDF page 49):
The footnote reference at the end of the first paragraph as indicated by
the 1 in superscript seems like it should be placed directly after the
first occurrence of the word Scala rather than at the end of the
paragraph. At its currently location I expected I would find a footnote
regarding the use of Scala in large systems since this is the preceding
thought.
Page l (PDF page 50):
In the paragraph following the class CheckSumActor, you write "it
calculates a checksum from the current value of sum and sends the result
back to the requester using the message send requester ! sum"

That last piece should actually say "requester ! checksum"
Page 5 (PDF page 51):
First of all, I really enjoy reading this book, even though I have just
started :-)

You write that "In Raymond's work the bazaar is a metaphor for
open-source development", as though the cathedral isn't. But Raymond
compares in his essay two different types of open-source development
strategies, Emacs being the canonical "cathedral" example, and Linux
being the "bazaar" example. One the other hand, it's hard to imagine
proprietary, closed-source software being developed in bazaar style...
Page 11 (PDF page 57):
It states on p11:
"C and C++ ... function pointers can only refer to global functions, ..."

C++ supports member/method functions pointers; eg:

int (Fred::*)(char,float)

for a non-static member function of class Fred.
Page 14 (PDF page 60):
class MyClass(index: Int, name: String) {}

will NOT produce two private instance variables index and name.
It should be

class MyClass(val index: Int, val name: String) {}
(produces instance variables plus getters)

or 

class MyClass(var index: Int, var name: String) {}
(produces instance variables plus getters and setters)
Page 14 (PDF page 60):
class MyClass(index: Int, name: String) {}

it does produce two private instance variables (as does the associated
java program), they are simply not accessible outside the class, however
that may be the intention

Page number: Book type: Paperback book PDF eBook
Book version: (Or build date. Found on back of title page.)
Your feedback:
Your name: (optional)
Your email address: (optional) (will not be published)

Copyright © 2021 Artima, Inc. All rights reserved.