base-4.14.1.0: Basic libraries

Data.Ord

Description

Orderings

Synopsis

# Documentation

class Eq a => Ord a where #

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.

The Haskell Report defines no laws for Ord. However, <= is customarily expected to implement a non-strict partial order and have the following properties:

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

Note that 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 (==).

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

Minimal complete definition

Methods

compare :: a -> a -> Ordering #

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

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

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

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

max :: a -> a -> a #

min :: a -> a -> a #

#### Instances

Instances details
 Instance detailsDefined in GHC.Classes Methodscompare :: Bool -> Bool -> Ordering #(<) :: Bool -> Bool -> Bool #(<=) :: Bool -> Bool -> Bool #(>) :: Bool -> Bool -> Bool #(>=) :: Bool -> Bool -> Bool #max :: Bool -> Bool -> Bool #min :: Bool -> Bool -> Bool # Instance detailsDefined in GHC.Classes Methodscompare :: Char -> Char -> Ordering #(<) :: Char -> Char -> Bool #(<=) :: Char -> Char -> Bool #(>) :: Char -> Char -> Bool #(>=) :: Char -> Char -> Bool #max :: Char -> Char -> Char #min :: Char -> Char -> Char # Note that due to the presence of NaN, Double's Ord instance does not satisfy reflexivity.>>> 0/0 <= (0/0 :: Double) False Also note that, due to the same, Ord's operator interactions are not respected by Double's instance:>>> (0/0 :: Double) > 1 False >>> compare (0/0 :: Double) 1 GT  Instance detailsDefined in GHC.Classes Methods(<) :: Double -> Double -> Bool #(<=) :: Double -> Double -> Bool #(>) :: Double -> Double -> Bool #(>=) :: Double -> Double -> Bool #max :: Double -> Double -> Double #min :: Double -> Double -> Double # Note that due to the presence of NaN, Float's Ord instance does not satisfy reflexivity.>>> 0/0 <= (0/0 :: Float) False Also note that, due to the same, Ord's operator interactions are not respected by Float's instance:>>> (0/0 :: Float) > 1 False >>> compare (0/0 :: Float) 1 GT  Instance detailsDefined in GHC.Classes Methods(<) :: Float -> Float -> Bool #(<=) :: Float -> Float -> Bool #(>) :: Float -> Float -> Bool #(>=) :: Float -> Float -> Bool #max :: Float -> Float -> Float #min :: Float -> Float -> Float # Instance detailsDefined in GHC.Classes Methodscompare :: Int -> Int -> Ordering #(<) :: Int -> Int -> Bool #(<=) :: Int -> Int -> Bool #(>) :: Int -> Int -> Bool #(>=) :: Int -> Int -> Bool #max :: Int -> Int -> Int #min :: Int -> Int -> Int # Source # Since: 2.1 Instance detailsDefined in GHC.Int Methodscompare :: Int8 -> Int8 -> Ordering #(<) :: Int8 -> Int8 -> Bool #(<=) :: Int8 -> Int8 -> Bool #(>) :: Int8 -> Int8 -> Bool #(>=) :: Int8 -> Int8 -> Bool #max :: Int8 -> Int8 -> Int8 #min :: Int8 -> Int8 -> Int8 # Source # Since: 2.1 Instance detailsDefined in GHC.Int Methods(<) :: Int16 -> Int16 -> Bool #(<=) :: Int16 -> Int16 -> Bool #(>) :: Int16 -> Int16 -> Bool #(>=) :: Int16 -> Int16 -> Bool #max :: Int16 -> Int16 -> Int16 #min :: Int16 -> Int16 -> Int16 # Source # Since: 2.1 Instance detailsDefined in GHC.Int Methods(<) :: Int32 -> Int32 -> Bool #(<=) :: Int32 -> Int32 -> Bool #(>) :: Int32 -> Int32 -> Bool #(>=) :: Int32 -> Int32 -> Bool #max :: Int32 -> Int32 -> Int32 #min :: Int32 -> Int32 -> Int32 # Source # Since: 2.1 Instance detailsDefined in GHC.Int Methods(<) :: Int64 -> Int64 -> Bool #(<=) :: Int64 -> Int64 -> Bool #(>) :: Int64 -> Int64 -> Bool #(>=) :: Int64 -> Int64 -> Bool #max :: Int64 -> Int64 -> Int64 #min :: Int64 -> Int64 -> Int64 # Instance detailsDefined in GHC.Integer.Type Methods(<) :: Integer -> Integer -> Bool #(<=) :: Integer -> Integer -> Bool #(>) :: Integer -> Integer -> Bool #(>=) :: Integer -> Integer -> Bool # Source # Since: 4.8.0.0 Instance detailsDefined in GHC.Natural Methods(<) :: Natural -> Natural -> Bool #(<=) :: Natural -> Natural -> Bool #(>) :: Natural -> Natural -> Bool #(>=) :: Natural -> Natural -> Bool # Instance detailsDefined in GHC.Classes Methods(<) :: Ordering -> Ordering -> Bool #(>) :: Ordering -> Ordering -> Bool # Instance detailsDefined in GHC.Classes Methodscompare :: Word -> Word -> Ordering #(<) :: Word -> Word -> Bool #(<=) :: Word -> Word -> Bool #(>) :: Word -> Word -> Bool #(>=) :: Word -> Word -> Bool #max :: Word -> Word -> Word #min :: Word -> Word -> Word # Source # Since: 2.1 Instance detailsDefined in GHC.Word Methods(<) :: Word8 -> Word8 -> Bool #(<=) :: Word8 -> Word8 -> Bool #(>) :: Word8 -> Word8 -> Bool #(>=) :: Word8 -> Word8 -> Bool #max :: Word8 -> Word8 -> Word8 #min :: Word8 -> Word8 -> Word8 # Source # Since: 2.1 Instance detailsDefined in GHC.Word Methods(<) :: Word16 -> Word16 -> Bool #(<=) :: Word16 -> Word16 -> Bool #(>) :: Word16 -> Word16 -> Bool #(>=) :: Word16 -> Word16 -> Bool #max :: Word16 -> Word16 -> Word16 #min :: Word16 -> Word16 -> Word16 # Source # Since: 2.1 Instance detailsDefined in GHC.Word Methods(<) :: Word32 -> Word32 -> Bool #(<=) :: Word32 -> Word32 -> Bool #(>) :: Word32 -> Word32 -> Bool #(>=) :: Word32 -> Word32 -> Bool #max :: Word32 -> Word32 -> Word32 #min :: Word32 -> Word32 -> Word32 # Source # Since: 2.1 Instance detailsDefined in GHC.Word Methods(<) :: Word64 -> Word64 -> Bool #(<=) :: Word64 -> Word64 -> Bool #(>) :: Word64 -> Word64 -> Bool #(>=) :: Word64 -> Word64 -> Bool #max :: Word64 -> Word64 -> Word64 #min :: Word64 -> Word64 -> Word64 # Source # Instance detailsDefined in Data.Typeable.Internal Methods Ord () Instance detailsDefined in GHC.Classes Methodscompare :: () -> () -> Ordering #(<) :: () -> () -> Bool #(<=) :: () -> () -> Bool #(>) :: () -> () -> Bool #(>=) :: () -> () -> Bool #max :: () -> () -> () #min :: () -> () -> () # Instance detailsDefined in GHC.Classes Methods(<) :: TyCon -> TyCon -> Bool #(<=) :: TyCon -> TyCon -> Bool #(>) :: TyCon -> TyCon -> Bool #(>=) :: TyCon -> TyCon -> Bool #max :: TyCon -> TyCon -> TyCon #min :: TyCon -> TyCon -> TyCon # Instance detailsDefined in GHC.Integer.Type Methods(<) :: BigNat -> BigNat -> Bool #(<=) :: BigNat -> BigNat -> Bool #(>) :: BigNat -> BigNat -> Bool #(>=) :: BigNat -> BigNat -> Bool #max :: BigNat -> BigNat -> BigNat #min :: BigNat -> BigNat -> BigNat # Source # Since: 2.1 Instance detailsDefined in GHC.Unicode Methods Source # Since: 4.4.0.0 Instance detailsDefined in GHC.Fingerprint.Type Methods Source # Since: 4.2.0.0 Instance detailsDefined in GHC.IO.IOMode Methods(<) :: IOMode -> IOMode -> Bool #(<=) :: IOMode -> IOMode -> Bool #(>) :: IOMode -> IOMode -> Bool #(>=) :: IOMode -> IOMode -> Bool #max :: IOMode -> IOMode -> IOMode #min :: IOMode -> IOMode -> IOMode # Source # Instance detailsDefined in Foreign.Ptr Methods(<) :: IntPtr -> IntPtr -> Bool #(<=) :: IntPtr -> IntPtr -> Bool #(>) :: IntPtr -> IntPtr -> Bool #(>=) :: IntPtr -> IntPtr -> Bool #max :: IntPtr -> IntPtr -> IntPtr #min :: IntPtr -> IntPtr -> IntPtr # Source # Instance detailsDefined in Foreign.Ptr Methods(<) :: WordPtr -> WordPtr -> Bool #(<=) :: WordPtr -> WordPtr -> Bool #(>) :: WordPtr -> WordPtr -> Bool #(>=) :: WordPtr -> WordPtr -> Bool # Source # Instance detailsDefined in Foreign.C.Types Methods(<) :: CUIntMax -> CUIntMax -> Bool #(>) :: CUIntMax -> CUIntMax -> Bool # Source # Instance detailsDefined in Foreign.C.Types Methods(<) :: CIntMax -> CIntMax -> Bool #(<=) :: CIntMax -> CIntMax -> Bool #(>) :: CIntMax -> CIntMax -> Bool #(>=) :: CIntMax -> CIntMax -> Bool # Source # Instance detailsDefined in Foreign.C.Types Methods(<) :: CUIntPtr -> CUIntPtr -> Bool #(>) :: CUIntPtr -> CUIntPtr -> Bool # Source # Instance detailsDefined in Foreign.C.Types Methods(<) :: CIntPtr -> CIntPtr -> Bool #(<=) :: CIntPtr -> CIntPtr -> Bool #(>) :: CIntPtr -> CIntPtr -> Bool #(>=) :: CIntPtr -> CIntPtr -> Bool # Source # Instance detailsDefined in Foreign.C.Types Methods Source # Instance detailsDefined in Foreign.C.Types Methods Source # Instance detailsDefined in Foreign.C.Types Methods(<) :: CTime -> CTime -> Bool #(<=) :: CTime -> CTime -> Bool #(>) :: CTime -> CTime -> Bool #(>=) :: CTime -> CTime -> Bool #max :: CTime -> CTime -> CTime #min :: CTime -> CTime -> CTime # Source # Instance detailsDefined in Foreign.C.Types Methods(<) :: CClock -> CClock -> Bool #(<=) :: CClock -> CClock -> Bool #(>) :: CClock -> CClock -> Bool #(>=) :: CClock -> CClock -> Bool #max :: CClock -> CClock -> CClock #min :: CClock -> CClock -> CClock # Source # Instance detailsDefined in Foreign.C.Types Methods Source # Instance detailsDefined in Foreign.C.Types Methods(<) :: CWchar -> CWchar -> Bool #(<=) :: CWchar -> CWchar -> Bool #(>) :: CWchar -> CWchar -> Bool #(>=) :: CWchar -> CWchar -> Bool #max :: CWchar -> CWchar -> CWchar #min :: CWchar -> CWchar -> CWchar # Source # Instance detailsDefined in Foreign.C.Types Methods(<) :: CSize -> CSize -> Bool #(<=) :: CSize -> CSize -> Bool #(>) :: CSize -> CSize -> Bool #(>=) :: CSize -> CSize -> Bool #max :: CSize -> CSize -> CSize #min :: CSize -> CSize -> CSize # Source # Instance detailsDefined in Foreign.C.Types Methods(<) :: CPtrdiff -> CPtrdiff -> Bool #(>) :: CPtrdiff -> CPtrdiff -> Bool # Source # Instance detailsDefined in Foreign.C.Types Methods(<) :: CDouble -> CDouble -> Bool #(<=) :: CDouble -> CDouble -> Bool #(>) :: CDouble -> CDouble -> Bool #(>=) :: CDouble -> CDouble -> Bool # Source # Instance detailsDefined in Foreign.C.Types Methods(<) :: CFloat -> CFloat -> Bool #(<=) :: CFloat -> CFloat -> Bool #(>) :: CFloat -> CFloat -> Bool #(>=) :: CFloat -> CFloat -> Bool #max :: CFloat -> CFloat -> CFloat #min :: CFloat -> CFloat -> CFloat # Source # Instance detailsDefined in Foreign.C.Types Methods(<) :: CBool -> CBool -> Bool #(<=) :: CBool -> CBool -> Bool #(>) :: CBool -> CBool -> Bool #(>=) :: CBool -> CBool -> Bool #max :: CBool -> CBool -> CBool #min :: CBool -> CBool -> CBool # Source # Instance detailsDefined in Foreign.C.Types Methods(<) :: CULLong -> CULLong -> Bool #(<=) :: CULLong -> CULLong -> Bool #(>) :: CULLong -> CULLong -> Bool #(>=) :: CULLong -> CULLong -> Bool # Source # Instance detailsDefined in Foreign.C.Types Methods(<) :: CLLong -> CLLong -> Bool #(<=) :: CLLong -> CLLong -> Bool #(>) :: CLLong -> CLLong -> Bool #(>=) :: CLLong -> CLLong -> Bool #max :: CLLong -> CLLong -> CLLong #min :: CLLong -> CLLong -> CLLong # Source # Instance detailsDefined in Foreign.C.Types Methods(<) :: CULong -> CULong -> Bool #(<=) :: CULong -> CULong -> Bool #(>) :: CULong -> CULong -> Bool #(>=) :: CULong -> CULong -> Bool #max :: CULong -> CULong -> CULong #min :: CULong -> CULong -> CULong # Source # Instance detailsDefined in Foreign.C.Types Methods(<) :: CLong -> CLong -> Bool #(<=) :: CLong -> CLong -> Bool #(>) :: CLong -> CLong -> Bool #(>=) :: CLong -> CLong -> Bool #max :: CLong -> CLong -> CLong #min :: CLong -> CLong -> CLong # Source # Instance detailsDefined in Foreign.C.Types Methods(<) :: CUInt -> CUInt -> Bool #(<=) :: CUInt -> CUInt -> Bool #(>) :: CUInt -> CUInt -> Bool #(>=) :: CUInt -> CUInt -> Bool #max :: CUInt -> CUInt -> CUInt #min :: CUInt -> CUInt -> CUInt # Source # Instance detailsDefined in Foreign.C.Types Methodscompare :: CInt -> CInt -> Ordering #(<) :: CInt -> CInt -> Bool #(<=) :: CInt -> CInt -> Bool #(>) :: CInt -> CInt -> Bool #(>=) :: CInt -> CInt -> Bool #max :: CInt -> CInt -> CInt #min :: CInt -> CInt -> CInt # Source # Instance detailsDefined in Foreign.C.Types Methods(<) :: CUShort -> CUShort -> Bool #(<=) :: CUShort -> CUShort -> Bool #(>) :: CUShort -> CUShort -> Bool #(>=) :: CUShort -> CUShort -> Bool # Source # Instance detailsDefined in Foreign.C.Types Methods(<) :: CShort -> CShort -> Bool #(<=) :: CShort -> CShort -> Bool #(>) :: CShort -> CShort -> Bool #(>=) :: CShort -> CShort -> Bool #max :: CShort -> CShort -> CShort #min :: CShort -> CShort -> CShort # Source # Instance detailsDefined in Foreign.C.Types Methods(<) :: CUChar -> CUChar -> Bool #(<=) :: CUChar -> CUChar -> Bool #(>) :: CUChar -> CUChar -> Bool #(>=) :: CUChar -> CUChar -> Bool #max :: CUChar -> CUChar -> CUChar #min :: CUChar -> CUChar -> CUChar # Source # Instance detailsDefined in Foreign.C.Types Methods(<) :: CSChar -> CSChar -> Bool #(<=) :: CSChar -> CSChar -> Bool #(>) :: CSChar -> CSChar -> Bool #(>=) :: CSChar -> CSChar -> Bool #max :: CSChar -> CSChar -> CSChar #min :: CSChar -> CSChar -> CSChar # Source # Instance detailsDefined in Foreign.C.Types Methods(<) :: CChar -> CChar -> Bool #(<=) :: CChar -> CChar -> Bool #(>) :: CChar -> CChar -> Bool #(>=) :: CChar -> CChar -> Bool #max :: CChar -> CChar -> CChar #min :: CChar -> CChar -> CChar # Source # Since: 4.7.0.0 Instance detailsDefined in GHC.TypeNats Methods(<) :: SomeNat -> SomeNat -> Bool #(<=) :: SomeNat -> SomeNat -> Bool #(>) :: SomeNat -> SomeNat -> Bool #(>=) :: SomeNat -> SomeNat -> Bool # Source # Since: 4.7.0.0 Instance detailsDefined in GHC.TypeLits Methods Source # Since: 4.9.0.0 Instance detailsDefined in GHC.Generics Methods Source # Since: 4.9.0.0 Instance detailsDefined in GHC.Generics Methods Source # Since: 4.9.0.0 Instance detailsDefined in GHC.Generics Methods Source # Since: 4.6.0.0 Instance detailsDefined in GHC.Generics Methods Source # Since: 4.6.0.0 Instance detailsDefined in GHC.Generics Methods(<) :: Fixity -> Fixity -> Bool #(<=) :: Fixity -> Fixity -> Bool #(>) :: Fixity -> Fixity -> Bool #(>=) :: Fixity -> Fixity -> Bool #max :: Fixity -> Fixity -> Fixity #min :: Fixity -> Fixity -> Fixity # Source # Since: 2.1 Instance detailsDefined in Data.Semigroup.Internal Methodscompare :: Any -> Any -> Ordering #(<) :: Any -> Any -> Bool #(<=) :: Any -> Any -> Bool #(>) :: Any -> Any -> Bool #(>=) :: Any -> Any -> Bool #max :: Any -> Any -> Any #min :: Any -> Any -> Any # Source # Since: 2.1 Instance detailsDefined in Data.Semigroup.Internal Methodscompare :: All -> All -> Ordering #(<) :: All -> All -> Bool #(<=) :: All -> All -> Bool #(>) :: All -> All -> Bool #(>=) :: All -> All -> Bool #max :: All -> All -> All #min :: All -> All -> All # Source # Since: 3.0 Instance detailsDefined in GHC.Exception.Type Methods Source # Since: 4.7.0.0 Instance detailsDefined in GHC.Exception Methods Source # Since: 4.2.0.0 Instance detailsDefined in GHC.IO.Device Methods(<) :: SeekMode -> SeekMode -> Bool #(>) :: SeekMode -> SeekMode -> Bool # Source # Since: 4.3.0.0 Instance detailsDefined in GHC.IO.Handle.Types Methods Source # Since: 4.3.0.0 Instance detailsDefined in GHC.IO.Handle.Types Methods(<) :: Newline -> Newline -> Bool #(<=) :: Newline -> Newline -> Bool #(>) :: Newline -> Newline -> Bool #(>=) :: Newline -> Newline -> Bool # Source # Since: 4.2.0.0 Instance detailsDefined in GHC.IO.Handle.Types Methods Source # Instance detailsDefined in GHC.IO.Exception Methods(<) :: ExitCode -> ExitCode -> Bool #(>) :: ExitCode -> ExitCode -> Bool # Source # Since: 4.2.0.0 Instance detailsDefined in GHC.IO.Exception Methods Source # Since: 4.2.0.0 Instance detailsDefined in GHC.IO.Exception Methods Source # Instance detailsDefined in System.Posix.Types Methodscompare :: Fd -> Fd -> Ordering #(<) :: Fd -> Fd -> Bool #(<=) :: Fd -> Fd -> Bool #(>) :: Fd -> Fd -> Bool #(>=) :: Fd -> Fd -> Bool #max :: Fd -> Fd -> Fd #min :: Fd -> Fd -> Fd # Source # Instance detailsDefined in System.Posix.Types Methods(<) :: CNfds -> CNfds -> Bool #(<=) :: CNfds -> CNfds -> Bool #(>) :: CNfds -> CNfds -> Bool #(>=) :: CNfds -> CNfds -> Bool #max :: CNfds -> CNfds -> CNfds #min :: CNfds -> CNfds -> CNfds # Source # Instance detailsDefined in System.Posix.Types Methods(<) :: CSocklen -> CSocklen -> Bool #(>) :: CSocklen -> CSocklen -> Bool # Source # Instance detailsDefined in System.Posix.Types Methods(<) :: CTimer -> CTimer -> Bool #(<=) :: CTimer -> CTimer -> Bool #(>) :: CTimer -> CTimer -> Bool #(>=) :: CTimer -> CTimer -> Bool #max :: CTimer -> CTimer -> CTimer #min :: CTimer -> CTimer -> CTimer # Source # Instance detailsDefined in System.Posix.Types Methodscompare :: CKey -> CKey -> Ordering #(<) :: CKey -> CKey -> Bool #(<=) :: CKey -> CKey -> Bool #(>) :: CKey -> CKey -> Bool #(>=) :: CKey -> CKey -> Bool #max :: CKey -> CKey -> CKey #min :: CKey -> CKey -> CKey # Source # Instance detailsDefined in System.Posix.Types Methodscompare :: CId -> CId -> Ordering #(<) :: CId -> CId -> Bool #(<=) :: CId -> CId -> Bool #(>) :: CId -> CId -> Bool #(>=) :: CId -> CId -> Bool #max :: CId -> CId -> CId #min :: CId -> CId -> CId # Source # Instance detailsDefined in System.Posix.Types Methods Source # Instance detailsDefined in System.Posix.Types Methods Source # Instance detailsDefined in System.Posix.Types Methods(<) :: CClockId -> CClockId -> Bool #(>) :: CClockId -> CClockId -> Bool # Source # Instance detailsDefined in System.Posix.Types Methods(<) :: CBlkCnt -> CBlkCnt -> Bool #(<=) :: CBlkCnt -> CBlkCnt -> Bool #(>) :: CBlkCnt -> CBlkCnt -> Bool #(>=) :: CBlkCnt -> CBlkCnt -> Bool # Source # Instance detailsDefined in System.Posix.Types Methods(<) :: CBlkSize -> CBlkSize -> Bool #(>) :: CBlkSize -> CBlkSize -> Bool # Source # Instance detailsDefined in System.Posix.Types Methods(<) :: CRLim -> CRLim -> Bool #(<=) :: CRLim -> CRLim -> Bool #(>) :: CRLim -> CRLim -> Bool #(>=) :: CRLim -> CRLim -> Bool #max :: CRLim -> CRLim -> CRLim #min :: CRLim -> CRLim -> CRLim # Source # Instance detailsDefined in System.Posix.Types Methods(<) :: CTcflag -> CTcflag -> Bool #(<=) :: CTcflag -> CTcflag -> Bool #(>) :: CTcflag -> CTcflag -> Bool #(>=) :: CTcflag -> CTcflag -> Bool # Source # Instance detailsDefined in System.Posix.Types Methods(<) :: CSpeed -> CSpeed -> Bool #(<=) :: CSpeed -> CSpeed -> Bool #(>) :: CSpeed -> CSpeed -> Bool #(>=) :: CSpeed -> CSpeed -> Bool #max :: CSpeed -> CSpeed -> CSpeed #min :: CSpeed -> CSpeed -> CSpeed # Source # Instance detailsDefined in System.Posix.Types Methodscompare :: CCc -> CCc -> Ordering #(<) :: CCc -> CCc -> Bool #(<=) :: CCc -> CCc -> Bool #(>) :: CCc -> CCc -> Bool #(>=) :: CCc -> CCc -> Bool #max :: CCc -> CCc -> CCc #min :: CCc -> CCc -> CCc # Source # Instance detailsDefined in System.Posix.Types Methodscompare :: CUid -> CUid -> Ordering #(<) :: CUid -> CUid -> Bool #(<=) :: CUid -> CUid -> Bool #(>) :: CUid -> CUid -> Bool #(>=) :: CUid -> CUid -> Bool #max :: CUid -> CUid -> CUid #min :: CUid -> CUid -> CUid # Source # Instance detailsDefined in System.Posix.Types Methods(<) :: CNlink -> CNlink -> Bool #(<=) :: CNlink -> CNlink -> Bool #(>) :: CNlink -> CNlink -> Bool #(>=) :: CNlink -> CNlink -> Bool #max :: CNlink -> CNlink -> CNlink #min :: CNlink -> CNlink -> CNlink # Source # Instance detailsDefined in System.Posix.Types Methodscompare :: CGid -> CGid -> Ordering #(<) :: CGid -> CGid -> Bool #(<=) :: CGid -> CGid -> Bool #(>) :: CGid -> CGid -> Bool #(>=) :: CGid -> CGid -> Bool #max :: CGid -> CGid -> CGid #min :: CGid -> CGid -> CGid # Source # Instance detailsDefined in System.Posix.Types Methods(<) :: CSsize -> CSsize -> Bool #(<=) :: CSsize -> CSsize -> Bool #(>) :: CSsize -> CSsize -> Bool #(>=) :: CSsize -> CSsize -> Bool #max :: CSsize -> CSsize -> CSsize #min :: CSsize -> CSsize -> CSsize # Source # Instance detailsDefined in System.Posix.Types Methodscompare :: CPid -> CPid -> Ordering #(<) :: CPid -> CPid -> Bool #(<=) :: CPid -> CPid -> Bool #(>) :: CPid -> CPid -> Bool #(>=) :: CPid -> CPid -> Bool #max :: CPid -> CPid -> CPid #min :: CPid -> CPid -> CPid # Source # Instance detailsDefined in System.Posix.Types Methodscompare :: COff -> COff -> Ordering #(<) :: COff -> COff -> Bool #(<=) :: COff -> COff -> Bool #(>) :: COff -> COff -> Bool #(>=) :: COff -> COff -> Bool #max :: COff -> COff -> COff #min :: COff -> COff -> COff # Source # Instance detailsDefined in System.Posix.Types Methods(<) :: CMode -> CMode -> Bool #(<=) :: CMode -> CMode -> Bool #(>) :: CMode -> CMode -> Bool #(>=) :: CMode -> CMode -> Bool #max :: CMode -> CMode -> CMode #min :: CMode -> CMode -> CMode # Source # Instance detailsDefined in System.Posix.Types Methodscompare :: CIno -> CIno -> Ordering #(<) :: CIno -> CIno -> Bool #(<=) :: CIno -> CIno -> Bool #(>) :: CIno -> CIno -> Bool #(>=) :: CIno -> CIno -> Bool #max :: CIno -> CIno -> CIno #min :: CIno -> CIno -> CIno # Source # Instance detailsDefined in System.Posix.Types Methodscompare :: CDev -> CDev -> Ordering #(<) :: CDev -> CDev -> Bool #(<=) :: CDev -> CDev -> Bool #(>) :: CDev -> CDev -> Bool #(>=) :: CDev -> CDev -> Bool #max :: CDev -> CDev -> CDev #min :: CDev -> CDev -> CDev # Source # Since: 4.3.0.0 Instance detailsDefined in GHC.Conc.Sync Methods Source # Since: 4.3.0.0 Instance detailsDefined in GHC.Conc.Sync Methods Source # Since: 4.2.0.0 Instance detailsDefined in GHC.Conc.Sync Methods(<) :: ThreadId -> ThreadId -> Bool #(>) :: ThreadId -> ThreadId -> Bool # Source # Since: 2.1 Instance detailsDefined in Data.Version Methods(<) :: Version -> Version -> Bool #(<=) :: Version -> Version -> Bool #(>) :: Version -> Version -> Bool #(>=) :: Version -> Version -> Bool # Source # Since: 4.11.0.0 Instance detailsDefined in GHC.ByteOrder Methods Source # Instance detailsDefined in Data.Unique Methods(<) :: Unique -> Unique -> Bool #(<=) :: Unique -> Unique -> Bool #(>) :: Unique -> Unique -> Bool #(>=) :: Unique -> Unique -> Bool #max :: Unique -> Unique -> Unique #min :: Unique -> Unique -> Unique # Source # Since: 4.8.0.0 Instance detailsDefined in Data.Void Methodscompare :: Void -> Void -> Ordering #(<) :: Void -> Void -> Bool #(<=) :: Void -> Void -> Bool #(>) :: Void -> Void -> Bool #(>=) :: Void -> Void -> Bool #max :: Void -> Void -> Void #min :: Void -> Void -> Void # Ord a => Ord [a] Instance detailsDefined in GHC.Classes Methodscompare :: [a] -> [a] -> Ordering #(<) :: [a] -> [a] -> Bool #(<=) :: [a] -> [a] -> Bool #(>) :: [a] -> [a] -> Bool #(>=) :: [a] -> [a] -> Bool #max :: [a] -> [a] -> [a] #min :: [a] -> [a] -> [a] # Ord a => Ord (Maybe a) Source # Since: 2.1 Instance detailsDefined in GHC.Maybe Methodscompare :: Maybe a -> Maybe a -> Ordering #(<) :: Maybe a -> Maybe a -> Bool #(<=) :: Maybe a -> Maybe a -> Bool #(>) :: Maybe a -> Maybe a -> Bool #(>=) :: Maybe a -> Maybe a -> Bool #max :: Maybe a -> Maybe a -> Maybe a #min :: Maybe a -> Maybe a -> Maybe a # Integral a => Ord (Ratio a) Source # Since: 2.0.1 Instance detailsDefined in GHC.Real Methodscompare :: Ratio a -> Ratio a -> Ordering #(<) :: Ratio a -> Ratio a -> Bool #(<=) :: Ratio a -> Ratio a -> Bool #(>) :: Ratio a -> Ratio a -> Bool #(>=) :: Ratio a -> Ratio a -> Bool #max :: Ratio a -> Ratio a -> Ratio a #min :: Ratio a -> Ratio a -> Ratio a # Ord (Ptr a) Source # Since: 2.1 Instance detailsDefined in GHC.Ptr Methodscompare :: Ptr a -> Ptr a -> Ordering #(<) :: Ptr a -> Ptr a -> Bool #(<=) :: Ptr a -> Ptr a -> Bool #(>) :: Ptr a -> Ptr a -> Bool #(>=) :: Ptr a -> Ptr a -> Bool #max :: Ptr a -> Ptr a -> Ptr a #min :: Ptr a -> Ptr a -> Ptr a # Ord (FunPtr a) Source # Instance detailsDefined in GHC.Ptr Methodscompare :: FunPtr a -> FunPtr a -> Ordering #(<) :: FunPtr a -> FunPtr a -> Bool #(<=) :: FunPtr a -> FunPtr a -> Bool #(>) :: FunPtr a -> FunPtr a -> Bool #(>=) :: FunPtr a -> FunPtr a -> Bool #max :: FunPtr a -> FunPtr a -> FunPtr a #min :: FunPtr a -> FunPtr a -> FunPtr a # Ord p => Ord (Par1 p) Source # Since: 4.7.0.0 Instance detailsDefined in GHC.Generics Methodscompare :: Par1 p -> Par1 p -> Ordering #(<) :: Par1 p -> Par1 p -> Bool #(<=) :: Par1 p -> Par1 p -> Bool #(>) :: Par1 p -> Par1 p -> Bool #(>=) :: Par1 p -> Par1 p -> Bool #max :: Par1 p -> Par1 p -> Par1 p #min :: Par1 p -> Par1 p -> Par1 p # Ord a => Ord (NonEmpty a) Source # Since: 4.9.0.0 Instance detailsDefined in GHC.Base Methodscompare :: NonEmpty a -> NonEmpty a -> Ordering #(<) :: NonEmpty a -> NonEmpty a -> Bool #(<=) :: NonEmpty a -> NonEmpty a -> Bool #(>) :: NonEmpty a -> NonEmpty a -> Bool #(>=) :: NonEmpty a -> NonEmpty a -> Bool #max :: NonEmpty a -> NonEmpty a -> NonEmpty a #min :: NonEmpty a -> NonEmpty a -> NonEmpty a # Ord a => Ord (Down a) Source # Since: 4.6.0.0 Instance detailsDefined in Data.Ord Methodscompare :: Down a -> Down a -> Ordering #(<) :: Down a -> Down a -> Bool #(<=) :: Down a -> Down a -> Bool #(>) :: Down a -> Down a -> Bool #(>=) :: Down a -> Down a -> Bool #max :: Down a -> Down a -> Down a #min :: Down a -> Down a -> Down a # Ord a => Ord (Product a) Source # Since: 2.1 Instance detailsDefined in Data.Semigroup.Internal Methodscompare :: Product a -> Product a -> Ordering #(<) :: Product a -> Product a -> Bool #(<=) :: Product a -> Product a -> Bool #(>) :: Product a -> Product a -> Bool #(>=) :: Product a -> Product a -> Bool #max :: Product a -> Product a -> Product a #min :: Product a -> Product a -> Product a # Ord a => Ord (Sum a) Source # Since: 2.1 Instance detailsDefined in Data.Semigroup.Internal Methodscompare :: Sum a -> Sum a -> Ordering #(<) :: Sum a -> Sum a -> Bool #(<=) :: Sum a -> Sum a -> Bool #(>) :: Sum a -> Sum a -> Bool #(>=) :: Sum a -> Sum a -> Bool #max :: Sum a -> Sum a -> Sum a #min :: Sum a -> Sum a -> Sum a # Ord a => Ord (Dual a) Source # Since: 2.1 Instance detailsDefined in Data.Semigroup.Internal Methodscompare :: Dual a -> Dual a -> Ordering #(<) :: Dual a -> Dual a -> Bool #(<=) :: Dual a -> Dual a -> Bool #(>) :: Dual a -> Dual a -> Bool #(>=) :: Dual a -> Dual a -> Bool #max :: Dual a -> Dual a -> Dual a #min :: Dual a -> Dual a -> Dual a # Ord a => Ord (Last a) Source # Since: 2.1 Instance detailsDefined in Data.Monoid Methodscompare :: Last a -> Last a -> Ordering #(<) :: Last a -> Last a -> Bool #(<=) :: Last a -> Last a -> Bool #(>) :: Last a -> Last a -> Bool #(>=) :: Last a -> Last a -> Bool #max :: Last a -> Last a -> Last a #min :: Last a -> Last a -> Last a # Ord a => Ord (First a) Source # Since: 2.1 Instance detailsDefined in Data.Monoid Methodscompare :: First a -> First a -> Ordering #(<) :: First a -> First a -> Bool #(<=) :: First a -> First a -> Bool #(>) :: First a -> First a -> Bool #(>=) :: First a -> First a -> Bool #max :: First a -> First a -> First a #min :: First a -> First a -> First a # Source # Since: 2.1 Instance detailsDefined in GHC.ForeignPtr Methodscompare :: ForeignPtr a -> ForeignPtr a -> Ordering #(<) :: ForeignPtr a -> ForeignPtr a -> Bool #(<=) :: ForeignPtr a -> ForeignPtr a -> Bool #(>) :: ForeignPtr a -> ForeignPtr a -> Bool #(>=) :: ForeignPtr a -> ForeignPtr a -> Bool #max :: ForeignPtr a -> ForeignPtr a -> ForeignPtr a #min :: ForeignPtr a -> ForeignPtr a -> ForeignPtr a # Ord a => Ord (Identity a) Source # Since: 4.8.0.0 Instance detailsDefined in Data.Functor.Identity Methodscompare :: Identity a -> Identity a -> Ordering #(<) :: Identity a -> Identity a -> Bool #(<=) :: Identity a -> Identity a -> Bool #(>) :: Identity a -> Identity a -> Bool #(>=) :: Identity a -> Identity a -> Bool #max :: Identity a -> Identity a -> Identity a #min :: Identity a -> Identity a -> Identity a # Ord a => Ord (ZipList a) Source # Since: 4.7.0.0 Instance detailsDefined in Control.Applicative Methodscompare :: ZipList a -> ZipList a -> Ordering #(<) :: ZipList a -> ZipList a -> Bool #(<=) :: ZipList a -> ZipList a -> Bool #(>) :: ZipList a -> ZipList a -> Bool #(>=) :: ZipList a -> ZipList a -> Bool #max :: ZipList a -> ZipList a -> ZipList a #min :: ZipList a -> ZipList a -> ZipList a # Ord a => Ord (Option a) Source # Since: 4.9.0.0 Instance detailsDefined in Data.Semigroup Methodscompare :: Option a -> Option a -> Ordering #(<) :: Option a -> Option a -> Bool #(<=) :: Option a -> Option a -> Bool #(>) :: Option a -> Option a -> Bool #(>=) :: Option a -> Option a -> Bool #max :: Option a -> Option a -> Option a #min :: Option a -> Option a -> Option a # Ord m => Ord (WrappedMonoid m) Source # Since: 4.9.0.0 Instance detailsDefined in Data.Semigroup Methods(<) :: WrappedMonoid m -> WrappedMonoid m -> Bool #(<=) :: WrappedMonoid m -> WrappedMonoid m -> Bool #(>) :: WrappedMonoid m -> WrappedMonoid m -> Bool #(>=) :: WrappedMonoid m -> WrappedMonoid m -> Bool #max :: WrappedMonoid m -> WrappedMonoid m -> WrappedMonoid m #min :: WrappedMonoid m -> WrappedMonoid m -> WrappedMonoid m # Ord a => Ord (Last a) Source # Since: 4.9.0.0 Instance detailsDefined in Data.Semigroup Methodscompare :: Last a -> Last a -> Ordering #(<) :: Last a -> Last a -> Bool #(<=) :: Last a -> Last a -> Bool #(>) :: Last a -> Last a -> Bool #(>=) :: Last a -> Last a -> Bool #max :: Last a -> Last a -> Last a #min :: Last a -> Last a -> Last a # Ord a => Ord (First a) Source # Since: 4.9.0.0 Instance detailsDefined in Data.Semigroup Methodscompare :: First a -> First a -> Ordering #(<) :: First a -> First a -> Bool #(<=) :: First a -> First a -> Bool #(>) :: First a -> First a -> Bool #(>=) :: First a -> First a -> Bool #max :: First a -> First a -> First a #min :: First a -> First a -> First a # Ord a => Ord (Max a) Source # Since: 4.9.0.0 Instance detailsDefined in Data.Semigroup Methodscompare :: Max a -> Max a -> Ordering #(<) :: Max a -> Max a -> Bool #(<=) :: Max a -> Max a -> Bool #(>) :: Max a -> Max a -> Bool #(>=) :: Max a -> Max a -> Bool #max :: Max a -> Max a -> Max a #min :: Max a -> Max a -> Max a # Ord a => Ord (Min a) Source # Since: 4.9.0.0 Instance detailsDefined in Data.Semigroup Methodscompare :: Min a -> Min a -> Ordering #(<) :: Min a -> Min a -> Bool #(<=) :: Min a -> Min a -> Bool #(>) :: Min a -> Min a -> Bool #(>=) :: Min a -> Min a -> Bool #max :: Min a -> Min a -> Min a #min :: Min a -> Min a -> Min a # (Ord a, Ord b) => Ord (Either a b) Source # Since: 2.1 Instance detailsDefined in Data.Either Methodscompare :: Either a b -> Either a b -> Ordering #(<) :: Either a b -> Either a b -> Bool #(<=) :: Either a b -> Either a b -> Bool #(>) :: Either a b -> Either a b -> Bool #(>=) :: Either a b -> Either a b -> Bool #max :: Either a b -> Either a b -> Either a b #min :: Either a b -> Either a b -> Either a b # Ord (V1 p) Source # Since: 4.9.0.0 Instance detailsDefined in GHC.Generics Methodscompare :: V1 p -> V1 p -> Ordering #(<) :: V1 p -> V1 p -> Bool #(<=) :: V1 p -> V1 p -> Bool #(>) :: V1 p -> V1 p -> Bool #(>=) :: V1 p -> V1 p -> Bool #max :: V1 p -> V1 p -> V1 p #min :: V1 p -> V1 p -> V1 p # Ord (U1 p) Source # Since: 4.7.0.0 Instance detailsDefined in GHC.Generics Methodscompare :: U1 p -> U1 p -> Ordering #(<) :: U1 p -> U1 p -> Bool #(<=) :: U1 p -> U1 p -> Bool #(>) :: U1 p -> U1 p -> Bool #(>=) :: U1 p -> U1 p -> Bool #max :: U1 p -> U1 p -> U1 p #min :: U1 p -> U1 p -> U1 p # Ord (TypeRep a) Source # Since: 4.4.0.0 Instance detailsDefined in Data.Typeable.Internal Methodscompare :: TypeRep a -> TypeRep a -> Ordering #(<) :: TypeRep a -> TypeRep a -> Bool #(<=) :: TypeRep a -> TypeRep a -> Bool #(>) :: TypeRep a -> TypeRep a -> Bool #(>=) :: TypeRep a -> TypeRep a -> Bool #max :: TypeRep a -> TypeRep a -> TypeRep a #min :: TypeRep a -> TypeRep a -> TypeRep a # (Ord a, Ord b) => Ord (a, b) Instance detailsDefined in GHC.Classes Methodscompare :: (a, b) -> (a, b) -> Ordering #(<) :: (a, b) -> (a, b) -> Bool #(<=) :: (a, b) -> (a, b) -> Bool #(>) :: (a, b) -> (a, b) -> Bool #(>=) :: (a, b) -> (a, b) -> Bool #max :: (a, b) -> (a, b) -> (a, b) #min :: (a, b) -> (a, b) -> (a, b) # (Ix i, Ord e) => Ord (Array i e) Source # Since: 2.1 Instance detailsDefined in GHC.Arr Methodscompare :: Array i e -> Array i e -> Ordering #(<) :: Array i e -> Array i e -> Bool #(<=) :: Array i e -> Array i e -> Bool #(>) :: Array i e -> Array i e -> Bool #(>=) :: Array i e -> Array i e -> Bool #max :: Array i e -> Array i e -> Array i e #min :: Array i e -> Array i e -> Array i e # Ord (Proxy s) Source # Since: 4.7.0.0 Instance detailsDefined in Data.Proxy Methodscompare :: Proxy s -> Proxy s -> Ordering #(<) :: Proxy s -> Proxy s -> Bool #(<=) :: Proxy s -> Proxy s -> Bool #(>) :: Proxy s -> Proxy s -> Bool #(>=) :: Proxy s -> Proxy s -> Bool #max :: Proxy s -> Proxy s -> Proxy s #min :: Proxy s -> Proxy s -> Proxy s # Ord a => Ord (Arg a b) Source # Since: 4.9.0.0 Instance detailsDefined in Data.Semigroup Methodscompare :: Arg a b -> Arg a b -> Ordering #(<) :: Arg a b -> Arg a b -> Bool #(<=) :: Arg a b -> Arg a b -> Bool #(>) :: Arg a b -> Arg a b -> Bool #(>=) :: Arg a b -> Arg a b -> Bool #max :: Arg a b -> Arg a b -> Arg a b #min :: Arg a b -> Arg a b -> Arg a b # Ord (Fixed a) Source # Since: 2.1 Instance detailsDefined in Data.Fixed Methodscompare :: Fixed a -> Fixed a -> Ordering #(<) :: Fixed a -> Fixed a -> Bool #(<=) :: Fixed a -> Fixed a -> Bool #(>) :: Fixed a -> Fixed a -> Bool #(>=) :: Fixed a -> Fixed a -> Bool #max :: Fixed a -> Fixed a -> Fixed a #min :: Fixed a -> Fixed a -> Fixed a # Ord (f p) => Ord (Rec1 f p) Source # Since: 4.7.0.0 Instance detailsDefined in GHC.Generics Methodscompare :: Rec1 f p -> Rec1 f p -> Ordering #(<) :: Rec1 f p -> Rec1 f p -> Bool #(<=) :: Rec1 f p -> Rec1 f p -> Bool #(>) :: Rec1 f p -> Rec1 f p -> Bool #(>=) :: Rec1 f p -> Rec1 f p -> Bool #max :: Rec1 f p -> Rec1 f p -> Rec1 f p #min :: Rec1 f p -> Rec1 f p -> Rec1 f p # Ord (URec Word p) Source # Since: 4.9.0.0 Instance detailsDefined in GHC.Generics Methodscompare :: URec Word p -> URec Word p -> Ordering #(<) :: URec Word p -> URec Word p -> Bool #(<=) :: URec Word p -> URec Word p -> Bool #(>) :: URec Word p -> URec Word p -> Bool #(>=) :: URec Word p -> URec Word p -> Bool #max :: URec Word p -> URec Word p -> URec Word p #min :: URec Word p -> URec Word p -> URec Word p # Ord (URec Int p) Source # Since: 4.9.0.0 Instance detailsDefined in GHC.Generics Methodscompare :: URec Int p -> URec Int p -> Ordering #(<) :: URec Int p -> URec Int p -> Bool #(<=) :: URec Int p -> URec Int p -> Bool #(>) :: URec Int p -> URec Int p -> Bool #(>=) :: URec Int p -> URec Int p -> Bool #max :: URec Int p -> URec Int p -> URec Int p #min :: URec Int p -> URec Int p -> URec Int p # Ord (URec Float p) Source # Instance detailsDefined in GHC.Generics Methodscompare :: URec Float p -> URec Float p -> Ordering #(<) :: URec Float p -> URec Float p -> Bool #(<=) :: URec Float p -> URec Float p -> Bool #(>) :: URec Float p -> URec Float p -> Bool #(>=) :: URec Float p -> URec Float p -> Bool #max :: URec Float p -> URec Float p -> URec Float p #min :: URec Float p -> URec Float p -> URec Float p # Source # Since: 4.9.0.0 Instance detailsDefined in GHC.Generics Methodscompare :: URec Double p -> URec Double p -> Ordering #(<) :: URec Double p -> URec Double p -> Bool #(<=) :: URec Double p -> URec Double p -> Bool #(>) :: URec Double p -> URec Double p -> Bool #(>=) :: URec Double p -> URec Double p -> Bool #max :: URec Double p -> URec Double p -> URec Double p #min :: URec Double p -> URec Double p -> URec Double p # Ord (URec Char p) Source # Since: 4.9.0.0 Instance detailsDefined in GHC.Generics Methodscompare :: URec Char p -> URec Char p -> Ordering #(<) :: URec Char p -> URec Char p -> Bool #(<=) :: URec Char p -> URec Char p -> Bool #(>) :: URec Char p -> URec Char p -> Bool #(>=) :: URec Char p -> URec Char p -> Bool #max :: URec Char p -> URec Char p -> URec Char p #min :: URec Char p -> URec Char p -> URec Char p # Ord (URec (Ptr ()) p) Source # Since: 4.9.0.0 Instance detailsDefined in GHC.Generics Methodscompare :: URec (Ptr ()) p -> URec (Ptr ()) p -> Ordering #(<) :: URec (Ptr ()) p -> URec (Ptr ()) p -> Bool #(<=) :: URec (Ptr ()) p -> URec (Ptr ()) p -> Bool #(>) :: URec (Ptr ()) p -> URec (Ptr ()) p -> Bool #(>=) :: URec (Ptr ()) p -> URec (Ptr ()) p -> Bool #max :: URec (Ptr ()) p -> URec (Ptr ()) p -> URec (Ptr ()) p #min :: URec (Ptr ()) p -> URec (Ptr ()) p -> URec (Ptr ()) p # (Ord a, Ord b, Ord c) => Ord (a, b, c) Instance detailsDefined in GHC.Classes Methodscompare :: (a, b, c) -> (a, b, c) -> Ordering #(<) :: (a, b, c) -> (a, b, c) -> Bool #(<=) :: (a, b, c) -> (a, b, c) -> Bool #(>) :: (a, b, c) -> (a, b, c) -> Bool #(>=) :: (a, b, c) -> (a, b, c) -> Bool #max :: (a, b, c) -> (a, b, c) -> (a, b, c) #min :: (a, b, c) -> (a, b, c) -> (a, b, c) # Ord (a :~: b) Source # Since: 4.7.0.0 Instance detailsDefined in Data.Type.Equality Methodscompare :: (a :~: b) -> (a :~: b) -> Ordering #(<) :: (a :~: b) -> (a :~: b) -> Bool #(<=) :: (a :~: b) -> (a :~: b) -> Bool #(>) :: (a :~: b) -> (a :~: b) -> Bool #(>=) :: (a :~: b) -> (a :~: b) -> Bool #max :: (a :~: b) -> (a :~: b) -> a :~: b #min :: (a :~: b) -> (a :~: b) -> a :~: b # Ord (Coercion a b) Source # Since: 4.7.0.0 Instance detailsDefined in Data.Type.Coercion Methodscompare :: Coercion a b -> Coercion a b -> Ordering #(<) :: Coercion a b -> Coercion a b -> Bool #(<=) :: Coercion a b -> Coercion a b -> Bool #(>) :: Coercion a b -> Coercion a b -> Bool #(>=) :: Coercion a b -> Coercion a b -> Bool #max :: Coercion a b -> Coercion a b -> Coercion a b #min :: Coercion a b -> Coercion a b -> Coercion a b # Ord (f a) => Ord (Alt f a) Source # Since: 4.8.0.0 Instance detailsDefined in Data.Semigroup.Internal Methodscompare :: Alt f a -> Alt f a -> Ordering #(<) :: Alt f a -> Alt f a -> Bool #(<=) :: Alt f a -> Alt f a -> Bool #(>) :: Alt f a -> Alt f a -> Bool #(>=) :: Alt f a -> Alt f a -> Bool #max :: Alt f a -> Alt f a -> Alt f a #min :: Alt f a -> Alt f a -> Alt f a # Ord (f a) => Ord (Ap f a) Source # Since: 4.12.0.0 Instance detailsDefined in Data.Monoid Methodscompare :: Ap f a -> Ap f a -> Ordering #(<) :: Ap f a -> Ap f a -> Bool #(<=) :: Ap f a -> Ap f a -> Bool #(>) :: Ap f a -> Ap f a -> Bool #(>=) :: Ap f a -> Ap f a -> Bool #max :: Ap f a -> Ap f a -> Ap f a #min :: Ap f a -> Ap f a -> Ap f a # Ord a => Ord (Const a b) Source # Since: 4.9.0.0 Instance detailsDefined in Data.Functor.Const Methodscompare :: Const a b -> Const a b -> Ordering #(<) :: Const a b -> Const a b -> Bool #(<=) :: Const a b -> Const a b -> Bool #(>) :: Const a b -> Const a b -> Bool #(>=) :: Const a b -> Const a b -> Bool #max :: Const a b -> Const a b -> Const a b #min :: Const a b -> Const a b -> Const a b # Ord c => Ord (K1 i c p) Source # Since: 4.7.0.0 Instance detailsDefined in GHC.Generics Methodscompare :: K1 i c p -> K1 i c p -> Ordering #(<) :: K1 i c p -> K1 i c p -> Bool #(<=) :: K1 i c p -> K1 i c p -> Bool #(>) :: K1 i c p -> K1 i c p -> Bool #(>=) :: K1 i c p -> K1 i c p -> Bool #max :: K1 i c p -> K1 i c p -> K1 i c p #min :: K1 i c p -> K1 i c p -> K1 i c p # (Ord (f p), Ord (g p)) => Ord ((f :+: g) p) Source # Since: 4.7.0.0 Instance detailsDefined in GHC.Generics Methodscompare :: (f :+: g) p -> (f :+: g) p -> Ordering #(<) :: (f :+: g) p -> (f :+: g) p -> Bool #(<=) :: (f :+: g) p -> (f :+: g) p -> Bool #(>) :: (f :+: g) p -> (f :+: g) p -> Bool #(>=) :: (f :+: g) p -> (f :+: g) p -> Bool #max :: (f :+: g) p -> (f :+: g) p -> (f :+: g) p #min :: (f :+: g) p -> (f :+: g) p -> (f :+: g) p # (Ord (f p), Ord (g p)) => Ord ((f :*: g) p) Source # Since: 4.7.0.0 Instance detailsDefined in GHC.Generics Methodscompare :: (f :*: g) p -> (f :*: g) p -> Ordering #(<) :: (f :*: g) p -> (f :*: g) p -> Bool #(<=) :: (f :*: g) p -> (f :*: g) p -> Bool #(>) :: (f :*: g) p -> (f :*: g) p -> Bool #(>=) :: (f :*: g) p -> (f :*: g) p -> Bool #max :: (f :*: g) p -> (f :*: g) p -> (f :*: g) p #min :: (f :*: g) p -> (f :*: g) p -> (f :*: g) p # (Ord a, Ord b, Ord c, Ord d) => Ord (a, b, c, d) Instance detailsDefined in GHC.Classes Methodscompare :: (a, b, c, d) -> (a, b, c, d) -> Ordering #(<) :: (a, b, c, d) -> (a, b, c, d) -> Bool #(<=) :: (a, b, c, d) -> (a, b, c, d) -> Bool #(>) :: (a, b, c, d) -> (a, b, c, d) -> Bool #(>=) :: (a, b, c, d) -> (a, b, c, d) -> Bool #max :: (a, b, c, d) -> (a, b, c, d) -> (a, b, c, d) #min :: (a, b, c, d) -> (a, b, c, d) -> (a, b, c, d) # Ord (a :~~: b) Source # Since: 4.10.0.0 Instance detailsDefined in Data.Type.Equality Methodscompare :: (a :~~: b) -> (a :~~: b) -> Ordering #(<) :: (a :~~: b) -> (a :~~: b) -> Bool #(<=) :: (a :~~: b) -> (a :~~: b) -> Bool #(>) :: (a :~~: b) -> (a :~~: b) -> Bool #(>=) :: (a :~~: b) -> (a :~~: b) -> Bool #max :: (a :~~: b) -> (a :~~: b) -> a :~~: b #min :: (a :~~: b) -> (a :~~: b) -> a :~~: b # (Ord1 f, Ord1 g, Ord a) => Ord (Sum f g a) Source # Since: 4.9.0.0 Instance detailsDefined in Data.Functor.Sum Methodscompare :: Sum f g a -> Sum f g a -> Ordering #(<) :: Sum f g a -> Sum f g a -> Bool #(<=) :: Sum f g a -> Sum f g a -> Bool #(>) :: Sum f g a -> Sum f g a -> Bool #(>=) :: Sum f g a -> Sum f g a -> Bool #max :: Sum f g a -> Sum f g a -> Sum f g a #min :: Sum f g a -> Sum f g a -> Sum f g a # (Ord1 f, Ord1 g, Ord a) => Ord (Product f g a) Source # Since: 4.9.0.0 Instance detailsDefined in Data.Functor.Product Methodscompare :: Product f g a -> Product f g a -> Ordering #(<) :: Product f g a -> Product f g a -> Bool #(<=) :: Product f g a -> Product f g a -> Bool #(>) :: Product f g a -> Product f g a -> Bool #(>=) :: Product f g a -> Product f g a -> Bool #max :: Product f g a -> Product f g a -> Product f g a #min :: Product f g a -> Product f g a -> Product f g a # Ord (f p) => Ord (M1 i c f p) Source # Since: 4.7.0.0 Instance detailsDefined in GHC.Generics Methodscompare :: M1 i c f p -> M1 i c f p -> Ordering #(<) :: M1 i c f p -> M1 i c f p -> Bool #(<=) :: M1 i c f p -> M1 i c f p -> Bool #(>) :: M1 i c f p -> M1 i c f p -> Bool #(>=) :: M1 i c f p -> M1 i c f p -> Bool #max :: M1 i c f p -> M1 i c f p -> M1 i c f p #min :: M1 i c f p -> M1 i c f p -> M1 i c f p # Ord (f (g p)) => Ord ((f :.: g) p) Source # Since: 4.7.0.0 Instance detailsDefined in GHC.Generics Methodscompare :: (f :.: g) p -> (f :.: g) p -> Ordering #(<) :: (f :.: g) p -> (f :.: g) p -> Bool #(<=) :: (f :.: g) p -> (f :.: g) p -> Bool #(>) :: (f :.: g) p -> (f :.: g) p -> Bool #(>=) :: (f :.: g) p -> (f :.: g) p -> Bool #max :: (f :.: g) p -> (f :.: g) p -> (f :.: g) p #min :: (f :.: g) p -> (f :.: g) p -> (f :.: g) p # (Ord a, Ord b, Ord c, Ord d, Ord e) => Ord (a, b, c, d, e) Instance detailsDefined in GHC.Classes Methodscompare :: (a, b, c, d, e) -> (a, b, c, d, e) -> Ordering #(<) :: (a, b, c, d, e) -> (a, b, c, d, e) -> Bool #(<=) :: (a, b, c, d, e) -> (a, b, c, d, e) -> Bool #(>) :: (a, b, c, d, e) -> (a, b, c, d, e) -> Bool #(>=) :: (a, b, c, d, e) -> (a, b, c, d, e) -> Bool #max :: (a, b, c, d, e) -> (a, b, c, d, e) -> (a, b, c, d, e) #min :: (a, b, c, d, e) -> (a, b, c, d, e) -> (a, b, c, d, e) # (Ord1 f, Ord1 g, Ord a) => Ord (Compose f g a) Source # Since: 4.9.0.0 Instance detailsDefined in Data.Functor.Compose Methodscompare :: Compose f g a -> Compose f g a -> Ordering #(<) :: Compose f g a -> Compose f g a -> Bool #(<=) :: Compose f g a -> Compose f g a -> Bool #(>) :: Compose f g a -> Compose f g a -> Bool #(>=) :: Compose f g a -> Compose f g a -> Bool #max :: Compose f g a -> Compose f g a -> Compose f g a #min :: Compose f g a -> Compose f g a -> Compose f g a # (Ord a, Ord b, Ord c, Ord d, Ord e, Ord f) => Ord (a, b, c, d, e, f) Instance detailsDefined in GHC.Classes Methodscompare :: (a, b, c, d, e, f) -> (a, b, c, d, e, f) -> Ordering #(<) :: (a, b, c, d, e, f) -> (a, b, c, d, e, f) -> Bool #(<=) :: (a, b, c, d, e, f) -> (a, b, c, d, e, f) -> Bool #(>) :: (a, b, c, d, e, f) -> (a, b, c, d, e, f) -> Bool #(>=) :: (a, b, c, d, e, f) -> (a, b, c, d, e, f) -> Bool #max :: (a, b, c, d, e, f) -> (a, b, c, d, e, f) -> (a, b, c, d, e, f) #min :: (a, b, c, d, e, f) -> (a, b, c, d, e, f) -> (a, b, c, d, e, f) # (Ord a, Ord b, Ord c, Ord d, Ord e, Ord f, Ord g) => Ord (a, b, c, d, e, f, g) Instance detailsDefined in GHC.Classes Methodscompare :: (a, b, c, d, e, f, g) -> (a, b, c, d, e, f, g) -> Ordering #(<) :: (a, b, c, d, e, f, g) -> (a, b, c, d, e, f, g) -> Bool #(<=) :: (a, b, c, d, e, f, g) -> (a, b, c, d, e, f, g) -> Bool #(>) :: (a, b, c, d, e, f, g) -> (a, b, c, d, e, f, g) -> Bool #(>=) :: (a, b, c, d, e, f, g) -> (a, b, c, d, e, f, g) -> Bool #max :: (a, b, c, d, e, f, g) -> (a, b, c, d, e, f, g) -> (a, b, c, d, e, f, g) #min :: (a, b, c, d, e, f, g) -> (a, b, c, d, e, f, g) -> (a, b, c, d, e, f, g) # (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) Instance detailsDefined in GHC.Classes Methodscompare :: (a, b, c, d, e, f, g, h) -> (a, b, c, d, e, f, g, h) -> Ordering #(<) :: (a, b, c, d, e, f, g, h) -> (a, b, c, d, e, f, g, h) -> Bool #(<=) :: (a, b, c, d, e, f, g, h) -> (a, b, c, d, e, f, g, h) -> Bool #(>) :: (a, b, c, d, e, f, g, h) -> (a, b, c, d, e, f, g, h) -> Bool #(>=) :: (a, b, c, d, e, f, g, h) -> (a, b, c, d, e, f, g, h) -> Bool #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) #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) # (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) 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 #(<) :: (a, b, c, d, e, f, g, h, i) -> (a, b, c, d, e, f, g, h, i) -> Bool #(<=) :: (a, b, c, d, e, f, g, h, i) -> (a, b, c, d, e, f, g, h, i) -> Bool #(>) :: (a, b, c, d, e, f, g, h, i) -> (a, b, c, d, e, f, g, h, i) -> Bool #(>=) :: (a, b, c, d, e, f, g, h, i) -> (a, b, c, d, e, f, g, h, i) -> Bool #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) #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) # (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) 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 #(<) :: (a, b, c, d, e, f, g, h, i, j) -> (a, b, c, d, e, f, g, h, i, j) -> Bool #(<=) :: (a, b, c, d, e, f, g, h, i, j) -> (a, b, c, d, e, f, g, h, i, j) -> Bool #(>) :: (a, b, c, d, e, f, g, h, i, j) -> (a, b, c, d, e, f, g, h, i, j) -> Bool #(>=) :: (a, b, c, d, e, f, g, h, i, j) -> (a, b, c, d, e, f, g, h, i, j) -> Bool #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) #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) # (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) 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 #(<) :: (a, b, c, d, e, f, g, h, i, j, k) -> (a, b, c, d, e, f, g, h, i, j, k) -> Bool #(<=) :: (a, b, c, d, e, f, g, h, i, j, k) -> (a, b, c, d, e, f, g, h, i, j, k) -> Bool #(>) :: (a, b, c, d, e, f, g, h, i, j, k) -> (a, b, c, d, e, f, g, h, i, j, k) -> Bool #(>=) :: (a, b, c, d, e, f, g, h, i, j, k) -> (a, b, c, d, e, f, g, h, i, j, k) -> Bool #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) #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) # (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) 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 #(<) :: (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 #(<=) :: (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 #(>) :: (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 #(>=) :: (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 #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) #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) # (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) 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 #(<) :: (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 #(<=) :: (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 #(>) :: (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 #(>=) :: (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 #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) #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) # (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) 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 #(<) :: (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 #(<=) :: (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 #(>) :: (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 #(>=) :: (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 #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) #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) # (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) 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 #(<) :: (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 #(<=) :: (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 #(>) :: (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 #(>=) :: (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 #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) #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) #

