You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fix: respect start/end boundaries in intro_sort heap-sort fallback
The heap_sort() call in intro_sort() ignored the start and end
parameters, causing elements outside the requested range to be
reordered when max_depth reached zero and the algorithm fell back
to heap sort.
Add optional start/end parameters to heapify() and heap_sort(), with
default values preserving existing whole-array behavior. Update the
intro_sort() call site to pass the correct range. Add a regression
doctest for the subrange heap-sort fallback case.
Fixes#15434
0 commit comments