SquareBracketAssociates / NewPharoByExample9

The PharoByExample9 repository since to have a broken history. Now the book versioning is moved to this repository to get work done.
10 stars 8 forks source link

Chapter 10 #8

Open Ducasse opened 2 years ago

Ducasse commented 2 years ago

There is a contradiction with demonstration of the program code in the chapter: some code snippets are placed in the text (smoothly with the explanation), on the other hand, another parts of code are placed into separate listings without references to them. Only listings 10-6, 10-12, 10-14..18 are refernced, and others are not. What the aim was to separate code snippets from the text? For example, in the subsection 10-2 Everything is an Object the sentence "Here are two examples." is surrounded by other text, there are not code around it - there are THREE listings jumped to the top of the page. It is unclear.

p. 122 Error: "At the end of this chap�ter, we added an implementation note on the object implementation for the curious reader." is a wrong statment and shoud be removed because the corresponding section was removed from this version of the book.

p. 123 Error in Listing 10-4: a part of the caption became a part of the code

p. 126 "As a consequence, we can send the same message to different objects, each of which may have its own method for responding to the message.

In the previous examples, we do not decide how the SmallInteger 3..." somewhere here should be a reference to the Listings 10-7, 10-8. Or move the code snippets directly to the place. (would be better on my mind)

p. 132 Error in the Listing 10-14: should be "Morph >> openInWorldReturnSelf" as denoted in the text below.

p. 133 " Imagine that we define the following three methods:" - U-upss, there are not any code here! It is separated to the Listings at the top of the page. Should be a reference istead the ":" or move the code into the text.

pp. 134-135. We are talking about anEllipse in the text an Figure 10-19, but we have the message "EllipseMorph new constructorString". May be would be better to define (or explain) anEllipse := EllipseMorph new ?

p. 134

Error: "and the method fullPrintOn: BorderedMorph is found" - BorderedMorph should be deleted "The message fullPrintOn: is looked up" should be "The method fullPrintOn: ..." p. 136

Error: "Similarly, class instance variables are just instance variables defined by a metaclass (a class whose instances are classes):" - but a metaclass has only single class, not classES. Should be "(a class whose instance is a class)". Error: "Sending the message now to the class Date is..." the class Date does not understand "now". Should be "Time now" or "Date today". Question: "You will therefore find the method blue defined on the class side of Color, not on the instance side." is some confusing because I CAN find the method blue on the INSTANCE SIDE. It has another meaning then a class one, but... May be "Color paleBlue" would be better? p. 137 What is the purpose of the Listings 10-21, 22, 23?

p. 141 A strange situation with code snippets that illustrate class instance variables: "Point class allInstVarNames" in the text and "WebServer class allInstVarNames" in the separate listing above. It is very hard to understand and to compare the results. It would be better to place both snippets to the text successively (as in the previous version). And WHY Point??? Earlier was "Object class allInstVarNames" that was natural.

p. 142 "We can now define a class method named uniqueInstance, as shown below." - Ups, Listing 10-32 is situated ABOVE

p. 143

Error: "Now we will look at an aspect of Pharo that is not so easily covered by our five rules: shared variables." There were SIX rules in the section 10.1 Error: "The variable Processor names an instance of ProcessScheduler" should be ProcessorScheduler p. 144 Inconsistance: "Undeclared ... the browser will normally prompt you to declare it, for example as a global or as an instance variable of the class." No, it prompt to declare AS CLASS VARIABLE, not as an instance variable of the class :(

p. 146

A question: Listing 10-35 has not a method's selector, and ColorName is something invented. Is it good? Color has not variable ColorName. typo: "TextConstants defines the variables CR that is bound..." shoud be "variable" p. 147 typo: "eventhough" should be "even though"

p. 149 "Although Pharo supports only single in�heritance, it is easy to share implementations of methods by packaging them as traits." - should be removed because the corresponding subsection was moved to the next chapter of this version of the book.

Ducasse commented 2 years ago

Finished!