Review: Needs Fixing > > This implementation is not threadsafe. > > > > You can also use defaultdict: > > http://docs.python.org/library/collections.html#collections.defaultdict > > LRU is threadsafe >
yes, it is. But not your use of if. > I think it would be slower (prove me wrong) defaultdict slower? the logic is done in C, it will be faster (and less error prone) that your python code -- https://code.launchpad.net/~openerp-dev/openobject-server/trunk-cachecleanup/+merge/63807 Your team OpenERP R&D Team is subscribed to branch lp:~openerp-dev/openobject-server/trunk-cachecleanup. _______________________________________________ Mailing list: https://launchpad.net/~openerp-dev-gtk Post to : [email protected] Unsubscribe : https://launchpad.net/~openerp-dev-gtk More help : https://help.launchpad.net/ListHelp

