May be cyrille the best way would be to: rewrite small dictionary using the double arrays and to do it from scratch. I do not know if you want to do that but it could be fun to see if it goes faster than a dictionary for a small sets of items. Since it was designed for that. lukas told me that this class is coming from the refactoringBrowser on VW. Stef
I think SmallDictionary should be removed from the core. There are no users.
Lukas
2009/7/3 Cyrille Delaunay <cy.delaunay@gmail.com>:
SmallDictionary, unlike all subclasses of Dictionary, never used ( and initialize ) the instance variable: 'array'. Associations are stored with a key array ( called 'keys' ) and a value array ( 'values' ). Problem is that the method #scanFor: is define in Dictionary ( and not overriden ) with this code : scanFor: anObject | element start finish | finish := array size. .... 'array' is nil and it cause bugs for those methods : -> #includesAssociation: -> #associationAt: -> #associationAt:ifAbsent: -> #associationDeclareAt:
_______________________________________________ Pharo-project mailing list Pharo-project@lists.gforge.inria.fr http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
-- Lukas Renggli http://www.lukas-renggli.ch
_______________________________________________ Pharo-project mailing list Pharo-project@lists.gforge.inria.fr http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project