summaryrefslogtreecommitdiff
path: root/lisp/emacs-lisp/generate-lisp-file.el
diff options
context:
space:
mode:
authorMattias EngdegÄrd <mattiase@acm.org>2024-03-18 19:56:20 +0100
committerMattias EngdegÄrd <mattiase@acm.org>2024-03-29 11:39:38 +0100
commita52f1121a3589af8f89828e04d66f1215c361bcf (patch)
treee0ee847774d45b3efa7376eefd775e43a30bcf0f /lisp/emacs-lisp/generate-lisp-file.el
parent1232ab31c656b8564984a758957466f90ac10501 (diff)
downloademacs-a52f1121a3589af8f89828e04d66f1215c361bcf.tar.gz
emacs-a52f1121a3589af8f89828e04d66f1215c361bcf.tar.bz2
emacs-a52f1121a3589af8f89828e04d66f1215c361bcf.zip
Add back timsort key function handling (bug#69709)
The original timsort code did provide for a key (accessor) function along with the necessary storage management, but we dropped it because our `sort` function didn't need it. Now it's been put back since it seems that it will come in handy after all. * src/fns.c (sort_list, sort_vector, Fsort): Pass Qnil as key function to tim_sort. * src/sort.c (reverse_slice, sortslice_copy) (sortslice_copy_incr, sortslice_copy_decr, sortslice_memcpy) (sortslice_memmove, sortslice_advance): New functions. (sortslice): New type. (struct stretch, struct reloc, merge_state) (binarysort, merge_init, merge_markmem, cleanup_mem) (merge_register_cleanup, merge_getmem, merge_lo, merge_hi, merge_at) (found_new_run, reverse_sortslice, resolve_fun, tim_sort): Merge back previously discarded parts from the upstreams timsort code that dealt with key functions, and adapt them to fit in.
Diffstat (limited to 'lisp/emacs-lisp/generate-lisp-file.el')
0 files changed, 0 insertions, 0 deletions