15 Sep
2020
15 Sep
'20
10:21 a.m.
On Tue, Sep 15, 2020 at 5:08 AM Marco Sulla
1. How can we check the size of an object only if it's an iterable using the Python C API?
There is no good way. Additionally, we need to know distinct count if we want to preallocate hash table. For example, `len(dict(["foo"]*1000))` is 1, not 1000.
2. Why, in your opinion, no relevant speedup was done?
We have "one big resize" logic in dict_merge already.
And I use dummy empty dictkeys for new empty dict.
So we don't allocate any temporary, intermediate dictkey object.
Bests,
--
Inada Naoki