base-4.20.0.0: Core data structures and operations

Data.Ord

Description

Orderings

Synopsis

# Documentation

class Eq a => Ord a where Source #

The Ord class is used for totally ordered datatypes.

Instances of Ord can be derived for any user-defined datatype whose constituent types are in Ord. The declared order of the constructors in the data declaration determines the ordering in derived Ord instances. The Ordering datatype allows a single comparison to determine the precise ordering of two objects.

Ord, as defined by the Haskell report, implements a total order and has the following properties:

Comparability
x <= y || y <= x = True
Transitivity
if x <= y && y <= z = True, then x <= z = True
Reflexivity
x <= x = True
Antisymmetry
if x <= y && y <= x = True, then x == y = True

The following operator interactions are expected to hold:

1. x >= y = y <= x
2. x < y = x <= y && x /= y
3. x > y = y < x
4. x < y = compare x y == LT
5. x > y = compare x y == GT
6. x == y = compare x y == EQ
7. min x y == if x <= y then x else y = True
8. max x y == if x >= y then x else y = True

Note that (7.) and (8.) do not require min and max to return either of their arguments. The result is merely required to equal one of the arguments in terms of (==). Users who expect a stronger guarantee are advised to write their own min and/or max functions.

The nuance of the above distinction is not always fully internalized by developers, and in the past (tracing back to the Haskell 1.4 Report) the specification for Ord asserted the stronger property that (min x y, max x y) = (x, y) or (y, x), or in other words, that min and max will return one of their arguments, using argument order as the tie-breaker if the arguments are equal by comparison. A few list and Foldable functions have behavior that is best understood with this assumption in mind: all variations of minimumBy and maximumBy (which can't use min and max in their implementations) are written such that minimumBy compare and maximumBy compare are respectively equivalent to minimum and maximum (which do use min and max) only if min and max adhere to this tie-breaking convention. Otherwise, if there are multiple least or largest elements in a container, minimum and maximum may not return the same one that minimumBy compare and maximumBy compare do (though they should return something that is equal). (This is relevant for types with non-extensional equality, like Arg, but also in cases where the precise reference held matters for memory-management reasons.) Unless there is a reason to deviate, it is less confusing for implementors of Ord to respect this same convention (as the default definitions of min and max do).

Minimal complete definition: either compare or <=. Using compare can be more efficient for complex types.

Minimal complete definition

Methods

compare :: a -> a -> Ordering Source #

(<) :: a -> a -> Bool infix 4 Source #

(<=) :: a -> a -> Bool infix 4 Source #

(>) :: a -> a -> Bool infix 4 Source #

(>=) :: a -> a -> Bool infix 4 Source #

max :: a -> a -> a Source #

min :: a -> a -> a Source #

#### Instances

Instances details
 Source # Non-lexicographic ordering. This compares the lengths of the byte arrays first and uses a lexicographic ordering if the lengths are equal. Subject to change between major versions.Since: base-4.17.0.0 Instance detailsDefined in Data.Array.Byte Methods # Instance detailsDefined in GHC.Num.BigNat Methods Source # Since: base-4.8.0.0 Instance detailsDefined in GHC.Internal.Base Methods(<) :: Void -> Void -> Bool Source #(<=) :: Void -> Void -> Bool Source #(>) :: Void -> Void -> Bool Source #(>=) :: Void -> Void -> Bool Source #max :: Void -> Void -> Void Source #min :: Void -> Void -> Void Source # Source # Since: base-4.11.0.0 Instance detailsDefined in GHC.Internal.ByteOrder Methods Source # Instance detailsDefined in GHC.Internal.ClosureTypes Methods Source # Since: base-4.3.0.0 Instance detailsDefined in GHC.Internal.Conc.Sync Methods Source # Since: base-4.2.0.0 Instance detailsDefined in GHC.Internal.Conc.Sync Methods Source # Since: base-4.3.0.0 Instance detailsDefined in GHC.Internal.Conc.Sync Methods Source # Since: base-2.1 Instance detailsDefined in GHC.Internal.Data.Semigroup.Internal Methods(<) :: All -> All -> Bool Source #(<=) :: All -> All -> Bool Source #(>) :: All -> All -> Bool Source #(>=) :: All -> All -> Bool Source #max :: All -> All -> All Source #min :: All -> All -> All Source # Source # Since: base-2.1 Instance detailsDefined in GHC.Internal.Data.Semigroup.Internal Methods(<) :: Any -> Any -> Bool Source #(<=) :: Any -> Any -> Bool Source #(>) :: Any -> Any -> Bool Source #(>=) :: Any -> Any -> Bool Source #max :: Any -> Any -> Any Source #min :: Any -> Any -> Any Source # Source # Instance detailsDefined in GHC.Internal.Data.Typeable.Internal Methods Source # Instance detailsDefined in GHC.Internal.Data.Unique Methods Source # Since: base-2.1 Instance detailsDefined in GHC.Internal.Data.Version Methods Source # Instance detailsDefined in GHC.Internal.Event.TimeOut Methods Ord Unique Source # Since: base-4.4.0.0 Instance detailsDefined in GHC.Internal.Event.Unique Methodscompare :: Unique -> Unique -> Ordering Source #(<) :: Unique -> Unique -> Bool Source #(<=) :: Unique -> Unique -> Bool Source #(>) :: Unique -> Unique -> Bool Source #(>=) :: Unique -> Unique -> Bool Source #max :: Unique -> Unique -> Unique Source #min :: Unique -> Unique -> Unique Source # Source # Since: base-4.7.0.0 Instance detailsDefined in GHC.Internal.Exception Methods Source # Since: base-3.0 Instance detailsDefined in GHC.Internal.Exception.Type Methods Source # Since: base-4.4.0.0 Instance detailsDefined in GHC.Internal.Fingerprint.Type Methods Source # Instance detailsDefined in GHC.Internal.Foreign.C.Types Methods(<) :: CBool -> CBool -> Bool Source #(>) :: CBool -> CBool -> Bool Source # Source # Instance detailsDefined in GHC.Internal.Foreign.C.Types Methods(<) :: CChar -> CChar -> Bool Source #(>) :: CChar -> CChar -> Bool Source # Source # Instance detailsDefined in GHC.Internal.Foreign.C.Types Methods Source # Instance detailsDefined in GHC.Internal.Foreign.C.Types Methods Source # Instance detailsDefined in GHC.Internal.Foreign.C.Types Methods Source # Instance detailsDefined in GHC.Internal.Foreign.C.Types Methods(<) :: CInt -> CInt -> Bool Source #(<=) :: CInt -> CInt -> Bool Source #(>) :: CInt -> CInt -> Bool Source #(>=) :: CInt -> CInt -> Bool Source #max :: CInt -> CInt -> CInt Source #min :: CInt -> CInt -> CInt Source # Source # Instance detailsDefined in GHC.Internal.Foreign.C.Types Methods Source # Instance detailsDefined in GHC.Internal.Foreign.C.Types Methods Source # Instance detailsDefined in GHC.Internal.Foreign.C.Types Methods Source # Instance detailsDefined in GHC.Internal.Foreign.C.Types Methods(<) :: CLong -> CLong -> Bool Source #(>) :: CLong -> CLong -> Bool Source # Source # Instance detailsDefined in GHC.Internal.Foreign.C.Types Methods Source # Instance detailsDefined in GHC.Internal.Foreign.C.Types Methods Source # Instance detailsDefined in GHC.Internal.Foreign.C.Types Methods Source # Instance detailsDefined in GHC.Internal.Foreign.C.Types Methods Source # Instance detailsDefined in GHC.Internal.Foreign.C.Types Methods Source # Instance detailsDefined in GHC.Internal.Foreign.C.Types Methods(<) :: CSize -> CSize -> Bool Source #(>) :: CSize -> CSize -> Bool Source # Source # Instance detailsDefined in GHC.Internal.Foreign.C.Types Methods(<) :: CTime -> CTime -> Bool Source #(>) :: CTime -> CTime -> Bool Source # Source # Instance detailsDefined in GHC.Internal.Foreign.C.Types Methods Source # Instance detailsDefined in GHC.Internal.Foreign.C.Types Methods(<) :: CUInt -> CUInt -> Bool Source #(>) :: CUInt -> CUInt -> Bool Source # Source # Instance detailsDefined in GHC.Internal.Foreign.C.Types Methods Source # Instance detailsDefined in GHC.Internal.Foreign.C.Types Methods Source # Instance detailsDefined in GHC.Internal.Foreign.C.Types Methods Source # Instance detailsDefined in GHC.Internal.Foreign.C.Types Methods Source # Instance detailsDefined in GHC.Internal.Foreign.C.Types Methods Source # Instance detailsDefined in GHC.Internal.Foreign.C.Types Methods Source # Instance detailsDefined in GHC.Internal.Foreign.C.Types Methods Source # Instance detailsDefined in GHC.Internal.Foreign.Ptr Methods Source # Instance detailsDefined in GHC.Internal.Foreign.Ptr Methods Source # Since: base-4.6.0.0 Instance detailsDefined in GHC.Internal.Generics Methods Source # Since: base-4.9.0.0 Instance detailsDefined in GHC.Internal.Generics Methods Source # Since: base-4.6.0.0 Instance detailsDefined in GHC.Internal.Generics Methods Source # Since: base-4.9.0.0 Instance detailsDefined in GHC.Internal.Generics Methods Source # Since: base-4.9.0.0 Instance detailsDefined in GHC.Internal.Generics Methods Source # Since: base-4.2.0.0 Instance detailsDefined in GHC.Internal.IO.Device Methods Source # Since: base-4.2.0.0 Instance detailsDefined in GHC.Internal.IO.Exception Methods Source # Since: base-4.2.0.0 Instance detailsDefined in GHC.Internal.IO.Exception Methods Source # Instance detailsDefined in GHC.Internal.IO.Exception Methods Source # Since: base-4.2.0.0 Instance detailsDefined in GHC.Internal.IO.Handle.Types Methods Source # Since: base-4.3.0.0 Instance detailsDefined in GHC.Internal.IO.Handle.Types Methods Source # Since: base-4.3.0.0 Instance detailsDefined in GHC.Internal.IO.Handle.Types Methods Source # Since: base-4.2.0.0 Instance detailsDefined in GHC.Internal.IO.IOMode Methods Source # Since: base-2.1 Instance detailsDefined in GHC.Internal.Int Methods(<) :: Int16 -> Int16 -> Bool Source #(>) :: Int16 -> Int16 -> Bool Source # Source # Since: base-2.1 Instance detailsDefined in GHC.Internal.Int Methods(<) :: Int32 -> Int32 -> Bool Source #(>) :: Int32 -> Int32 -> Bool Source # Source # Since: base-2.1 Instance detailsDefined in GHC.Internal.Int Methods(<) :: Int64 -> Int64 -> Bool Source #(>) :: Int64 -> Int64 -> Bool Source # Source # Since: base-2.1 Instance detailsDefined in GHC.Internal.Int Methods(<) :: Int8 -> Int8 -> Bool Source #(<=) :: Int8 -> Int8 -> Bool Source #(>) :: Int8 -> Int8 -> Bool Source #(>=) :: Int8 -> Int8 -> Bool Source #max :: Int8 -> Int8 -> Int8 Source #min :: Int8 -> Int8 -> Int8 Source # Source # Instance detailsDefined in GHC.Internal.LanguageExtensions Methods Source # Instance detailsDefined in GHC.Internal.System.Posix.Types Methods Source # Instance detailsDefined in GHC.Internal.System.Posix.Types Methods Source # Instance detailsDefined in GHC.Internal.System.Posix.Types Methods(<) :: CCc -> CCc -> Bool Source #(<=) :: CCc -> CCc -> Bool Source #(>) :: CCc -> CCc -> Bool Source #(>=) :: CCc -> CCc -> Bool Source #max :: CCc -> CCc -> CCc Source #min :: CCc -> CCc -> CCc Source # Source # Instance detailsDefined in GHC.Internal.System.Posix.Types Methods Source # Instance detailsDefined in GHC.Internal.System.Posix.Types Methods(<) :: CDev -> CDev -> Bool Source #(<=) :: CDev -> CDev -> Bool Source #(>) :: CDev -> CDev -> Bool Source #(>=) :: CDev -> CDev -> Bool Source #max :: CDev -> CDev -> CDev Source #min :: CDev -> CDev -> CDev Source # Source # Instance detailsDefined in GHC.Internal.System.Posix.Types Methods Source # Instance detailsDefined in GHC.Internal.System.Posix.Types Methods Source # Instance detailsDefined in GHC.Internal.System.Posix.Types Methods(<) :: CGid -> CGid -> Bool Source #(<=) :: CGid -> CGid -> Bool Source #(>) :: CGid -> CGid -> Bool Source #(>=) :: CGid -> CGid -> Bool Source #max :: CGid -> CGid -> CGid Source #min :: CGid -> CGid -> CGid Source # Source # Instance detailsDefined in GHC.Internal.System.Posix.Types Methods(<) :: CId -> CId -> Bool Source #(<=) :: CId -> CId -> Bool Source #(>) :: CId -> CId -> Bool Source #(>=) :: CId -> CId -> Bool Source #max :: CId -> CId -> CId Source #min :: CId -> CId -> CId Source # Source # Instance detailsDefined in GHC.Internal.System.Posix.Types Methods(<) :: CIno -> CIno -> Bool Source #(<=) :: CIno -> CIno -> Bool Source #(>) :: CIno -> CIno -> Bool Source #(>=) :: CIno -> CIno -> Bool Source #max :: CIno -> CIno -> CIno Source #min :: CIno -> CIno -> CIno Source # Source # Instance detailsDefined in GHC.Internal.System.Posix.Types Methods(<) :: CKey -> CKey -> Bool Source #(<=) :: CKey -> CKey -> Bool Source #(>) :: CKey -> CKey -> Bool Source #(>=) :: CKey -> CKey -> Bool Source #max :: CKey -> CKey -> CKey Source #min :: CKey -> CKey -> CKey Source # Source # Instance detailsDefined in GHC.Internal.System.Posix.Types Methods(<) :: CMode -> CMode -> Bool Source #(>) :: CMode -> CMode -> Bool Source # Source # Instance detailsDefined in GHC.Internal.System.Posix.Types Methods(<) :: CNfds -> CNfds -> Bool Source #(>) :: CNfds -> CNfds -> Bool Source # Source # Instance detailsDefined in GHC.Internal.System.Posix.Types Methods Source # Instance detailsDefined in GHC.Internal.System.Posix.Types Methods(<) :: COff -> COff -> Bool Source #(<=) :: COff -> COff -> Bool Source #(>) :: COff -> COff -> Bool Source #(>=) :: COff -> COff -> Bool Source #max :: COff -> COff -> COff Source #min :: COff -> COff -> COff Source # Source # Instance detailsDefined in GHC.Internal.System.Posix.Types Methods(<) :: CPid -> CPid -> Bool Source #(<=) :: CPid -> CPid -> Bool Source #(>) :: CPid -> CPid -> Bool Source #(>=) :: CPid -> CPid -> Bool Source #max :: CPid -> CPid -> CPid Source #min :: CPid -> CPid -> CPid Source # Source # Instance detailsDefined in GHC.Internal.System.Posix.Types Methods(<) :: CRLim -> CRLim -> Bool Source #(>) :: CRLim -> CRLim -> Bool Source # Source # Instance detailsDefined in GHC.Internal.System.Posix.Types Methods Source # Instance detailsDefined in GHC.Internal.System.Posix.Types Methods Source # Instance detailsDefined in GHC.Internal.System.Posix.Types Methods Source # Instance detailsDefined in GHC.Internal.System.Posix.Types Methods Source # Instance detailsDefined in GHC.Internal.System.Posix.Types Methods Source # Instance detailsDefined in GHC.Internal.System.Posix.Types Methods(<) :: CUid -> CUid -> Bool Source #(<=) :: CUid -> CUid -> Bool Source #(>) :: CUid -> CUid -> Bool Source #(>=) :: CUid -> CUid -> Bool Source #max :: CUid -> CUid -> CUid Source #min :: CUid -> CUid -> CUid Source # Source # Instance detailsDefined in GHC.Internal.System.Posix.Types Methods(<) :: Fd -> Fd -> Bool Source #(<=) :: Fd -> Fd -> Bool Source #(>) :: Fd -> Fd -> Bool Source #(>=) :: Fd -> Fd -> Bool Source #max :: Fd -> Fd -> Fd Source #min :: Fd -> Fd -> Fd Source # Source # Instance detailsDefined in GHC.Internal.TH.Syntax Methods Source # Instance detailsDefined in GHC.Internal.TH.Syntax Methods Source # Instance detailsDefined in GHC.Internal.TH.Syntax Methods(<) :: Bang -> Bang -> Bool Source #(<=) :: Bang -> Bang -> Bool Source #(>) :: Bang -> Bang -> Bool Source #(>=) :: Bang -> Bang -> Bool Source #max :: Bang -> Bang -> Bang Source #min :: Bang -> Bang -> Bang Source # Source # Instance detailsDefined in GHC.Internal.TH.Syntax Methods Source # Instance detailsDefined in GHC.Internal.TH.Syntax Methods(<) :: Body -> Body -> Bool Source #(<=) :: Body -> Body -> Bool Source #(>) :: Body -> Body -> Bool Source #(>=) :: Body -> Body -> Bool Source #max :: Body -> Body -> Body Source #min :: Body -> Body -> Body Source # Source # Instance detailsDefined in GHC.Internal.TH.Syntax Methods(<) :: Bytes -> Bytes -> Bool Source #(>) :: Bytes -> Bytes -> Bool Source # Source # Instance detailsDefined in GHC.Internal.TH.Syntax Methods Source # Instance detailsDefined in GHC.Internal.TH.Syntax Methods Source # Instance detailsDefined in GHC.Internal.TH.Syntax Methods(<) :: Con -> Con -> Bool Source #(<=) :: Con -> Con -> Bool Source #(>) :: Con -> Con -> Bool Source #(>=) :: Con -> Con -> Bool Source #max :: Con -> Con -> Con Source #min :: Con -> Con -> Con Source # Source # Instance detailsDefined in GHC.Internal.TH.Syntax Methods(<) :: Dec -> Dec -> Bool Source #(<=) :: Dec -> Dec -> Bool Source #(>) :: Dec -> Dec -> Bool Source #(>=) :: Dec -> Dec -> Bool Source #max :: Dec -> Dec -> Dec Source #min :: Dec -> Dec -> Dec Source # Source # Instance detailsDefined in GHC.Internal.TH.Syntax Methods Source # Instance detailsDefined in GHC.Internal.TH.Syntax Methods Source # Instance detailsDefined in GHC.Internal.TH.Syntax Methods Source # Instance detailsDefined in GHC.Internal.TH.Syntax Methods Source # Instance detailsDefined in GHC.Internal.TH.Syntax Methods(<) :: Exp -> Exp -> Bool Source #(<=) :: Exp -> Exp -> Bool Source #(>) :: Exp -> Exp -> Bool Source #(>=) :: Exp -> Exp -> Bool Source #max :: Exp -> Exp -> Exp Source #min :: Exp -> Exp -> Exp Source # Source # Instance detailsDefined in GHC.Internal.TH.Syntax Methods Source # Instance detailsDefined in GHC.Internal.TH.Syntax Methods Source # Instance detailsDefined in GHC.Internal.TH.Syntax Methods Source # Instance detailsDefined in GHC.Internal.TH.Syntax Methods Source # Instance detailsDefined in GHC.Internal.TH.Syntax Methods Source # Instance detailsDefined in GHC.Internal.TH.Syntax Methods(<) :: Guard -> Guard -> Bool Source #(>) :: Guard -> Guard -> Bool Source # Source # Instance detailsDefined in GHC.Internal.TH.Syntax Methods(<) :: Info -> Info -> Bool Source #(<=) :: Info -> Info -> Bool Source #(>) :: Info -> Info -> Bool Source #(>=) :: Info -> Info -> Bool Source #max :: Info -> Info -> Info Source #min :: Info -> Info -> Info Source # Source # Instance detailsDefined in GHC.Internal.TH.Syntax Methods Source # Instance detailsDefined in GHC.Internal.TH.Syntax Methods Source # Instance detailsDefined in GHC.Internal.TH.Syntax Methods(<) :: Lit -> Lit -> Bool Source #(<=) :: Lit -> Lit -> Bool Source #(>) :: Lit -> Lit -> Bool Source #(>=) :: Lit -> Lit -> Bool Source #max :: Lit -> Lit -> Lit Source #min :: Lit -> Lit -> Lit Source # Source # Instance detailsDefined in GHC.Internal.TH.Syntax Methods(<) :: Loc -> Loc -> Bool Source #(<=) :: Loc -> Loc -> Bool Source #(>) :: Loc -> Loc -> Bool Source #(>=) :: Loc -> Loc -> Bool Source #max :: Loc -> Loc -> Loc Source #min :: Loc -> Loc -> Loc Source # Source # Instance detailsDefined in GHC.Internal.TH.Syntax Methods(<) :: Match -> Match -> Bool Source #(>) :: Match -> Match -> Bool Source # Source # Instance detailsDefined in GHC.Internal.TH.Syntax Methods Source # Instance detailsDefined in GHC.Internal.TH.Syntax Methods Source # Instance detailsDefined in GHC.Internal.TH.Syntax Methods Source # Instance detailsDefined in GHC.Internal.TH.Syntax Methods(<) :: Name -> Name -> Bool Source #(<=) :: Name -> Name -> Bool Source #(>) :: Name -> Name -> Bool Source #(>=) :: Name -> Name -> Bool Source #max :: Name -> Name -> Name Source #min :: Name -> Name -> Name Source # Source # Instance detailsDefined in GHC.Internal.TH.Syntax Methods Source # Instance detailsDefined in GHC.Internal.TH.Syntax Methods Source # Instance detailsDefined in GHC.Internal.TH.Syntax Methods Source # Instance detailsDefined in GHC.Internal.TH.Syntax Methods Source # Instance detailsDefined in GHC.Internal.TH.Syntax Methods Source # Instance detailsDefined in GHC.Internal.TH.Syntax Methods(<) :: Pat -> Pat -> Bool Source #(<=) :: Pat -> Pat -> Bool Source #(>) :: Pat -> Pat -> Bool Source #(>=) :: Pat -> Pat -> Bool Source #max :: Pat -> Pat -> Pat Source #min :: Pat -> Pat -> Pat Source # Source # Instance detailsDefined in GHC.Internal.TH.Syntax Methods Source # Instance detailsDefined in GHC.Internal.TH.Syntax Methods Source # Instance detailsDefined in GHC.Internal.TH.Syntax Methods Source # Instance detailsDefined in GHC.Internal.TH.Syntax Methods Source # Instance detailsDefined in GHC.Internal.TH.Syntax Methods Source # Instance detailsDefined in GHC.Internal.TH.Syntax Methods(<) :: Range -> Range -> Bool Source #(>) :: Range -> Range -> Bool Source # Source # Instance detailsDefined in GHC.Internal.TH.Syntax Methods(<) :: Role -> Role -> Bool Source #(<=) :: Role -> Role -> Bool Source #(>) :: Role -> Role -> Bool Source #(>=) :: Role -> Role -> Bool Source #max :: Role -> Role -> Role Source #min :: Role -> Role -> Role Source # Source # Instance detailsDefined in GHC.Internal.TH.Syntax Methods Source # Instance detailsDefined in GHC.Internal.TH.Syntax Methods Source # Instance detailsDefined in GHC.Internal.TH.Syntax Methods Source # Instance detailsDefined in GHC.Internal.TH.Syntax Methods Source # Instance detailsDefined in GHC.Internal.TH.Syntax Methods Source # Instance detailsDefined in GHC.Internal.TH.Syntax Methods Source # Instance detailsDefined in GHC.Internal.TH.Syntax Methods(<) :: Stmt -> Stmt -> Bool Source #(<=) :: Stmt -> Stmt -> Bool Source #(>) :: Stmt -> Stmt -> Bool Source #(>=) :: Stmt -> Stmt -> Bool Source #max :: Stmt -> Stmt -> Stmt Source #min :: Stmt -> Stmt -> Stmt Source # Source # Instance detailsDefined in GHC.Internal.TH.Syntax Methods(<) :: TyLit -> TyLit -> Bool Source #(>) :: TyLit -> TyLit -> Bool Source # Source # Instance detailsDefined in GHC.Internal.TH.Syntax Methods Source # Instance detailsDefined in GHC.Internal.TH.Syntax Methods(<) :: Type -> Type -> Bool Source #(<=) :: Type -> Type -> Bool Source #(>) :: Type -> Type -> Bool Source #(>=) :: Type -> Type -> Bool Source #max :: Type -> Type -> Type Source #min :: Type -> Type -> Type Source # Source # Instance detailsDefined in GHC.Internal.TH.Syntax Methods Source # Instance detailsDefined in GHC.Internal.TypeLits Methods Source # Since: base-4.7.0.0 Instance detailsDefined in GHC.Internal.TypeLits Methods Source # Since: base-4.7.0.0 Instance detailsDefined in GHC.Internal.TypeNats Methods Source # Since: base-2.1 Instance detailsDefined in GHC.Internal.Unicode Methods Source # Since: base-2.1 Instance detailsDefined in GHC.Internal.Word Methods Source # Since: base-2.1 Instance detailsDefined in GHC.Internal.Word Methods Source # Since: base-2.1 Instance detailsDefined in GHC.Internal.Word Methods Source # Since: base-2.1 Instance detailsDefined in GHC.Internal.Word Methods(<) :: Word8 -> Word8 -> Bool Source #(>) :: Word8 -> Word8 -> Bool Source # Source # Instance detailsDefined in GHC.Classes Methods Source # Instance detailsDefined in GHC.Classes Methods(<) :: TyCon -> TyCon -> Bool Source #(>) :: TyCon -> TyCon -> Bool Source # # Instance detailsDefined in GHC.Num.Integer Methods # Instance detailsDefined in GHC.Num.Natural Methods Ord () Source # Instance detailsDefined in GHC.Classes Methodscompare :: () -> () -> Ordering Source #(<) :: () -> () -> Bool Source #(<=) :: () -> () -> Bool Source #(>) :: () -> () -> Bool Source #(>=) :: () -> () -> Bool Source #max :: () -> () -> () Source #min :: () -> () -> () Source # Source # Instance detailsDefined in GHC.Classes Methods(<) :: Bool -> Bool -> Bool Source #(<=) :: Bool -> Bool -> Bool Source #(>) :: Bool -> Bool -> Bool Source #(>=) :: Bool -> Bool -> Bool Source #max :: Bool -> Bool -> Bool Source #min :: Bool -> Bool -> Bool Source # Source # Instance detailsDefined in GHC.Classes Methods(<) :: Char -> Char -> Bool Source #(<=) :: Char -> Char -> Bool Source #(>) :: Char -> Char -> Bool Source #(>=) :: Char -> Char -> Bool Source #max :: Char -> Char -> Char Source #min :: Char -> Char -> Char Source # Source # IEEE 754 Double-precision type includes not only numbers, but also positive and negative infinities and a special element called NaN (which can be quiet or signal).IEEE 754-2008, section 5.11 requires that if at least one of arguments of <=, <, >, >= is NaN then the result of the comparison is False, and instance Ord Double complies with this requirement. This violates the reflexivity: both NaN <= NaN and NaN >= NaN are False.IEEE 754-2008, section 5.10 defines totalOrder predicate. Unfortunately, compare on Doubles violates the IEEE standard and does not define a total order. More specifically, both compare NaN x and compare x NaN always return GT.Thus, users must be extremely cautious when using instance Ord Double. For instance, one should avoid ordered containers with keys represented by Double, because data loss and corruption may happen. An IEEE-compliant compare is available in fp-ieee package as TotallyOrdered newtype.Moving further, the behaviour of min and max with regards to NaN is also non-compliant. IEEE 754-2008, section 5.3.1 defines that quiet NaN should be treated as a missing data by minNum and maxNum functions, for example, minNum(NaN, 1) = minNum(1, NaN) = 1. Some languages such as Java deviate from the standard implementing minNum(NaN, 1) = minNum(1, NaN) = NaN. However, min / max in base are even worse: min NaN 1 is 1, but min 1 NaN is NaN.IEEE 754-2008 compliant min / max can be found in ieee754 package under minNum / maxNum names. Implementations compliant with minimumNumber / maximumNumber from a newer IEEE 754-2019, section 9.6 are available from fp-ieee package. Instance detailsDefined in GHC.Classes Methods Source # See instance Ord Double for discussion of deviations from IEEE 754 standard. Instance detailsDefined in GHC.Classes Methods(<) :: Float -> Float -> Bool Source #(>) :: Float -> Float -> Bool Source # Source # Instance detailsDefined in GHC.Classes Methods(<) :: Int -> Int -> Bool Source #(<=) :: Int -> Int -> Bool Source #(>) :: Int -> Int -> Bool Source #(>=) :: Int -> Int -> Bool Source #max :: Int -> Int -> Int Source #min :: Int -> Int -> Int Source # Source # Instance detailsDefined in GHC.Classes Methods(<) :: Word -> Word -> Bool Source #(<=) :: Word -> Word -> Bool Source #(>) :: Word -> Word -> Bool Source #(>=) :: Word -> Word -> Bool Source #max :: Word -> Word -> Word Source #min :: Word -> Word -> Word Source # Ord a => Ord (First a) Source # Since: base-4.9.0.0 Instance detailsDefined in Data.Semigroup Methodscompare :: First a -> First a -> Ordering Source #(<) :: First a -> First a -> Bool Source #(<=) :: First a -> First a -> Bool Source #(>) :: First a -> First a -> Bool Source #(>=) :: First a -> First a -> Bool Source #max :: First a -> First a -> First a Source #min :: First a -> First a -> First a Source # Ord a => Ord (Last a) Source # Since: base-4.9.0.0 Instance detailsDefined in Data.Semigroup Methodscompare :: Last a -> Last a -> Ordering Source #(<) :: Last a -> Last a -> Bool Source #(<=) :: Last a -> Last a -> Bool Source #(>) :: Last a -> Last a -> Bool Source #(>=) :: Last a -> Last a -> Bool Source #max :: Last a -> Last a -> Last a Source #min :: Last a -> Last a -> Last a Source # Ord a => Ord (Max a) Source # Since: base-4.9.0.0 Instance detailsDefined in Data.Semigroup Methodscompare :: Max a -> Max a -> Ordering Source #(<) :: Max a -> Max a -> Bool Source #(<=) :: Max a -> Max a -> Bool Source #(>) :: Max a -> Max a -> Bool Source #(>=) :: Max a -> Max a -> Bool Source #max :: Max a -> Max a -> Max a Source #min :: Max a -> Max a -> Max a Source # Ord a => Ord (Min a) Source # Since: base-4.9.0.0 Instance detailsDefined in Data.Semigroup Methodscompare :: Min a -> Min a -> Ordering Source #(<) :: Min a -> Min a -> Bool Source #(<=) :: Min a -> Min a -> Bool Source #(>) :: Min a -> Min a -> Bool Source #(>=) :: Min a -> Min a -> Bool Source #max :: Min a -> Min a -> Min a Source #min :: Min a -> Min a -> Min a Source # Ord m => Ord (WrappedMonoid m) Source # Since: base-4.9.0.0 Instance detailsDefined in Data.Semigroup Methods(<) :: WrappedMonoid m -> WrappedMonoid m -> Bool Source #(>) :: WrappedMonoid m -> WrappedMonoid m -> Bool Source # Ord a => Ord (NonEmpty a) Source # Since: base-4.9.0.0 Instance detailsDefined in GHC.Internal.Base Methodscompare :: NonEmpty a -> NonEmpty a -> Ordering Source #(<) :: NonEmpty a -> NonEmpty a -> Bool Source #(<=) :: NonEmpty a -> NonEmpty a -> Bool Source #(>) :: NonEmpty a -> NonEmpty a -> Bool Source #(>=) :: NonEmpty a -> NonEmpty a -> Bool Source #max :: NonEmpty a -> NonEmpty a -> NonEmpty a Source #min :: NonEmpty a -> NonEmpty a -> NonEmpty a Source # Ord a => Ord (Identity a) Source # Since: base-4.8.0.0 Instance detailsDefined in GHC.Internal.Data.Functor.Identity Methodscompare :: Identity a -> Identity a -> Ordering Source #(<) :: Identity a -> Identity a -> Bool Source #(<=) :: Identity a -> Identity a -> Bool Source #(>) :: Identity a -> Identity a -> Bool Source #(>=) :: Identity a -> Identity a -> Bool Source #max :: Identity a -> Identity a -> Identity a Source #min :: Identity a -> Identity a -> Identity a Source # Ord a => Ord (First a) Source # Since: base-2.1 Instance detailsDefined in GHC.Internal.Data.Monoid Methodscompare :: First a -> First a -> Ordering Source #(<) :: First a -> First a -> Bool Source #(<=) :: First a -> First a -> Bool Source #(>) :: First a -> First a -> Bool Source #(>=) :: First a -> First a -> Bool Source #max :: First a -> First a -> First a Source #min :: First a -> First a -> First a Source # Ord a => Ord (Last a) Source # Since: base-2.1 Instance detailsDefined in GHC.Internal.Data.Monoid Methodscompare :: Last a -> Last a -> Ordering Source #(<) :: Last a -> Last a -> Bool Source #(<=) :: Last a -> Last a -> Bool Source #(>) :: Last a -> Last a -> Bool Source #(>=) :: Last a -> Last a -> Bool Source #max :: Last a -> Last a -> Last a Source #min :: Last a -> Last a -> Last a Source # Ord a => Ord (Down a) Source # Since: base-4.6.0.0 Instance detailsDefined in GHC.Internal.Data.Ord Methodscompare :: Down a -> Down a -> Ordering Source #(<) :: Down a -> Down a -> Bool Source #(<=) :: Down a -> Down a -> Bool Source #(>) :: Down a -> Down a -> Bool Source #(>=) :: Down a -> Down a -> Bool Source #max :: Down a -> Down a -> Down a Source #min :: Down a -> Down a -> Down a Source # Ord a => Ord (Dual a) Source # Since: base-2.1 Instance detailsDefined in GHC.Internal.Data.Semigroup.Internal Methodscompare :: Dual a -> Dual a -> Ordering Source #(<) :: Dual a -> Dual a -> Bool Source #(<=) :: Dual a -> Dual a -> Bool Source #(>) :: Dual a -> Dual a -> Bool Source #(>=) :: Dual a -> Dual a -> Bool Source #max :: Dual a -> Dual a -> Dual a Source #min :: Dual a -> Dual a -> Dual a Source # Ord a => Ord (Product a) Source # Since: base-2.1 Instance detailsDefined in GHC.Internal.Data.Semigroup.Internal Methodscompare :: Product a -> Product a -> Ordering Source #(<) :: Product a -> Product a -> Bool Source #(<=) :: Product a -> Product a -> Bool Source #(>) :: Product a -> Product a -> Bool Source #(>=) :: Product a -> Product a -> Bool Source #max :: Product a -> Product a -> Product a Source #min :: Product a -> Product a -> Product a Source # Ord a => Ord (Sum a) Source # Since: base-2.1 Instance detailsDefined in GHC.Internal.Data.Semigroup.Internal Methodscompare :: Sum a -> Sum a -> Ordering Source #(<) :: Sum a -> Sum a -> Bool Source #(<=) :: Sum a -> Sum a -> Bool Source #(>) :: Sum a -> Sum a -> Bool Source #(>=) :: Sum a -> Sum a -> Bool Source #max :: Sum a -> Sum a -> Sum a Source #min :: Sum a -> Sum a -> Sum a Source # Ord (ConstPtr a) Source # Instance detailsDefined in GHC.Internal.Foreign.C.ConstPtr Methodscompare :: ConstPtr a -> ConstPtr a -> Ordering Source #(<) :: ConstPtr a -> ConstPtr a -> Bool Source #(<=) :: ConstPtr a -> ConstPtr a -> Bool Source #(>) :: ConstPtr a -> ConstPtr a -> Bool Source #(>=) :: ConstPtr a -> ConstPtr a -> Bool Source #max :: ConstPtr a -> ConstPtr a -> ConstPtr a Source #min :: ConstPtr a -> ConstPtr a -> ConstPtr a Source # Source # Since: base-2.1 Instance detailsDefined in GHC.Internal.ForeignPtr Methods(<) :: ForeignPtr a -> ForeignPtr a -> Bool Source #(<=) :: ForeignPtr a -> ForeignPtr a -> Bool Source #(>) :: ForeignPtr a -> ForeignPtr a -> Bool Source #(>=) :: ForeignPtr a -> ForeignPtr a -> Bool Source #max :: ForeignPtr a -> ForeignPtr a -> ForeignPtr a Source #min :: ForeignPtr a -> ForeignPtr a -> ForeignPtr a Source # Ord a => Ord (ZipList a) Source # Since: base-4.7.0.0 Instance detailsDefined in GHC.Internal.Functor.ZipList Methodscompare :: ZipList a -> ZipList a -> Ordering Source #(<) :: ZipList a -> ZipList a -> Bool Source #(<=) :: ZipList a -> ZipList a -> Bool Source #(>) :: ZipList a -> ZipList a -> Bool Source #(>=) :: ZipList a -> ZipList a -> Bool Source #max :: ZipList a -> ZipList a -> ZipList a Source #min :: ZipList a -> ZipList a -> ZipList a Source # Ord p => Ord (Par1 p) Source # Since: base-4.7.0.0 Instance detailsDefined in GHC.Internal.Generics Methodscompare :: Par1 p -> Par1 p -> Ordering Source #(<) :: Par1 p -> Par1 p -> Bool Source #(<=) :: Par1 p -> Par1 p -> Bool Source #(>) :: Par1 p -> Par1 p -> Bool Source #(>=) :: Par1 p -> Par1 p -> Bool Source #max :: Par1 p -> Par1 p -> Par1 p Source #min :: Par1 p -> Par1 p -> Par1 p Source # Ord (FunPtr a) Source # Instance detailsDefined in GHC.Internal.Ptr Methodscompare :: FunPtr a -> FunPtr a -> Ordering Source #(<) :: FunPtr a -> FunPtr a -> Bool Source #(<=) :: FunPtr a -> FunPtr a -> Bool Source #(>) :: FunPtr a -> FunPtr a -> Bool Source #(>=) :: FunPtr a -> FunPtr a -> Bool Source #max :: FunPtr a -> FunPtr a -> FunPtr a Source #min :: FunPtr a -> FunPtr a -> FunPtr a Source # Ord (Ptr a) Source # Since: base-2.1 Instance detailsDefined in GHC.Internal.Ptr Methodscompare :: Ptr a -> Ptr a -> Ordering Source #(<) :: Ptr a -> Ptr a -> Bool Source #(<=) :: Ptr a -> Ptr a -> Bool Source #(>) :: Ptr a -> Ptr a -> Bool Source #(>=) :: Ptr a -> Ptr a -> Bool Source #max :: Ptr a -> Ptr a -> Ptr a Source #min :: Ptr a -> Ptr a -> Ptr a Source # Integral a => Ord (Ratio a) Source # Since: base-2.0.1 Instance detailsDefined in GHC.Internal.Real Methodscompare :: Ratio a -> Ratio a -> Ordering Source #(<) :: Ratio a -> Ratio a -> Bool Source #(<=) :: Ratio a -> Ratio a -> Bool Source #(>) :: Ratio a -> Ratio a -> Bool Source #(>=) :: Ratio a -> Ratio a -> Bool Source #max :: Ratio a -> Ratio a -> Ratio a Source #min :: Ratio a -> Ratio a -> Ratio a Source # Ord flag => Ord (TyVarBndr flag) Source # Instance detailsDefined in GHC.Internal.TH.Syntax Methodscompare :: TyVarBndr flag -> TyVarBndr flag -> Ordering Source #(<) :: TyVarBndr flag -> TyVarBndr flag -> Bool Source #(<=) :: TyVarBndr flag -> TyVarBndr flag -> Bool Source #(>) :: TyVarBndr flag -> TyVarBndr flag -> Bool Source #(>=) :: TyVarBndr flag -> TyVarBndr flag -> Bool Source #max :: TyVarBndr flag -> TyVarBndr flag -> TyVarBndr flag Source #min :: TyVarBndr flag -> TyVarBndr flag -> TyVarBndr flag Source # Ord (SChar c) Source # Since: base-4.19.0.0 Instance detailsDefined in GHC.Internal.TypeLits Methodscompare :: SChar c -> SChar c -> Ordering Source #(<) :: SChar c -> SChar c -> Bool Source #(<=) :: SChar c -> SChar c -> Bool Source #(>) :: SChar c -> SChar c -> Bool Source #(>=) :: SChar c -> SChar c -> Bool Source #max :: SChar c -> SChar c -> SChar c Source #min :: SChar c -> SChar c -> SChar c Source # Ord (SSymbol s) Source # Since: base-4.19.0.0 Instance detailsDefined in GHC.Internal.TypeLits Methodscompare :: SSymbol s -> SSymbol s -> Ordering Source #(<) :: SSymbol s -> SSymbol s -> Bool Source #(<=) :: SSymbol s -> SSymbol s -> Bool Source #(>) :: SSymbol s -> SSymbol s -> Bool Source #(>=) :: SSymbol s -> SSymbol s -> Bool Source #max :: SSymbol s -> SSymbol s -> SSymbol s Source #min :: SSymbol s -> SSymbol s -> SSymbol s Source # Ord (SNat n) Source # Since: base-4.19.0.0 Instance detailsDefined in GHC.Internal.TypeNats Methodscompare :: SNat n -> SNat n -> Ordering Source #(<) :: SNat n -> SNat n -> Bool Source #(<=) :: SNat n -> SNat n -> Bool Source #(>) :: SNat n -> SNat n -> Bool Source #(>=) :: SNat n -> SNat n -> Bool Source #max :: SNat n -> SNat n -> SNat n Source #min :: SNat n -> SNat n -> SNat n Source # Ord a => Ord (Maybe a) Source # Since: base-2.1 Instance detailsDefined in GHC.Internal.Maybe Methodscompare :: Maybe a -> Maybe a -> Ordering Source #(<) :: Maybe a -> Maybe a -> Bool Source #(<=) :: Maybe a -> Maybe a -> Bool Source #(>) :: Maybe a -> Maybe a -> Bool Source #(>=) :: Maybe a -> Maybe a -> Bool Source #max :: Maybe a -> Maybe a -> Maybe a Source #min :: Maybe a -> Maybe a -> Maybe a Source # Ord a => Ord (Solo a) Source # Instance detailsDefined in GHC.Classes Methodscompare :: Solo a -> Solo a -> Ordering Source #(<) :: Solo a -> Solo a -> Bool Source #(<=) :: Solo a -> Solo a -> Bool Source #(>) :: Solo a -> Solo a -> Bool Source #(>=) :: Solo a -> Solo a -> Bool Source #max :: Solo a -> Solo a -> Solo a Source #min :: Solo a -> Solo a -> Solo a Source # Ord a => Ord [a] Source # Instance detailsDefined in GHC.Classes Methodscompare :: [a] -> [a] -> Ordering Source #(<) :: [a] -> [a] -> Bool Source #(<=) :: [a] -> [a] -> Bool Source #(>) :: [a] -> [a] -> Bool Source #(>=) :: [a] -> [a] -> Bool Source #max :: [a] -> [a] -> [a] Source #min :: [a] -> [a] -> [a] Source # Ord (Fixed a) Source # Since: base-2.1 Instance detailsDefined in Data.Fixed Methodscompare :: Fixed a -> Fixed a -> Ordering Source #(<) :: Fixed a -> Fixed a -> Bool Source #(<=) :: Fixed a -> Fixed a -> Bool Source #(>) :: Fixed a -> Fixed a -> Bool Source #(>=) :: Fixed a -> Fixed a -> Bool Source #max :: Fixed a -> Fixed a -> Fixed a Source #min :: Fixed a -> Fixed a -> Fixed a Source # Ord a => Ord (Arg a b) Source # Note that Arg's Ord instance has min and max implementations that differ from the tie-breaking conventions of the default implementation of min and max in class Ord; Arg breaks ties by favoring the first argument in both functions.Since: base-4.9.0.0 Instance detailsDefined in Data.Semigroup Methodscompare :: Arg a b -> Arg a b -> Ordering Source #(<) :: Arg a b -> Arg a b -> Bool Source #(<=) :: Arg a b -> Arg a b -> Bool Source #(>) :: Arg a b -> Arg a b -> Bool Source #(>=) :: Arg a b -> Arg a b -> Bool Source #max :: Arg a b -> Arg a b -> Arg a b Source #min :: Arg a b -> Arg a b -> Arg a b Source # (Ix i, Ord e) => Ord (Array i e) Source # Since: base-2.1 Instance detailsDefined in GHC.Internal.Arr Methodscompare :: Array i e -> Array i e -> Ordering Source #(<) :: Array i e -> Array i e -> Bool Source #(<=) :: Array i e -> Array i e -> Bool Source #(>) :: Array i e -> Array i e -> Bool Source #(>=) :: Array i e -> Array i e -> Bool Source #max :: Array i e -> Array i e -> Array i e Source #min :: Array i e -> Array i e -> Array i e Source # (Ord a, Ord b) => Ord (Either a b) Source # Since: base-2.1 Instance detailsDefined in GHC.Internal.Data.Either Methodscompare :: Either a b -> Either a b -> Ordering Source #(<) :: Either a b -> Either a b -> Bool Source #(<=) :: Either a b -> Either a b -> Bool Source #(>) :: Either a b -> Either a b -> Bool Source #(>=) :: Either a b -> Either a b -> Bool Source #max :: Either a b -> Either a b -> Either a b Source #min :: Either a b -> Either a b -> Either a b Source # Ord (Proxy s) Source # Since: base-4.7.0.0 Instance detailsDefined in GHC.Internal.Data.Proxy Methodscompare :: Proxy s -> Proxy s -> Ordering Source #(<) :: Proxy s -> Proxy s -> Bool Source #(<=) :: Proxy s -> Proxy s -> Bool Source #(>) :: Proxy s -> Proxy s -> Bool Source #(>=) :: Proxy s -> Proxy s -> Bool Source #max :: Proxy s -> Proxy s -> Proxy s Source #min :: Proxy s -> Proxy s -> Proxy s Source # Ord (TypeRep a) Source # Since: base-4.4.0.0 Instance detailsDefined in GHC.Internal.Data.Typeable.Internal Methodscompare :: TypeRep a -> TypeRep a -> Ordering Source #(<) :: TypeRep a -> TypeRep a -> Bool Source #(<=) :: TypeRep a -> TypeRep a -> Bool Source #(>) :: TypeRep a -> TypeRep a -> Bool Source #(>=) :: TypeRep a -> TypeRep a -> Bool Source #max :: TypeRep a -> TypeRep a -> TypeRep a Source #min :: TypeRep a -> TypeRep a -> TypeRep a Source # Ord (U1 p) Source # Since: base-4.7.0.0 Instance detailsDefined in GHC.Internal.Generics Methodscompare :: U1 p -> U1 p -> Ordering Source #(<) :: U1 p -> U1 p -> Bool Source #(<=) :: U1 p -> U1 p -> Bool Source #(>) :: U1 p -> U1 p -> Bool Source #(>=) :: U1 p -> U1 p -> Bool Source #max :: U1 p -> U1 p -> U1 p Source #min :: U1 p -> U1 p -> U1 p Source # Ord (V1 p) Source # Since: base-4.9.0.0 Instance detailsDefined in GHC.Internal.Generics Methodscompare :: V1 p -> V1 p -> Ordering Source #(<) :: V1 p -> V1 p -> Bool Source #(<=) :: V1 p -> V1 p -> Bool Source #(>) :: V1 p -> V1 p -> Bool Source #(>=) :: V1 p -> V1 p -> Bool Source #max :: V1 p -> V1 p -> V1 p Source #min :: V1 p -> V1 p -> V1 p Source # (Ord a, Ord b) => Ord (a, b) Source # Instance detailsDefined in GHC.Classes Methodscompare :: (a, b) -> (a, b) -> Ordering Source #(<) :: (a, b) -> (a, b) -> Bool Source #(<=) :: (a, b) -> (a, b) -> Bool Source #(>) :: (a, b) -> (a, b) -> Bool Source #(>=) :: (a, b) -> (a, b) -> Bool Source #max :: (a, b) -> (a, b) -> (a, b) Source #min :: (a, b) -> (a, b) -> (a, b) Source # Ord a => Ord (Const a b) Source # Since: base-4.9.0.0 Instance detailsDefined in GHC.Internal.Data.Functor.Const Methodscompare :: Const a b -> Const a b -> Ordering Source #(<) :: Const a b -> Const a b -> Bool Source #(<=) :: Const a b -> Const a b -> Bool Source #(>) :: Const a b -> Const a b -> Bool Source #(>=) :: Const a b -> Const a b -> Bool Source #max :: Const a b -> Const a b -> Const a b Source #min :: Const a b -> Const a b -> Const a b Source # Ord (f a) => Ord (Ap f a) Source # Since: base-4.12.0.0 Instance detailsDefined in GHC.Internal.Data.Monoid Methodscompare :: Ap f a -> Ap f a -> Ordering Source #(<) :: Ap f a -> Ap f a -> Bool Source #(<=) :: Ap f a -> Ap f a -> Bool Source #(>) :: Ap f a -> Ap f a -> Bool Source #(>=) :: Ap f a -> Ap f a -> Bool Source #max :: Ap f a -> Ap f a -> Ap f a Source #min :: Ap f a -> Ap f a -> Ap f a Source # Ord (f a) => Ord (Alt f a) Source # Since: base-4.8.0.0 Instance detailsDefined in GHC.Internal.Data.Semigroup.Internal Methodscompare :: Alt f a -> Alt f a -> Ordering Source #(<) :: Alt f a -> Alt f a -> Bool Source #(<=) :: Alt f a -> Alt f a -> Bool Source #(>) :: Alt f a -> Alt f a -> Bool Source #(>=) :: Alt f a -> Alt f a -> Bool Source #max :: Alt f a -> Alt f a -> Alt f a Source #min :: Alt f a -> Alt f a -> Alt f a Source # Ord (Coercion a b) Source # Since: base-4.7.0.0 Instance detailsDefined in GHC.Internal.Data.Type.Coercion Methodscompare :: Coercion a b -> Coercion a b -> Ordering Source #(<) :: Coercion a b -> Coercion a b -> Bool Source #(<=) :: Coercion a b -> Coercion a b -> Bool Source #(>) :: Coercion a b -> Coercion a b -> Bool Source #(>=) :: Coercion a b -> Coercion a b -> Bool Source #max :: Coercion a b -> Coercion a b -> Coercion a b Source #min :: Coercion a b -> Coercion a b -> Coercion a b Source # Ord (a :~: b) Source # Since: base-4.7.0.0 Instance detailsDefined in GHC.Internal.Data.Type.Equality Methodscompare :: (a :~: b) -> (a :~: b) -> Ordering Source #(<) :: (a :~: b) -> (a :~: b) -> Bool Source #(<=) :: (a :~: b) -> (a :~: b) -> Bool Source #(>) :: (a :~: b) -> (a :~: b) -> Bool Source #(>=) :: (a :~: b) -> (a :~: b) -> Bool Source #max :: (a :~: b) -> (a :~: b) -> a :~: b Source #min :: (a :~: b) -> (a :~: b) -> a :~: b Source # (Generic1 f, Ord (Rep1 f a)) => Ord (Generically1 f a) Source # Since: base-4.18.0.0 Instance detailsDefined in GHC.Internal.Generics Methodscompare :: Generically1 f a -> Generically1 f a -> Ordering Source #(<) :: Generically1 f a -> Generically1 f a -> Bool Source #(<=) :: Generically1 f a -> Generically1 f a -> Bool Source #(>) :: Generically1 f a -> Generically1 f a -> Bool Source #(>=) :: Generically1 f a -> Generically1 f a -> Bool Source #max :: Generically1 f a -> Generically1 f a -> Generically1 f a Source #min :: Generically1 f a -> Generically1 f a -> Generically1 f a Source # Ord (f p) => Ord (Rec1 f p) Source # Since: base-4.7.0.0 Instance detailsDefined in GHC.Internal.Generics Methodscompare :: Rec1 f p -> Rec1 f p -> Ordering Source #(<) :: Rec1 f p -> Rec1 f p -> Bool Source #(<=) :: Rec1 f p -> Rec1 f p -> Bool Source #(>) :: Rec1 f p -> Rec1 f p -> Bool Source #(>=) :: Rec1 f p -> Rec1 f p -> Bool Source #max :: Rec1 f p -> Rec1 f p -> Rec1 f p Source #min :: Rec1 f p -> Rec1 f p -> Rec1 f p Source # Ord (URec (Ptr ()) p) Source # Since: base-4.9.0.0 Instance detailsDefined in GHC.Internal.Generics Methodscompare :: URec (Ptr ()) p -> URec (Ptr ()) p -> Ordering Source #(<) :: URec (Ptr ()) p -> URec (Ptr ()) p -> Bool Source #(<=) :: URec (Ptr ()) p -> URec (Ptr ()) p -> Bool Source #(>) :: URec (Ptr ()) p -> URec (Ptr ()) p -> Bool Source #(>=) :: URec (Ptr ()) p -> URec (Ptr ()) p -> Bool Source #max :: URec (Ptr ()) p -> URec (Ptr ()) p -> URec (Ptr ()) p Source #min :: URec (Ptr ()) p -> URec (Ptr ()) p -> URec (Ptr ()) p Source # Ord (URec Char p) Source # Since: base-4.9.0.0 Instance detailsDefined in GHC.Internal.Generics Methodscompare :: URec Char p -> URec Char p -> Ordering Source #(<) :: URec Char p -> URec Char p -> Bool Source #(<=) :: URec Char p -> URec Char p -> Bool Source #(>) :: URec Char p -> URec Char p -> Bool Source #(>=) :: URec Char p -> URec Char p -> Bool Source #max :: URec Char p -> URec Char p -> URec Char p Source #min :: URec Char p -> URec Char p -> URec Char p Source # Source # Since: base-4.9.0.0 Instance detailsDefined in GHC.Internal.Generics Methods(<) :: URec Double p -> URec Double p -> Bool Source #(<=) :: URec Double p -> URec Double p -> Bool Source #(>) :: URec Double p -> URec Double p -> Bool Source #(>=) :: URec Double p -> URec Double p -> Bool Source #max :: URec Double p -> URec Double p -> URec Double p Source #min :: URec Double p -> URec Double p -> URec Double p Source # Ord (URec Float p) Source # Instance detailsDefined in GHC.Internal.Generics Methodscompare :: URec Float p -> URec Float p -> Ordering Source #(<) :: URec Float p -> URec Float p -> Bool Source #(<=) :: URec Float p -> URec Float p -> Bool Source #(>) :: URec Float p -> URec Float p -> Bool Source #(>=) :: URec Float p -> URec Float p -> Bool Source #max :: URec Float p -> URec Float p -> URec Float p Source #min :: URec Float p -> URec Float p -> URec Float p Source # Ord (URec Int p) Source # Since: base-4.9.0.0 Instance detailsDefined in GHC.Internal.Generics Methodscompare :: URec Int p -> URec Int p -> Ordering Source #(<) :: URec Int p -> URec Int p -> Bool Source #(<=) :: URec Int p -> URec Int p -> Bool Source #(>) :: URec Int p -> URec Int p -> Bool Source #(>=) :: URec Int p -> URec Int p -> Bool Source #max :: URec Int p -> URec Int p -> URec Int p Source #min :: URec Int p -> URec Int p -> URec Int p Source # Ord (URec Word p) Source # Since: base-4.9.0.0 Instance detailsDefined in GHC.Internal.Generics Methodscompare :: URec Word p -> URec Word p -> Ordering Source #(<) :: URec Word p -> URec Word p -> Bool Source #(<=) :: URec Word p -> URec Word p -> Bool Source #(>) :: URec Word p -> URec Word p -> Bool Source #(>=) :: URec Word p -> URec Word p -> Bool Source #max :: URec Word p -> URec Word p -> URec Word p Source #min :: URec Word p -> URec Word p -> URec Word p Source # (Ord a, Ord b, Ord c) => Ord (a, b, c) Source # Instance detailsDefined in GHC.Classes Methodscompare :: (a, b, c) -> (a, b, c) -> Ordering Source #(<) :: (a, b, c) -> (a, b, c) -> Bool Source #(<=) :: (a, b, c) -> (a, b, c) -> Bool Source #(>) :: (a, b, c) -> (a, b, c) -> Bool Source #(>=) :: (a, b, c) -> (a, b, c) -> Bool Source #max :: (a, b, c) -> (a, b, c) -> (a, b, c) Source #min :: (a, b, c) -> (a, b, c) -> (a, b, c) Source # (Ord (f a), Ord (g a)) => Ord (Product f g a) Source # Since: base-4.18.0.0 Instance detailsDefined in Data.Functor.Product Methodscompare :: Product f g a -> Product f g a -> Ordering Source #(<) :: Product f g a -> Product f g a -> Bool Source #(<=) :: Product f g a -> Product f g a -> Bool Source #(>) :: Product f g a -> Product f g a -> Bool Source #(>=) :: Product f g a -> Product f g a -> Bool Source #max :: Product f g a -> Product f g a -> Product f g a Source #min :: Product f g a -> Product f g a -> Product f g a Source # (Ord (f a), Ord (g a)) => Ord (Sum f g a) Source # Since: base-4.18.0.0 Instance detailsDefined in Data.Functor.Sum Methodscompare :: Sum f g a -> Sum f g a -> Ordering Source #(<) :: Sum f g a -> Sum f g a -> Bool Source #(<=) :: Sum f g a -> Sum f g a -> Bool Source #(>) :: Sum f g a -> Sum f g a -> Bool Source #(>=) :: Sum f g a -> Sum f g a -> Bool Source #max :: Sum f g a -> Sum f g a -> Sum f g a Source #min :: Sum f g a -> Sum f g a -> Sum f g a Source # Ord (a :~~: b) Source # Since: base-4.10.0.0 Instance detailsDefined in GHC.Internal.Data.Type.Equality Methodscompare :: (a :~~: b) -> (a :~~: b) -> Ordering Source #(<) :: (a :~~: b) -> (a :~~: b) -> Bool Source #(<=) :: (a :~~: b) -> (a :~~: b) -> Bool Source #(>) :: (a :~~: b) -> (a :~~: b) -> Bool Source #(>=) :: (a :~~: b) -> (a :~~: b) -> Bool Source #max :: (a :~~: b) -> (a :~~: b) -> a :~~: b Source #min :: (a :~~: b) -> (a :~~: b) -> a :~~: b Source # (Ord (f p), Ord (g p)) => Ord ((f :*: g) p) Source # Since: base-4.7.0.0 Instance detailsDefined in GHC.Internal.Generics Methodscompare :: (f :*: g) p -> (f :*: g) p -> Ordering Source #(<) :: (f :*: g) p -> (f :*: g) p -> Bool Source #(<=) :: (f :*: g) p -> (f :*: g) p -> Bool Source #(>) :: (f :*: g) p -> (f :*: g) p -> Bool Source #(>=) :: (f :*: g) p -> (f :*: g) p -> Bool Source #max :: (f :*: g) p -> (f :*: g) p -> (f :*: g) p Source #min :: (f :*: g) p -> (f :*: g) p -> (f :*: g) p Source # (Ord (f p), Ord (g p)) => Ord ((f :+: g) p) Source # Since: base-4.7.0.0 Instance detailsDefined in GHC.Internal.Generics Methodscompare :: (f :+: g) p -> (f :+: g) p -> Ordering Source #(<) :: (f :+: g) p -> (f :+: g) p -> Bool Source #(<=) :: (f :+: g) p -> (f :+: g) p -> Bool Source #(>) :: (f :+: g) p -> (f :+: g) p -> Bool Source #(>=) :: (f :+: g) p -> (f :+: g) p -> Bool Source #max :: (f :+: g) p -> (f :+: g) p -> (f :+: g) p Source #min :: (f :+: g) p -> (f :+: g) p -> (f :+: g) p Source # Ord c => Ord (K1 i c p) Source # Since: base-4.7.0.0 Instance detailsDefined in GHC.Internal.Generics Methodscompare :: K1 i c p -> K1 i c p -> Ordering Source #(<) :: K1 i c p -> K1 i c p -> Bool Source #(<=) :: K1 i c p -> K1 i c p -> Bool Source #(>) :: K1 i c p -> K1 i c p -> Bool Source #(>=) :: K1 i c p -> K1 i c p -> Bool Source #max :: K1 i c p -> K1 i c p -> K1 i c p Source #min :: K1 i c p -> K1 i c p -> K1 i c p Source # (Ord a, Ord b, Ord c, Ord d) => Ord (a, b, c, d) Source # Instance detailsDefined in GHC.Classes Methodscompare :: (a, b, c, d) -> (a, b, c, d) -> Ordering Source #(<) :: (a, b, c, d) -> (a, b, c, d) -> Bool Source #(<=) :: (a, b, c, d) -> (a, b, c, d) -> Bool Source #(>) :: (a, b, c, d) -> (a, b, c, d) -> Bool Source #(>=) :: (a, b, c, d) -> (a, b, c, d) -> Bool Source #max :: (a, b, c, d) -> (a, b, c, d) -> (a, b, c, d) Source #min :: (a, b, c, d) -> (a, b, c, d) -> (a, b, c, d) Source # Ord (f (g a)) => Ord (Compose f g a) Source # Since: base-4.18.0.0 Instance detailsDefined in Data.Functor.Compose Methodscompare :: Compose f g a -> Compose f g a -> Ordering Source #(<) :: Compose f g a -> Compose f g a -> Bool Source #(<=) :: Compose f g a -> Compose f g a -> Bool Source #(>) :: Compose f g a -> Compose f g a -> Bool Source #(>=) :: Compose f g a -> Compose f g a -> Bool Source #max :: Compose f g a -> Compose f g a -> Compose f g a Source #min :: Compose f g a -> Compose f g a -> Compose f g a Source # Ord (f (g p)) => Ord ((f :.: g) p) Source # Since: base-4.7.0.0 Instance detailsDefined in GHC.Internal.Generics Methodscompare :: (f :.: g) p -> (f :.: g) p -> Ordering Source #(<) :: (f :.: g) p -> (f :.: g) p -> Bool Source #(<=) :: (f :.: g) p -> (f :.: g) p -> Bool Source #(>) :: (f :.: g) p -> (f :.: g) p -> Bool Source #(>=) :: (f :.: g) p -> (f :.: g) p -> Bool Source #max :: (f :.: g) p -> (f :.: g) p -> (f :.: g) p Source #min :: (f :.: g) p -> (f :.: g) p -> (f :.: g) p Source # Ord (f p) => Ord (M1 i c f p) Source # Since: base-4.7.0.0 Instance detailsDefined in GHC.Internal.Generics Methodscompare :: M1 i c f p -> M1 i c f p -> Ordering Source #(<) :: M1 i c f p -> M1 i c f p -> Bool Source #(<=) :: M1 i c f p -> M1 i c f p -> Bool Source #(>) :: M1 i c f p -> M1 i c f p -> Bool Source #(>=) :: M1 i c f p -> M1 i c f p -> Bool Source #max :: M1 i c f p -> M1 i c f p -> M1 i c f p Source #min :: M1 i c f p -> M1 i c f p -> M1 i c f p Source # (Ord a, Ord b, Ord c, Ord d, Ord e) => Ord (a, b, c, d, e) Source # Instance detailsDefined in GHC.Classes Methodscompare :: (a, b, c, d, e) -> (a, b, c, d, e) -> Ordering Source #(<) :: (a, b, c, d, e) -> (a, b, c, d, e) -> Bool Source #(<=) :: (a, b, c, d, e) -> (a, b, c, d, e) -> Bool Source #(>) :: (a, b, c, d, e) -> (a, b, c, d, e) -> Bool Source #(>=) :: (a, b, c, d, e) -> (a, b, c, d, e) -> Bool Source #max :: (a, b, c, d, e) -> (a, b, c, d, e) -> (a, b, c, d, e) Source #min :: (a, b, c, d, e) -> (a, b, c, d, e) -> (a, b, c, d, e) Source # (Ord a, Ord b, Ord c, Ord d, Ord e, Ord f) => Ord (a, b, c, d, e, f) Source # Instance detailsDefined in GHC.Classes Methodscompare :: (a, b, c, d, e, f) -> (a, b, c, d, e, f) -> Ordering Source #(<) :: (a, b, c, d, e, f) -> (a, b, c, d, e, f) -> Bool Source #(<=) :: (a, b, c, d, e, f) -> (a, b, c, d, e, f) -> Bool Source #(>) :: (a, b, c, d, e, f) -> (a, b, c, d, e, f) -> Bool Source #(>=) :: (a, b, c, d, e, f) -> (a, b, c, d, e, f) -> Bool Source #max :: (a, b, c, d, e, f) -> (a, b, c, d, e, f) -> (a, b, c, d, e, f) Source #min :: (a, b, c, d, e, f) -> (a, b, c, d, e, f) -> (a, b, c, d, e, f) Source # (Ord a, Ord b, Ord c, Ord d, Ord e, Ord f, Ord g) => Ord (a, b, c, d, e, f, g) Source # Instance detailsDefined in GHC.Classes Methodscompare :: (a, b, c, d, e, f, g) -> (a, b, c, d, e, f, g) -> Ordering Source #(<) :: (a, b, c, d, e, f, g) -> (a, b, c, d, e, f, g) -> Bool Source #(<=) :: (a, b, c, d, e, f, g) -> (a, b, c, d, e, f, g) -> Bool Source #(>) :: (a, b, c, d, e, f, g) -> (a, b, c, d, e, f, g) -> Bool Source #(>=) :: (a, b, c, d, e, f, g) -> (a, b, c, d, e, f, g) -> Bool Source #max :: (a, b, c, d, e, f, g) -> (a, b, c, d, e, f, g) -> (a, b, c, d, e, f, g) Source #min :: (a, b, c, d, e, f, g) -> (a, b, c, d, e, f, g) -> (a, b, c, d, e, f, g) Source # (Ord a, Ord b, Ord c, Ord d, Ord e, Ord f, Ord g, Ord h) => Ord (a, b, c, d, e, f, g, h) Source # Instance detailsDefined in GHC.Classes Methodscompare :: (a, b, c, d, e, f, g, h) -> (a, b, c, d, e, f, g, h) -> Ordering Source #(<) :: (a, b, c, d, e, f, g, h) -> (a, b, c, d, e, f, g, h) -> Bool Source #(<=) :: (a, b, c, d, e, f, g, h) -> (a, b, c, d, e, f, g, h) -> Bool Source #(>) :: (a, b, c, d, e, f, g, h) -> (a, b, c, d, e, f, g, h) -> Bool Source #(>=) :: (a, b, c, d, e, f, g, h) -> (a, b, c, d, e, f, g, h) -> Bool Source #max :: (a, b, c, d, e, f, g, h) -> (a, b, c, d, e, f, g, h) -> (a, b, c, d, e, f, g, h) Source #min :: (a, b, c, d, e, f, g, h) -> (a, b, c, d, e, f, g, h) -> (a, b, c, d, e, f, g, h) Source # (Ord a, Ord b, Ord c, Ord d, Ord e, Ord f, Ord g, Ord h, Ord i) => Ord (a, b, c, d, e, f, g, h, i) Source # Instance detailsDefined in GHC.Classes Methodscompare :: (a, b, c, d, e, f, g, h, i) -> (a, b, c, d, e, f, g, h, i) -> Ordering Source #(<) :: (a, b, c, d, e, f, g, h, i) -> (a, b, c, d, e, f, g, h, i) -> Bool Source #(<=) :: (a, b, c, d, e, f, g, h, i) -> (a, b, c, d, e, f, g, h, i) -> Bool Source #(>) :: (a, b, c, d, e, f, g, h, i) -> (a, b, c, d, e, f, g, h, i) -> Bool Source #(>=) :: (a, b, c, d, e, f, g, h, i) -> (a, b, c, d, e, f, g, h, i) -> Bool Source #max :: (a, b, c, d, e, f, g, h, i) -> (a, b, c, d, e, f, g, h, i) -> (a, b, c, d, e, f, g, h, i) Source #min :: (a, b, c, d, e, f, g, h, i) -> (a, b, c, d, e, f, g, h, i) -> (a, b, c, d, e, f, g, h, i) Source # (Ord a, Ord b, Ord c, Ord d, Ord e, Ord f, Ord g, Ord h, Ord i, Ord j) => Ord (a, b, c, d, e, f, g, h, i, j) Source # Instance detailsDefined in GHC.Classes Methodscompare :: (a, b, c, d, e, f, g, h, i, j) -> (a, b, c, d, e, f, g, h, i, j) -> Ordering Source #(<) :: (a, b, c, d, e, f, g, h, i, j) -> (a, b, c, d, e, f, g, h, i, j) -> Bool Source #(<=) :: (a, b, c, d, e, f, g, h, i, j) -> (a, b, c, d, e, f, g, h, i, j) -> Bool Source #(>) :: (a, b, c, d, e, f, g, h, i, j) -> (a, b, c, d, e, f, g, h, i, j) -> Bool Source #(>=) :: (a, b, c, d, e, f, g, h, i, j) -> (a, b, c, d, e, f, g, h, i, j) -> Bool Source #max :: (a, b, c, d, e, f, g, h, i, j) -> (a, b, c, d, e, f, g, h, i, j) -> (a, b, c, d, e, f, g, h, i, j) Source #min :: (a, b, c, d, e, f, g, h, i, j) -> (a, b, c, d, e, f, g, h, i, j) -> (a, b, c, d, e, f, g, h, i, j) Source # (Ord a, Ord b, Ord c, Ord d, Ord e, Ord f, Ord g, Ord h, Ord i, Ord j, Ord k) => Ord (a, b, c, d, e, f, g, h, i, j, k) Source # Instance detailsDefined in GHC.Classes Methodscompare :: (a, b, c, d, e, f, g, h, i, j, k) -> (a, b, c, d, e, f, g, h, i, j, k) -> Ordering Source #(<) :: (a, b, c, d, e, f, g, h, i, j, k) -> (a, b, c, d, e, f, g, h, i, j, k) -> Bool Source #(<=) :: (a, b, c, d, e, f, g, h, i, j, k) -> (a, b, c, d, e, f, g, h, i, j, k) -> Bool Source #(>) :: (a, b, c, d, e, f, g, h, i, j, k) -> (a, b, c, d, e, f, g, h, i, j, k) -> Bool Source #(>=) :: (a, b, c, d, e, f, g, h, i, j, k) -> (a, b, c, d, e, f, g, h, i, j, k) -> Bool Source #max :: (a, b, c, d, e, f, g, h, i, j, k) -> (a, b, c, d, e, f, g, h, i, j, k) -> (a, b, c, d, e, f, g, h, i, j, k) Source #min :: (a, b, c, d, e, f, g, h, i, j, k) -> (a, b, c, d, e, f, g, h, i, j, k) -> (a, b, c, d, e, f, g, h, i, j, k) Source # (Ord a, Ord b, Ord c, Ord d, Ord e, Ord f, Ord g, Ord h, Ord i, Ord j, Ord k, Ord l) => Ord (a, b, c, d, e, f, g, h, i, j, k, l) Source # Instance detailsDefined in GHC.Classes Methodscompare :: (a, b, c, d, e, f, g, h, i, j, k, l) -> (a, b, c, d, e, f, g, h, i, j, k, l) -> Ordering Source #(<) :: (a, b, c, d, e, f, g, h, i, j, k, l) -> (a, b, c, d, e, f, g, h, i, j, k, l) -> Bool Source #(<=) :: (a, b, c, d, e, f, g, h, i, j, k, l) -> (a, b, c, d, e, f, g, h, i, j, k, l) -> Bool Source #(>) :: (a, b, c, d, e, f, g, h, i, j, k, l) -> (a, b, c, d, e, f, g, h, i, j, k, l) -> Bool Source #(>=) :: (a, b, c, d, e, f, g, h, i, j, k, l) -> (a, b, c, d, e, f, g, h, i, j, k, l) -> Bool Source #max :: (a, b, c, d, e, f, g, h, i, j, k, l) -> (a, b, c, d, e, f, g, h, i, j, k, l) -> (a, b, c, d, e, f, g, h, i, j, k, l) Source #min :: (a, b, c, d, e, f, g, h, i, j, k, l) -> (a, b, c, d, e, f, g, h, i, j, k, l) -> (a, b, c, d, e, f, g, h, i, j, k, l) Source # (Ord a, Ord b, Ord c, Ord d, Ord e, Ord f, Ord g, Ord h, Ord i, Ord j, Ord k, Ord l, Ord m) => Ord (a, b, c, d, e, f, g, h, i, j, k, l, m) Source # Instance detailsDefined in GHC.Classes Methodscompare :: (a, b, c, d, e, f, g, h, i, j, k, l, m) -> (a, b, c, d, e, f, g, h, i, j, k, l, m) -> Ordering Source #(<) :: (a, b, c, d, e, f, g, h, i, j, k, l, m) -> (a, b, c, d, e, f, g, h, i, j, k, l, m) -> Bool Source #(<=) :: (a, b, c, d, e, f, g, h, i, j, k, l, m) -> (a, b, c, d, e, f, g, h, i, j, k, l, m) -> Bool Source #(>) :: (a, b, c, d, e, f, g, h, i, j, k, l, m) -> (a, b, c, d, e, f, g, h, i, j, k, l, m) -> Bool Source #(>=) :: (a, b, c, d, e, f, g, h, i, j, k, l, m) -> (a, b, c, d, e, f, g, h, i, j, k, l, m) -> Bool Source #max :: (a, b, c, d, e, f, g, h, i, j, k, l, m) -> (a, b, c, d, e, f, g, h, i, j, k, l, m) -> (a, b, c, d, e, f, g, h, i, j, k, l, m) Source #min :: (a, b, c, d, e, f, g, h, i, j, k, l, m) -> (a, b, c, d, e, f, g, h, i, j, k, l, m) -> (a, b, c, d, e, f, g, h, i, j, k, l, m) Source # (Ord a, Ord b, Ord c, Ord d, Ord e, Ord f, Ord g, Ord h, Ord i, Ord j, Ord k, Ord l, Ord m, Ord n) => Ord (a, b, c, d, e, f, g, h, i, j, k, l, m, n) Source # Instance detailsDefined in GHC.Classes Methodscompare :: (a, b, c, d, e, f, g, h, i, j, k, l, m, n) -> (a, b, c, d, e, f, g, h, i, j, k, l, m, n) -> Ordering Source #(<) :: (a, b, c, d, e, f, g, h, i, j, k, l, m, n) -> (a, b, c, d, e, f, g, h, i, j, k, l, m, n) -> Bool Source #(<=) :: (a, b, c, d, e, f, g, h, i, j, k, l, m, n) -> (a, b, c, d, e, f, g, h, i, j, k, l, m, n) -> Bool Source #(>) :: (a, b, c, d, e, f, g, h, i, j, k, l, m, n) -> (a, b, c, d, e, f, g, h, i, j, k, l, m, n) -> Bool Source #(>=) :: (a, b, c, d, e, f, g, h, i, j, k, l, m, n) -> (a, b, c, d, e, f, g, h, i, j, k, l, m, n) -> Bool Source #max :: (a, b, c, d, e, f, g, h, i, j, k, l, m, n) -> (a, b, c, d, e, f, g, h, i, j, k, l, m, n) -> (a, b, c, d, e, f, g, h, i, j, k, l, m, n) Source #min :: (a, b, c, d, e, f, g, h, i, j, k, l, m, n) -> (a, b, c, d, e, f, g, h, i, j, k, l, m, n) -> (a, b, c, d, e, f, g, h, i, j, k, l, m, n) Source # (Ord a, Ord b, Ord c, Ord d, Ord e, Ord f, Ord g, Ord h, Ord i, Ord j, Ord k, Ord l, Ord m, Ord n, Ord o) => Ord (a, b, c, d, e, f, g, h, i, j, k, l, m, n, o) Source # Instance detailsDefined in GHC.Classes Methodscompare :: (a, b, c, d, e, f, g, h, i, j, k, l, m, n, o) -> (a, b, c, d, e, f, g, h, i, j, k, l, m, n, o) -> Ordering Source #(<) :: (a, b, c, d, e, f, g, h, i, j, k, l, m, n, o) -> (a, b, c, d, e, f, g, h, i, j, k, l, m, n, o) -> Bool Source #(<=) :: (a, b, c, d, e, f, g, h, i, j, k, l, m, n, o) -> (a, b, c, d, e, f, g, h, i, j, k, l, m, n, o) -> Bool Source #(>) :: (a, b, c, d, e, f, g, h, i, j, k, l, m, n, o) -> (a, b, c, d, e, f, g, h, i, j, k, l, m, n, o) -> Bool Source #(>=) :: (a, b, c, d, e, f, g, h, i, j, k, l, m, n, o) -> (a, b, c, d, e, f, g, h, i, j, k, l, m, n, o) -> Bool Source #max :: (a, b, c, d, e, f, g, h, i, j, k, l, m, n, o) -> (a, b, c, d, e, f, g, h, i, j, k, l, m, n, o) -> (a, b, c, d, e, f, g, h, i, j, k, l, m, n, o) Source #min :: (a, b, c, d, e, f, g, h, i, j, k, l, m, n, o) -> (a, b, c, d, e, f, g, h, i, j, k, l, m, n, o) -> (a, b, c, d, e, f, g, h, i, j, k, l, m, n, o) Source #

data Ordering Source #

Constructors

 LT EQ GT

#### Instances

Instances details
Source #

Since: base-2.1

Instance details

Defined in GHC.Internal.Base

Source #

Since: base-4.9.0.0

Instance details

Defined in GHC.Internal.Base

Methods

stimes :: Integral b => b -> Ordering -> Ordering Source #

Source #

Since: base-4.0.0.0

Instance details

Defined in GHC.Internal.Data.Data

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> Ordering -> c Ordering Source #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c Ordering Source #

dataCast1 :: Typeable t => (forall d. Data d => c (t d)) -> Maybe (c Ordering) Source #

dataCast2 :: Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c Ordering) Source #

