[Python-Dev] Re: (Adaptive) Shivers sort variant of Tim sort

2021-08-29 Thread Laurent Lyaudet
Hello, Le sam. 28 août 2021 à 19:38, Tim Peters a écrit : > [Laurent Lyaudet ] > > ... > > My benchmarks could be improved but however I found that Shivers' sort > > and adaptive Shivers' sort (aka Jugé's sort) performs better than > > Tim's sort. > > Cool! Could you move this to the issue repor

[Python-Dev] Re: Discrepancy between what aiter() and `async for` requires on purpose?

2021-08-29 Thread Serhiy Storchaka
29.08.21 23:16, Brett Cannon пише: > If you look at > https://github.com/python/cpython/blob/b11a951f16f0603d98de24fee5c023df83ea552c/Python/ceval.c#L2409-L2451 > > you will see that `async

[Python-Dev] Discrepancy between what aiter() and `async for` requires on purpose?

2021-08-29 Thread Brett Cannon
If you look at https://github.com/python/cpython/blob/b11a951f16f0603d98de24fee5c023df83ea552c/Python/ceval.c#L2409-L2451 you will see that `async for` requires that the iterator returned from `__aiter__` define `__anext__`. But if you look at aiter() which uses PyObject_GetAiter() from https://git