Message363188
Why should that be backwards incompatible? The number of times we can `__len__` on the constructor is an implementation detail. The reason is called now twice is because there is an extra check for the preallocation logic, which is detached from the logic of the subsequent list_extend(self, iterable).
On the other hand, there may be a chance for optimization here, but on a very rough first plan, that may require coupling some logic (passing down the calculated length to list_extend() or some helper, which I am not very fond of. |
|
Date |
User |
Action |
Args |
2020-03-02 15:44:00 | pablogsal | set | recipients:
+ pablogsal, brett.cannon, rhettinger, eric.snow, kimiguel |
2020-03-02 15:44:00 | pablogsal | set | messageid: <1583163840.41.0.709822381633.issue39829@roundup.psfhosted.org> |
2020-03-02 15:44:00 | pablogsal | link | issue39829 messages |
2020-03-02 15:44:00 | pablogsal | create | |
|