gmapT :: (forall b. Data b => b -> b) -> Ordering -> Ordering Source #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> Ordering -> r Source #

gmapQr :: forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> Ordering -> r Source #

gmapQ :: (forall d. Data d => d -> u) -> Ordering -> [u] Source #

gmapQi :: Int -> (forall d. Data d => d -> u) -> Ordering -> u Source #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> Ordering -> m Ordering Source #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> Ordering -> m Ordering Source #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> Ordering -> m Ordering Source #

Source #

Since: base-2.1

Instance details

Defined in GHC.Internal.Enum

Methods

Source #

Since: base-2.1

Instance details

Defined in GHC.Internal.Enum

Methods

Source #
Instance details

Defined in GHC.Internal.Generics

Associated Types

 type Rep Ordering Since: base-4.6.0.0 Instance detailsDefined in GHC.Internal.Generics type Rep Ordering = D1 ('MetaData "Ordering" "GHC.Types" "ghc-prim" 'False) (C1 ('MetaCons "LT" 'PrefixI 'False) (U1 :: Type -> Type) :+: (C1 ('MetaCons "EQ" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "GT" 'PrefixI 'False) (U1 :: Type -> Type)))

Methods

Source #

Since: base-2.1

Instance details

Defined in GHC.Internal.Ix

