| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| type(sort_key_buf), | intent(in) | :: | keys(:) |
the keys, in precedence order. |
||
| integer(kind=int64), | intent(in) | :: | n |
total rows across both ranges. |
||
| integer(kind=int64), | intent(in) | :: | na |
rows in the first range. |
||
| integer(kind=int64), | intent(inout) | :: | perm(:) |
receives |
Merges the already-ordered ranges 1..na and na+1..n into one permutation.
Ties take from the FIRST range, which is std::merge's stability guarantee and what
makes pf_merge agree with pf_sort of the concatenation element for element.