[squeak-dev] The Trunk: Protocols-nice.14.mcz

commits at source.squeak.org commits at source.squeak.org
Tue Oct 20 22:58:54 UTC 2009


Nicolas Cellier uploaded a new version of Protocols to project The Trunk:
http://source.squeak.org/trunk/Protocols-nice.14.mcz

==================== Summary ====================

Name: Protocols-nice.14
Author: nice
Time: 21 October 2009, 12:58:29 pm
UUID: d0d702b0-ef9b-446d-b9d0-f9dc86e2669a
Ancestors: Protocols-nice.13

Use #keys rather than #fasterKeys
Note that pattern (x keys asArray sort) could as well be written (x keys sort) now that keys returns an Array...
This #asArray is here solely for cross-dialect/fork compatibility.

=============== Diff against Protocols-nice.13 ===============

Item was changed:
  ----- Method: Vocabulary>>strings (in category 'initialization') -----
  strings
  	| strm |
  	"Get started making a vocabulary for a foreign language.  That is, build a method like #addGermanVocabulary, but for another language.  
  	Returns this vocabulary in the same form used as the input used for foreign languages.  To avoid string quote problems, execute
  	Transcript show: Vocabulary eToyVocabulary strings.
  and copy the text from the transcript to the method you are building."
  
  	"selector		wording			documentation"
  
  strm := WriteStream on: (String new: 400).
+ methodInterfaces keys asArray sort do: [:sel |
- methodInterfaces fasterKeys sort do: [:sel |
  	strm cr; nextPut: $(;
  		nextPutAll: sel; tab; tab; tab; nextPut: $';
  		nextPutAll: (methodInterfaces at: sel) wording;
  		nextPut: $'; tab; tab; tab; nextPut: $';
  		nextPutAll: (methodInterfaces at: sel) documentation;
  		nextPut: $'; nextPut: $)].
  ^ strm contents!




More information about the Squeak-dev mailing list