Source #

Since: base-2.1

Instance details

Methods

Source #

Since: base-2.1

Instance details

Defined in GHC.Internal.Show

Methods

showList :: [Ordering] -> ShowS Source #

Source #
Instance details

Defined in GHC.Classes

Methods

Source #
Instance details

Defined in GHC.Classes

Methods

type Rep Ordering Source #

Since: base-4.6.0.0

Instance details

Defined in GHC.Internal.Generics

type Rep Ordering = D1 ('MetaData "Ordering" "GHC.Types" "ghc-prim" 'False) (C1 ('MetaCons "LT" 'PrefixI 'False) (U1 :: Type -> Type) :+: (C1 ('MetaCons "EQ" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "GT" 'PrefixI 'False) (U1 :: Type -> Type)))

newtype Down a Source #

The Down type allows you to reverse sort order conveniently. A value of type Down a contains a value of type a (represented as Down a).

If a has an Ord instance associated with it then comparing two values thus wrapped will give you the opposite of their normal sort order. This is particularly useful when sorting in generalised list comprehensions, as in: then sortWith by Down x.

>>> compare True False
GT

>>> compare (Down True) (Down False)
LT


If a has a Bounded instance then the wrapped instance also respects the reversed ordering by exchanging the values of minBound and maxBound.