data Ordering #

Constructors

 LT EQ GT

#### Instances

Instances details
 Source # Since: 2.1 Instance detailsDefined in GHC.Enum Methods Source # Since: 2.1 Instance detailsDefined in GHC.Enum Methods Instance detailsDefined in GHC.Classes Methods Source # Since: 4.0.0.0 Instance detailsDefined in Data.Data Methodsgfoldl :: (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 # Instance detailsDefined in GHC.Classes Methods(<) :: Ordering -> Ordering -> Bool #(>) :: Ordering -> Ordering -> Bool # Source # Since: 2.1 Instance detailsDefined in GHC.Read Methods Source # Since: 2.1 Instance detailsDefined in GHC.Show MethodsshowList :: [Ordering] -> ShowS Source # Source # Since: 2.1 Instance detailsDefined in GHC.Ix Methodsrange :: (Ordering, Ordering) -> [Ordering] Source #index :: (Ordering, Ordering) -> Ordering -> Int Source #inRange :: (Ordering, Ordering) -> Ordering -> Bool Source #rangeSize :: (Ordering, Ordering) -> Int Source # Source # Since: 4.6.0.0 Instance detailsDefined in GHC.Generics Associated Typestype Rep Ordering :: Type -> Type Source # Methods Source # Since: 4.9.0.0 Instance detailsDefined in GHC.Base Methodsstimes :: Integral b => b -> Ordering -> Ordering Source # Source # Since: 2.1 Instance detailsDefined in GHC.Base Methodsmconcat :: [Ordering] -> Ordering Source # type Rep Ordering Source # Instance detailsDefined in GHC.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

