The Author Online Book Forums are Moving

The Author Online Book Forums will soon redirect to Manning's liveBook and liveVideo. All book forum content will migrate to liveBook's discussion forum and all video forum content will migrate to liveVideo. Log in to liveBook or liveVideo with your Manning credentials to join the discussion!

Thank you for your engagement in the AoF over the years! We look forward to offering you a more enhanced forum experience.

lutzhank (61) [Avatar] Offline
#1
MEAP 11/02/2010

1) Header for Listing 2.3
orig: "Listing 2.3 An ordinal class in Scala"

The following code is not a class in Scala and later the code is referenced as
"Ordinal.scala script...", but never marked as such, therefore
suggestion: change the original header in
"Listing 2.3 Ordinal.scala script"
which marks the code as the later referenced script.

2) After Listing 2.3, first paragraph, 4th line
orig:
"...longer need to provide a break for each case because in Scala you can’t overflow into other case clauses..."

"fall-through" might be another term for this behavior (read in Code Complete, Steve McConnell) and here
http://en.wikipedia.org/wiki/Switch_statement

3) After Listing 2.3, first paragraph, second last sentence
orig:
"In Scala default is replaced with case..."

Font of the word "default" is the same as the words before and after, therefore it may not be clear on first read that the Java-"default" from the java example is meant here.

suggestion:
emphasize the word "default" e.g. via code-font.

4) After Listing 2.3, end of first paragraph
orig:
"To run the Ordinal.scala script, execute the following command
from a command prompt:
scala Ordinal.scala <your input>"

reason: may break the train of thought when running the script is done here, because before and after you talk about case.

Therefore my suggestion:
Close this introduction with the above text (execution of the script) at the end of the page, like
"...it ignores it without providing any sort of feedback.
To run the Ordinal.scala script..."

------------------------------
Corrected MEAP version
Message was edited by: lutzhank