>>> minBound :: Int
-9223372036854775808

>>> minBound :: Down Int
Down 9223372036854775807


All other instances of Down a behave as they do for a.

Since: base-4.6.0.0

Constructors

 Down FieldsgetDown :: aSince: base-4.14.0.0

#### Instances

Instances details
Source #

Since: base-4.12.0.0

Instance details

Methods

mzip :: Down a -> Down b -> Down (a, b) Source #

mzipWith :: (a -> b -> c) -> Down a -> Down b -> Down c Source #

munzip :: Down (a, b) -> (Down a, Down b) Source #

Source #

Since: base-4.18.0.0

Instance details

Defined in Data.Foldable1

Methods

fold1 :: Semigroup m => Down m -> m Source #

foldMap1 :: Semigroup m => (a -> m) -> Down a -> m Source #

foldMap1' :: Semigroup m => (a -> m) -> Down a -> m Source #

maximum :: Ord a => Down a -> a Source #

minimum :: Ord a => Down a -> a Source #

head :: Down a -> a Source #

last :: Down a -> a Source #

foldrMap1 :: (a -> b) -> (a -> b -> b) -> Down a -> b Source #

foldlMap1' :: (a -> b) -> (b -> a -> b) -> Down a -> b Source #

foldlMap1 :: (a -> b) -> (b -> a -> b) -> Down a -> b Source #