Since: 4.6.0.0

Constructors

 Down FieldsgetDown :: aSince: 4.14.0.0

#### Instances

Instances details
 Source # Since: 4.11.0.0 Instance detailsDefined in 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: 4.11.0.0 Instance detailsDefined in Data.Ord Methodsfmap :: (a -> b) -> Down a -> Down b Source #(<\$) :: a -> Down b -> Down a Source # Source # Since: 4.12.0.0 Instance detailsDefined in Control.Monad.Fix Methodsmfix :: (a -> Down a) -> Down a Source # Source # Since: 4.11.0.0 Instance detailsDefined in Data.Ord Methodspure :: 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: 4.12.0.0 Instance detailsDefined in Data.Foldable Methodsfold :: 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: 4.12.0.0 Instance detailsDefined in Data.Traversable Methodstraverse :: 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 # Since: 4.12.0.0 Instance detailsDefined in Control.Monad.Zip Methodsmzip :: 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: 4.12.0.0 Instance detailsDefined in Data.Functor.Classes MethodsliftShowsPrec :: (Int -> a -> ShowS) -> ([a] -> ShowS) -> Int -> Down a -> ShowS Source #liftShowList :: (Int -> a -> ShowS) -> ([a] -> ShowS) -> [Down a] -> ShowS Source # Source # Since: 4.12.0.0 Instance detailsDefined in Data.Functor.Classes MethodsliftReadsPrec :: (Int -> ReadS a) -> ReadS [a] -> Int -> ReadS (Down a) Source #liftReadList :: (Int -> ReadS a) -> ReadS [a] -> ReadS [Down a] Source #liftReadPrec :: ReadPrec a -> ReadPrec [a] -> ReadPrec (Down a) Source #liftReadListPrec :: ReadPrec a -> ReadPrec [a] -> ReadPrec [Down a] Source # Source # Since: 4.12.0.0 Instance detailsDefined in Data.Functor.Classes MethodsliftCompare :: (a -> b -> Ordering) -> Down a -> Down b -> Ordering Source # Source # Since: 4.12.0.0 Instance detailsDefined in Data.Functor.Classes MethodsliftEq :: (a -> b -> Bool) -> Down a -> Down b -> Bool Source # Bounded a => Bounded (Down a) Source # Since: 4.14.0.0 Instance detailsDefined in Data.Ord Methods Enum a => Enum (Down a) Source # Since: 4.14.0.0 Instance detailsDefined in Data.Ord Methodssucc :: 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 # Eq a => Eq (Down a) Source # Since: 4.6.0.0 Instance detailsDefined in Data.Ord Methods(==) :: Down a -> Down a -> Bool #(/=) :: Down a -> Down a -> Bool # Floating a => Floating (Down a) Source # Since: 4.14.0.0 Instance detailsDefined in Data.Ord Methodsexp :: 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 Source #acos :: Down a -> Down a Source #atan :: Down a -> Down a Source #sinh :: Down a -> Down a Source #cosh :: Down a -> Down a Source #tanh :: Down a -> Down a Source #asinh :: Down a -> Down a Source #acosh :: Down a -> Down a Source #atanh :: Down a -> Down a Source #log1p :: Down a -> Down a Source #expm1 :: Down a -> Down a Source #log1pexp :: Down a -> Down a Source #log1mexp :: Down a -> Down a Source # Fractional a => Fractional (Down a) Source # Since: 4.14.0.0 Instance detailsDefined in Data.Ord Methods(/) :: Down a -> Down a -> Down a Source #recip :: Down a -> Down a Source # Integral a => Integral (Down a) Source # Since: 4.14.0.0 Instance detailsDefined in Data.Ord Methodsquot :: Down a -> Down a -> Down a Source #rem :: Down a -> Down a -> Down a Source #div :: Down a -> Down a -> Down a Source #mod :: Down a -> Down a -> Down a Source #quotRem :: Down a -> Down a -> (Down a, Down a) Source #divMod :: Down a -> Down a -> (Down a, Down a) Source # Data a => Data (Down a) Source # Since: 4.12.0.0 Instance detailsDefined in Data.Data Methodsgfoldl :: (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 # Num a => Num (Down a) Source # Since: 4.11.0.0 Instance detailsDefined in Data.Ord Methods(+) :: Down a -> Down a -> Down a Source #(-) :: Down a -> Down a -> Down a Source #(*) :: Down a -> Down a -> Down a Source #negate :: Down a -> Down a Source #abs :: Down a -> Down a Source #signum :: Down a -> Down a Source # Ord a => Ord (Down a) Source # Since: 4.6.0.0 Instance detailsDefined in Data.Ord Methodscompare :: Down a -> Down a -> Ordering #(<) :: Down a -> Down a -> Bool #(<=) :: Down a -> Down a -> Bool #(>) :: Down a -> Down a -> Bool #(>=) :: Down a -> Down a -> Bool #max :: Down a -> Down a -> Down a #min :: Down a -> Down a -> Down a # Read a => Read (Down a) Source # This instance would be equivalent to the derived instances of the Down newtype if the getDown field were removedSince: 4.7.0.0 Instance detailsDefined in Data.Ord MethodsreadsPrec :: Int -> ReadS (Down a) Source # Real a => Real (Down a) Source # Since: 4.14.0.0 Instance detailsDefined in Data.Ord Methods RealFloat a => RealFloat (Down a) Source # Since: 4.14.0.0 Instance detailsDefined in Data.Ord MethodsfloatRange :: Down a -> (Int, Int) Source #decodeFloat :: Down a -> (Integer, Int) Source #exponent :: Down a -> Int Source #significand :: Down a -> Down a Source #scaleFloat :: Int -> Down a -> Down a Source #isNaN :: Down a -> Bool Source #isIEEE :: Down a -> Bool Source #atan2 :: Down a -> Down a -> Down a Source # RealFrac a => RealFrac (Down a) Source # Since: 4.14.0.0 Instance detailsDefined in Data.Ord MethodsproperFraction :: Integral b => Down a -> (b, Down a) Source #truncate :: Integral b => Down a -> b Source #round :: Integral b => Down a -> b Source #ceiling :: Integral b => Down a -> b Source #floor :: Integral b => Down a -> b Source # Show a => Show (Down a) Source # This instance would be equivalent to the derived instances of the Down newtype if the getDown field were removedSince: 4.7.0.0 Instance detailsDefined in Data.Ord MethodsshowsPrec :: Int -> Down a -> ShowS Source #show :: Down a -> String Source #showList :: [Down a] -> ShowS Source # Ix a => Ix (Down a) Source # Since: 4.14.0.0 Instance detailsDefined in Data.Ord Methodsrange :: (Down a, Down a) -> [Down a] Source #index :: (Down a, Down a) -> Down a -> Int Source #unsafeIndex :: (Down a, Down a) -> Down a -> Int Source #inRange :: (Down a, Down a) -> Down a -> Bool Source #rangeSize :: (Down a, Down a) -> Int Source #unsafeRangeSize :: (Down a, Down a) -> Int Source # Generic (Down a) Source # Since: 4.12.0.0 Instance detailsDefined in GHC.Generics Associated Typestype Rep (Down a) :: Type -> Type Source # Methodsfrom :: Down a -> Rep (Down a) x Source #to :: Rep (Down a) x -> Down a Source # Semigroup a => Semigroup (Down a) Source # Since: 4.11.0.0 Instance detailsDefined in 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 # Monoid a => Monoid (Down a) Source # Since: 4.11.0.0 Instance detailsDefined in Data.Ord Methodsmappend :: Down a -> Down a -> Down a Source #mconcat :: [Down a] -> Down a Source # FiniteBits a => FiniteBits (Down a) Source # Since: 4.14.0.0 Instance detailsDefined in Data.Ord Methods Bits a => Bits (Down a) Source # Since: 4.14.0.0 Instance detailsDefined in 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 # Storable a => Storable (Down a) Source # Since: 4.14.0.0 Instance detailsDefined in Data.Ord MethodssizeOf :: Down a -> Int Source #alignment :: Down a -> Int Source #peekElemOff :: Ptr (Down a) -> Int -> IO (Down a) Source #pokeElemOff :: Ptr (Down a) -> Int -> Down a -> IO () Source #peekByteOff :: Ptr b -> Int -> IO (Down a) Source #pokeByteOff :: Ptr b -> Int -> Down a -> IO () Source #peek :: Ptr (Down a) -> IO (Down a) Source #poke :: Ptr (Down a) -> Down a -> IO () Source # Source # Since: 4.12.0.0 Instance detailsDefined in GHC.Generics Associated Typestype Rep1 Down :: k -> Type Source # Methodsfrom1 :: forall (a :: k). Down a -> Rep1 Down a Source #to1 :: forall (a :: k). Rep1 Down a -> Down a Source # type Rep (Down a) Source # Instance detailsDefined in GHC.Generics type Rep (Down a) = D1 ('MetaData "Down" "Data.Ord" "base" 'True) (C1 ('MetaCons "Down" 'PrefixI 'True) (S1 ('MetaSel ('Just "getDown") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 a))) type Rep1 Down Source # Instance detailsDefined in GHC.Generics type Rep1 Down = D1 ('MetaData "Down" "Data.Ord" "base" 'True) (C1 ('MetaCons "Down" 'PrefixI 'True) (S1 ('MetaSel ('Just "getDown") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) Par1))

comparing :: Ord a => (b -> a) -> b -> b -> Ordering Source #

comparing p x y = compare (p x) (p y)

Useful combinator for use in conjunction with the xxxBy family of functions from Data.List, for example:

  ... sortBy (comparing fst) ...