naturalOrder<T> function Null safety

Comparator<T> naturalOrder<T>()

Returns a comparator that compares Comparable objects in natural order.

Implementation

Comparator<T> naturalOrder<T>() => _naturalOrder as Comparator<T>;