foldrMap1' :: (a -> b) -> (a -> b -> b) -> Down a -> b Source #

Source #

Since: base-4.12.0.0

Instance details

Defined in Data.Functor.Classes

Methods

liftEq :: (a -> b -> Bool) -> Down a -> Down b -> Bool Source #

Source #

Since: base-4.12.0.0

Instance details

Defined in Data.Functor.Classes

Methods

liftCompare :: (a -> b -> Ordering) -> Down a -> Down b -> Ordering Source #

Source #

Since: base-4.12.0.0

Instance details

Defined in Data.Functor.Classes

Methods

Source #

Since: base-4.12.0.0

Instance details

Defined in Data.Functor.Classes

Methods

liftShowsPrec :: (Int -> a -> ShowS) -> ([a] -> ShowS) -> Int -> Down a -> ShowS Source #

liftShowList :: (Int -> a -> ShowS) -> ([a] -> ShowS) -> [Down a] -> ShowS Source #

Source #

Since: base-4.11.0.0

Instance details

Defined in GHC.Internal.Data.Ord

Methods

pure :: a -> Down a Source #

(<*>) :: Down (a -> b) -> Down a -> Down b Source #

liftA2 :: (a -> b -> c) -> Down a -> Down b -> Down c Source #

(*>) :: Down a -> Down b -> Down b Source #

