maint: expand heap a bit less aggressively
commit5af1b2662b03f42abac46517a7922593eda448b5
authorPaul Eggert <eggert@cs.ucla.edu>
Thu, 7 Nov 2024 00:16:25 +0000 (6 16:16 -0800)
committerPaul Eggert <eggert@cs.ucla.edu>
Sat, 9 Nov 2024 07:41:18 +0000 (8 23:41 -0800)
treed3cc52f144c06a7495d8afd3cb303bcd0b2b1699
parentfbfda4df1a1f73b6e9e5e8bd00f2ddb06c6f219b
maint: expand heap a bit less aggressively

* gl/lib/heap.c (struct heap, heap_alloc, heap_insert)
(heapify_down, heapify_up): Prefer idx_t to size_t for sizes.
(heap_insert): Use xpalloc instead of x2nrealloc.
(heapify_down): Return void since no caller cares about value.
* gl/modules/heap: Depend on idx.
gl/lib/heap.c
gl/lib/heap.h
gl/modules/heap