diff options
author | Charles Harris <charlesr.harris@gmail.com> | 2019-02-06 19:01:59 -0700 |
---|---|---|
committer | Charles Harris <charlesr.harris@gmail.com> | 2019-02-07 14:54:27 -0700 |
commit | d3eb626ef41e1302631b5154037567b9cc02630d (patch) | |
tree | 4dd09f4f86cf1f422a45b2d7c901516a3b3dcd06 /numpy/core/numeric.py | |
parent | de1ca61e038548c73ede1e8bd11a9c7dfa02794d (diff) | |
download | numpy-d3eb626ef41e1302631b5154037567b9cc02630d.tar.gz |
BUG: Add timsort without breaking the API.
In order to maintain forward compatibility it is necessary to keep the
size of PyArray_ArrFuncs struct fixed. The usual trick of adding new
elements to the end of the structure is not available in this case
because the struct may be instanciated by user types and we have no way
to know whether the new or old struct is in play.
The solution adopted here is the reuse the (a)mergesort slots for stable
sorts of all kinds, with the actual kind set when the struct is
initialized. The '(a)mergesort' option thus becomes an alias for
'stable', but we keep it for backwards compatibility.
Diffstat (limited to 'numpy/core/numeric.py')
0 files changed, 0 insertions, 0 deletions