(<*) :: Down a -> Down b -> Down a Source #

Source #

Since: base-4.11.0.0

Instance details

Defined in GHC.Internal.Data.Ord

Methods

fmap :: (a -> b) -> Down a -> Down b Source #

(<\$) :: a -> Down b -> Down a Source #

Source #

Since: base-4.11.0.0

Instance details

Defined in GHC.Internal.Data.Ord

Methods

(>>=) :: Down a -> (a -> Down b) -> Down b Source #

(>>) :: Down a -> Down b -> Down b Source #

return :: a -> Down a Source #

Source #

Since: base-4.12.0.0

Instance details

Methods

mfix :: (a -> Down a) -> Down a Source #

Source #

Since: base-4.12.0.0

Instance details

Defined in GHC.Internal.Data.Foldable

Methods

fold :: Monoid m => Down m -> m Source #

foldMap :: Monoid m => (a -> m) -> Down a -> m Source #

foldMap' :: Monoid m => (a -> m) -> Down a -> m Source #

foldr :: (a -> b -> b) -> b -> Down a -> b Source #

foldr' :: (a -> b -> b) -> b -> Down a -> b Source #

foldl :: (b -> a -> b) -> b -> Down a -> b Source #

foldl' :: (b -> a -> b) -> b -> Down a -> b Source #

