All Downloads are FREE. Search and download functionalities are using the official Maven repository.

izumi.reflect.internal.OrderingCompat.scala Maven / Gradle / Ivy

There is a newer version: 2.3.10
Show newest version
package izumi.reflect.internal

import scala.collection.immutable.SortedSet

private[reflect] object OrderingCompat {
  inline private[reflect] def listOrdering[A](ordering: Ordering[A]): Ordering[List[A]] = {
    Ordering.Implicits.seqOrdering(ordering)
  }
  inline private[reflect] def sortedSetOrdering[A](ordering: Ordering[A]): Ordering[scala.collection.immutable.SortedSet[A]] = {
    Ordering.Implicits.sortedSetOrdering(ordering)
  }
  inline private[reflect] def setToSortedSet[A](ord: Ordering[_ >: A])(set: Set[_ <: A]): SortedSet[A] = {
    SortedSet.from[A](set)(ord.asInstanceOf[Ordering[A]])
  }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy