"use client";
import i from "./ascending.js";
function o(n = i) {
  if (n === i) return u;
  if (typeof n != "function") throw new TypeError("compare is not a function");
  return (t, e) => {
    const r = n(t, e);
    return r || r === 0 ? r : (n(e, e) === 0) - (n(t, t) === 0);
  };
}
function u(n, t) {
  return (n == null || !(n >= n)) - (t == null || !(t >= t)) || (n < t ? -1 : n > t ? 1 : 0);
}
export {
  u as ascendingDefined,
  o as compareDefined
};