foldr1 :: (a -> a -> a) -> Down a -> a Source #

foldl1 :: (a -> a -> a) -> Down a -> a Source #

toList :: Down a -> [a] Source #

null :: Down a -> Bool Source #

length :: Down a -> Int Source #

elem :: Eq a => a -> Down a -> Bool Source #

maximum :: Ord a => Down a -> a Source #

minimum :: Ord a => Down a -> a Source #

sum :: Num a => Down a -> a Source #

product :: Num a => Down a -> a Source #

Source #

Since: base-4.12.0.0

Instance details

Defined in GHC.Internal.Data.Traversable

Methods

traverse :: Applicative f => (a -> f b) -> Down a -> f (Down b) Source #

sequenceA :: Applicative f => Down (f a) -> f (Down a) Source #

mapM :: Monad m => (a -> m b) -> Down a -> m (Down b) Source #

sequence :: Monad m => Down (m a) -> m (Down a) Source #

Source #
Instance details

Defined in GHC.Internal.Generics

Associated Types

 type Rep1 Down Since: base-4.12.0.0 Instance detailsDefined in GHC.Internal.Generics type Rep1 Down = D1 ('MetaData "Down" "GHC.Internal.Data.Ord" "ghc-internal" 'True) (C1 ('MetaCons "Down" 'PrefixI 'True) (S1 ('MetaSel ('Just "getDown") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) Par1))

Methods

from1 :: Down a -> Rep1 Down a Source #

to1 :: Rep1 Down a -> Down a Source #

Monoid a => Monoid (Down a) Source #

Since: base-4.11.0.0

Instance details

Defined in GHC.Internal.Data.Ord

Methods

mappend :: Down a -> Down a -> Down a Source #

mconcat :: [Down a] -> Down a Source #

Semigroup a => Semigroup (Down a) Source #

Since: base-4.11.0.0

Instance details

Defined in GHC.Internal.Data.Ord

Methods

(<>) :: Down a -> Down a -> Down a Source #

sconcat :: NonEmpty (Down a) -> Down a Source #

stimes :: Integral b => b -> Down a -> Down a Source #

Bits a => Bits (Down a) Source #

Since: base-4.14.0.0

Instance details

Defined in GHC.Internal.Data.Ord

Methods

(.&.) :: Down a -> Down a -> Down a Source #

(.|.) :: Down a -> Down a -> Down a Source #

xor :: Down a -> Down a -> Down a Source #

complement :: Down a -> Down a Source #

shift :: Down a -> Int -> Down a Source #

rotate :: Down a -> Int -> Down a Source #

bit :: Int -> Down a Source #

setBit :: Down a -> Int -> Down a Source #

clearBit :: Down a -> Int -> Down a Source #

complementBit :: Down a -> Int -> Down a Source #

testBit :: Down a -> Int -> Bool Source #

bitSize :: Down a -> Int Source #

isSigned :: Down a -> Bool Source #

shiftL :: Down a -> Int -> Down a Source #

unsafeShiftL :: Down a -> Int -> Down a Source #

shiftR :: Down a -> Int -> Down a Source #

unsafeShiftR :: Down a -> Int -> Down a Source #

rotateL :: Down a -> Int -> Down a Source #

rotateR :: Down a -> Int -> Down a Source #

popCount :: Down a -> Int Source #

FiniteBits a => FiniteBits (Down a) Source #

Since: base-4.14.0.0

Instance details

Defined in GHC.Internal.Data.Ord

Methods

Data a => Data (Down a) Source #

Since: base-4.12.0.0

Instance details

Defined in GHC.Internal.Data.Data

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> Down a -> c (Down a) Source #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c (Down a) Source #

dataCast1 :: Typeable t => (forall d. Data d => c (t d)) -> Maybe (c (Down a)) Source #

dataCast2 :: Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c (Down a)) Source #

gmapT :: (forall b. Data b => b -> b) -> Down a -> Down a Source #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> Down a -> r Source #

gmapQr :: forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> Down a -> r Source #

gmapQ :: (forall d. Data d => d -> u) -> Down a -> [u] Source #

gmapQi :: Int -> (forall d. Data d => d -> u) -> Down a -> u Source #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> Down a -> m (Down a) Source #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> Down a -> m (Down a) Source #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> Down a -> m (Down a) Source #

Bounded a => Bounded (Down a) Source #

Swaps minBound and maxBound of the underlying type.

Since: base-4.14.0.0

Instance details

Defined in GHC.Internal.Data.Ord

Methods

(Enum a, Bounded a, Eq a) => Enum (Down a) Source #

Swaps succ and pred of the underlying type.

Since: base-4.18.0.0

Instance details

Defined in GHC.Internal.Data.Ord

Methods

succ :: Down a -> Down a Source #

pred :: Down a -> Down a Source #

toEnum :: Int -> Down a Source #

fromEnum :: Down a -> Int Source #

enumFrom :: Down a -> [Down a] Source #

enumFromThen :: Down a -> Down a -> [Down a] Source #

enumFromTo :: Down a -> Down a -> [Down a] Source #

enumFromThenTo :: Down a -> Down a -> Down a -> [Down a] Source #

Floating a => Floating (Down a) Source #

Since: base-4.14.0.0

Instance details

Defined in GHC.Internal.Data.Ord

Methods

exp :: Down a -> Down a Source #

log :: Down a -> Down a Source #

sqrt :: Down a -> Down a Source #

(**) :: Down a -> Down a -> Down a Source #

logBase :: Down a -> Down a -> Down a Source #

sin :: Down a -> Down a Source #

cos :: Down a -> Down a Source #

tan :: Down a -> Down a Source #

asin :: Down a -> Down a