Possible behaviors of `predsort/3`
问题 This is a followup to an answer to a question about sorting on a particular argument of a term, without creating a new list for a keysort (if I understood the original question correctly). Say we wanted predsort/3 to behave exactly as sort/2 : if I understand correctly, this would mean calling it as: ?- predsort(compare, List, Sorted). Now say that we wanted to use predsort/3 to sort as implemented by msort/2 (see also this question). One way to do it would be to define a comparison predicate