Instead of having an unintuitive but strong implicit sort order on FeeFrac (first increasing feerate, then decreasing size), and separate overloaded operator<< and operator>> that implement a weak ordering that only looks at feerate, replace these with explicit wrapper classes which make the behavior more explicit (ByRatio and ByRatioNegSize).
This allows for things like ByRatio{a} <= ByRatio{b}, instead of the earlier !(a >> b). It also supports usage inside std::min/std::max/std::less, and std::greater, so one can use:
std::max<ByRatioNegSize<FeeFrac>>(a, b)to get the highest-feerateFeeFrac, tie-breaking by smallest size.std::ranges::sort(v, std::greater<ByRatioNegSize<FeeFrac>>{});to sort a vector that way.
Suggested in #34257 (review).