Begin forwarded message:
From: Alexandre Bergel Alexandre.Bergel@inria.fr Date: April 21, 2009 10:20:10 AM CEDT To: Pharo Development Pharo-project@lists.gforge.inria.fr Subject: [Pharo-project] RuntimeStorage Reply-To: Pharo-project@lists.gforge.inria.fr
Dear List,
This morning, Jannik and I were surprised by the class RuntimeStorage.
RuntimeStorage>>initialize: capacity
byGroup := Dictionary new: 24. byName := IdentityDictionary new: 10000. elements := OrderedCollection new: capacity
Why byName reference an identify dictionary? Why not a dictionary? Names are usually accessed through their name as a String apparently (e.g., importing Smalltalk packages keys entities with a String). Should entities be accessed through a symbol instead of a string?
If entities are stored in an identity dictionary, then names must be accessed with a symbol. If entities are to be accessed with a string, then a dictionary should be used instead of an identitydictionary.
Cheers, Alexandre
-- _,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;: Alexandre Bergel http://www.bergel.eu ^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;.
Pharo-project mailing list Pharo-project@lists.gforge.inria.fr http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project