HORIZON HASKELLDocslts/ghc-10.0.xaa25b892026-10-10Search names, modules, packages, or :: a typeCtrl K

GHC 10.0.0.20260917 · lts/ghc-10.0.x · aa25b89 · 2026-10-10

Moduleghc-10.0.0.20260917GHC2024

GHC.Prelude.Basic

Custom minimal GHC Prelude

This module serves as a replacement for the Prelude module and abstracts over differences between the bootstrapping GHC version, and may also provide a common default vocabulary.

  • 17 types
  • 25 classes
  • 121 values
valuefoldl1 :: Foldable1 t => (a -> a -> a) -> t a -> a
#

A variant of foldlMap1 where the leftmost element maps to itself.

valuefoldlM1 :: (Foldable1 t, Monad m) => (a -> a -> m a) -> t a -> m a
#

Monadic fold over the elements of a non-empty structure, associating to the left, i.e. from left to right.

valuefoldr1 :: Foldable1 t => (a -> a -> a) -> t a -> a
#

A variant of foldrMap1 where the rightmost element maps to itself.

valuefoldrM1 :: (Foldable1 t, Monad m) => (a -> a -> m a) -> t a -> m a
#

Monadic fold over the elements of a non-empty structure, associating to the right, i.e. from right to left.

valueintercalate1 :: (Foldable1 t, Semigroup m) => m -> t m -> m
#

Insert an m between each pair of t m.

Example1 expression
intercalate1 ", " $ "hello" :| ["how", "are", "you"]"hello, how, are, you"
Example1 expression
intercalate1 ", " $ "hello" :| []"hello"
Example1 expression
intercalate1 mempty $ "I" :| ["Am", "Fine", "You?"]"IAmFineYou?"
valuemaximumBy :: Foldable1 t => (a -> a -> Ordering) -> t a -> a
#

The largest element of a non-empty structure with respect to the given comparison function. Structure order is used as a tie-breaker: if there are multiple largest elements, the rightmost of them is chosen.

valueminimumBy :: Foldable1 t => (a -> a -> Ordering) -> t a -> a
#

The least element of a non-empty structure with respect to the given comparison function. Structure order is used as a tie-breaker: if there are multiple least elements, the leftmost of them is chosen.

value($) :: (a -> b) -> a -> b
#

($) is the function application operator.

Applying ($) to a function f and an argument x gives the same result as applying f to x directly. The definition is akin to this:

($) :: (a -> b) -> a -> b
($) f x = f x

This is id specialized from a -> a to (a -> b) -> (a -> b) which by the associativity of (->) is the same as (a -> b) -> a -> b.

On the face of it, this may appear pointless! But it's actually one of the most useful and important operators in Haskell.

The order of operations is very different between ($) and normal function application. Normal function application has precedence 10 - higher than any operator - and associates to the left. So these two definitions are equivalent:

expr = min 5 1 + 5
expr = ((min 5) 1) + 5

($) has precedence 0 (the lowest) and associates to the right, so these are equivalent:

expr = min 5 $ 1 + 5
expr = (min 5) (1 + 5)
Examples

A common use cases of ($) is to avoid parentheses in complex expressions.

For example, instead of using nested parentheses in the following Haskell function:

-- | Sum numbers in a string: strSum "100  5 -7" == 98
strSum :: String -> Int
strSum s = sum (mapMaybe readMaybe (words s))

we can deploy the function application operator:

-- | Sum numbers in a string: strSum "100  5 -7" == 98
strSum :: String -> Int
strSum s = sum $ mapMaybe readMaybe $ words s

($) is also used as a section (a partially applied operator), in order to indicate that we wish to apply some yet-unspecified function to a given value. For example, to apply the argument 5 to a list of functions:

applyFive :: [Int]
applyFive = map ($ 5) [(+1), (2^)]
>>> [6, 32]
Technical Remark (Representation Polymorphism)

($) is fully representation-polymorphic. This allows it to also be used with arguments of unlifted and even unboxed kinds, such as unboxed integers:

fastMod :: Int -> Int -> Int
fastMod (I# x) (I# m) = I# $ remInt# x m
value($!) :: (a -> b) -> a -> b
#

Strict (call-by-value) application operator. It takes a function and an argument, evaluates the argument to weak head normal form (WHNF), then calls the function with that value.

value(++) :: [a] -> [a] -> [a]
#

(++) appends two lists, i.e.,

[x1, ..., xm] ++ [y1, ..., yn] == [x1, ..., xm, y1, ..., yn]
[x1, ..., xm] ++ [y1, ...] == [x1, ..., xm, y1, ...]

If the first list is not finite, the result is the first list.

Performance considerations

This function takes linear time in the number of elements of the first list. Thus it is better to associate repeated applications of (++) to the right (which is the default behaviour): xs ++ (ys ++ zs) or simply xs ++ ys ++ zs, but not (xs ++ ys) ++ zs. For the same reason GHC.Internal.Data.List.concat = GHC.Internal.Data.List.foldr (++) [] has linear performance, while GHC.Internal.Data.List.foldl (++) [] is prone to quadratic slowdown

Examples
Example1 expression
[1, 2, 3] ++ [4, 5, 6][1,2,3,4,5,6]
Example1 expression
[] ++ [1, 2, 3][1,2,3]
Example1 expression
[3, 2, 1] ++ [][3,2,1]
value(.) :: (b -> c) -> (a -> b) -> a -> c
#

Right to left function composition.

Property
(f . g) x = f (g x)
Property
f . id = f = id . f
Examples
Example1 expression
map ((*2) . length) [[], [0, 1, 2], [0]][0,6,2]
Example1 expression
foldr (.) id [(+1), (*3), (^3)] 225
Example1 expression
let (...) = (.).(.) in ((*2)...(+)) 5 1030
value(=<<) :: Monad m => (a -> m b) -> m a -> m b
#

Same as >>=, but with the arguments interchanged.

as >>= f == f =<< as
valueasTypeOf :: a -> a -> a
#

asTypeOf is a type-restricted version of const. It is usually used as an infix operator, and its typing forces its first argument (which is usually overloaded) to have the same type as the second.

valueconst :: a -> b -> a
#

const x y always evaluates to x, ignoring its second argument.

const x = \_ -> x

This function might seem useless at first glance, but it can be very useful in a higher order context.

Examples
Example1 expression
const 42 "hello"42
Example1 expression
map (const 42) [0..3][42,42,42,42]
valueflip :: (a -> b -> c) -> b -> a -> c
#

flip f takes its (first) two arguments in the reverse order of f.

Property
flip f x y = f y x
Property
flip . flip = id
Examples
Example1 expression
flip (++) "hello" "world""worldhello"
Example1 expression
let (.>) = flip (.) in (+1) .> show $ 5"6"
valueid :: a -> a
#

Identity function.

id x = x

This function might seem useless at first glance, but it can be very useful in a higher order context.

Examples
Example1 expression
length $ filter id [True, True, False, True]3
Example1 expression
Just (Just 3) >>= idJust 3
Example1 expression
foldr id 0 [(^3), (*5), (+2)]1000
valuemap :: (a -> b) -> [a] -> [b]
#

\mathcal{O}(n). map f xs is the list obtained by applying f to each element of xs, i.e.,

map f [x1, x2, ..., xn] == [f x1, f x2, ..., f xn]
map f [x1, x2, ...] == [f x1, f x2, ...]

this means that map id == id

Examples
Example1 expression
map (+1) [1, 2, 3][2,3,4]
Example1 expression
map id [1, 2, 3][1,2,3]
Example1 expression
map (\n -> 3 * n + 1) [1, 2, 3][4,7,10]
valueotherwise :: Bool
#

otherwise is defined as the value True. It helps to make guards more readable. eg.

 f x | x < 0     = ...
     | otherwise = ...
valueuntil :: (a -> Bool) -> (a -> a) -> a -> a
#

until p f yields the result of applying f until p holds.

value(&&) :: Bool -> Bool -> Bool
#

Boolean "and", lazy in the second argument

value(||) :: Bool -> Bool -> Bool
#

Boolean "or", lazy in the second argument

valueeither :: (a -> c) -> (b -> c) -> Either a b -> c
#

Case analysis for the Either type. If the value is Left a, apply the first function to a; if it is Right b, apply the second function to b.

Examples

We create two values of type Either String Int, one using the Left constructor and another using the Right constructor. Then we apply "either" the Prelude.length function (if we have a String) or the "times-two" function (if we have an Int):

Example4 expressions
let s = Left "foo" :: Either String Intlet n = Right 3 :: Either String Inteither length (*2) s3either length (*2) n6
valueall :: Foldable t => (a -> Bool) -> t a -> Bool
#

Determines whether all elements of the structure satisfy the predicate.

Examples

Basic usage:

Example1 expression
all (> 3) []True
Example1 expression
all (> 3) [1,2]False
Example1 expression
all (> 3) [1,2,3,4,5]False
Example1 expression
all (> 3) [1..]False
Example1 expression
all (> 3) [4..]* Hangs forever *
valueand :: Foldable t => t Bool -> Bool
#

and returns the conjunction of a container of Bools. For the result to be True, the container must be finite; False, however, results from a False value finitely far from the left end.

Examples

Basic usage:

Example1 expression
and []True
Example1 expression
and [True]True
Example1 expression
and [False]False
Example1 expression
and [True, True, False]False
Example1 expression
and (False : repeat True) -- Infinite list [False,True,True,True,...False
Example1 expression
and (repeat True)* Hangs forever *
valueany :: Foldable t => (a -> Bool) -> t a -> Bool
#

Determines whether any element of the structure satisfies the predicate.

Examples

Basic usage:

Example1 expression
any (> 3) []False
Example1 expression
any (> 3) [1,2]False
Example1 expression
any (> 3) [1,2,3,4,5]True
Example1 expression
any (> 3) [1..]True
Example1 expression
any (> 3) [0, -1..]* Hangs forever *
valueconcat :: Foldable t => t [a] -> [a]
#

The concatenation of all the elements of a container of lists.

Examples

Basic usage:

Example1 expression
concat (Just [1, 2, 3])[1,2,3]
Example1 expression
concat (Left 42)[]
Example1 expression
concat [[1, 2, 3], [4, 5], [6], []][1,2,3,4,5,6]
valueconcatMap :: Foldable t => (a -> [b]) -> t a -> [b]
#

Map a function over all the elements of a container and concatenate the resulting lists.

Examples

Basic usage:

Example1 expression
concatMap (take 3) [[1..], [10..], [100..], [1000..]][1,2,3,10,11,12,100,101,102,1000,1001,1002]
Example1 expression
concatMap (take 3) (Just [1..])[1,2,3]
valuemapM_ :: (Foldable t, Monad m) => (a -> m b) -> t a -> m ()
#

Map each element of a structure to a monadic action, evaluate these actions from left to right, and ignore the results. For a version that doesn't ignore the results see Data.Traversable.mapM.

mapM_ is just like traverse_, but specialised to monadic actions.

valuenotElem :: (Foldable t, Eq a) => a -> t a -> Bool
#

notElem is the negation of elem.

Examples

Basic usage:

Example1 expression
3 `notElem` []True
Example1 expression
3 `notElem` [1,2]True
Example1 expression
3 `notElem` [1,2,3,4,5]False

For infinite structures, notElem terminates if the value exists at a finite distance from the left side of the structure:

Example1 expression
3 `notElem` [1..]False
Example1 expression
3 `notElem` ([4..] ++ [3])* Hangs forever *
valueor :: Foldable t => t Bool -> Bool
#

or returns the disjunction of a container of Bools. For the result to be False, the container must be finite; True, however, results from a True value finitely far from the left end.

Examples

Basic usage:

Example1 expression
or []False
Example1 expression
or [True]True
Example1 expression
or [False]False
Example1 expression
or [True, True, False]True
Example1 expression
or (True : repeat False) -- Infinite list [True,False,False,False,...True
Example1 expression
or (repeat False)* Hangs forever *
valuesequence_ :: (Foldable t, Monad m) => t (m a) -> m ()
#

Evaluate each monadic action in the structure from left to right, and ignore the results. For a version that doesn't ignore the results see Data.Traversable.sequence.

sequence_ is just like sequenceA_, but specialised to monadic actions.

value(<$>) :: Functor f => (a -> b) -> f a -> f b
#

An infix synonym for fmap.

The name of this operator is an allusion to Prelude.$. Note the similarities between their types:

 ($)  ::              (a -> b) ->   a ->   b
(<$>) :: Functor f => (a -> b) -> f a -> f b

Whereas Prelude.$ is function application, <$> is function application lifted over a Functor.

Examples

Convert from a Maybe Int to a Maybe String using show:

Example1 expression
show <$> NothingNothing
Example1 expression
show <$> Just 3Just "3"

Convert from an Either Int Int to an Either Int String using show:

Example1 expression
show <$> Left 17Left 17
Example1 expression
show <$> Right 17Right "17"

Double each element of a list:

Example1 expression
(*2) <$> [1,2,3][2,4,6]

Apply even to the second element of a pair:

Example1 expression
even <$> (2,2)(2,True)
valuemaybe :: b -> (a -> b) -> Maybe a -> b
#

The maybe function takes a default value, a function, and a Maybe value. If the Maybe value is Nothing, the function returns the default value. Otherwise, it applies the function to the value inside the Just and returns the result.

Examples

Basic usage:

Example1 expression
maybe False odd (Just 3)True
Example1 expression
maybe False odd NothingFalse

Read an integer from a string using readMaybe. If we succeed, return twice the integer; that is, apply (*2) to it. If instead we fail to parse an integer, return 0 by default:

Example3 expressions
import GHC.Internal.Text.Read ( readMaybe )maybe 0 (*2) (readMaybe "5")10maybe 0 (*2) (readMaybe "")0

Apply show to a Maybe Int. If we have Just n, we want to show the underlying Int n. But if we have Nothing, we return the empty string instead of (for example) "Nothing":

Example2 expressions
maybe "" show (Just 5)"5"maybe "" show Nothing""
valuelines :: String -> [String]
#

Splits the argument into a list of lines stripped of their terminating \n characters. The \n terminator is optional in a final non-empty line of the argument string.

When the argument string is empty, or ends in a \n character, it can be recovered by passing the result of lines to the unlines function. Otherwise, unlines appends the missing terminating \n. This makes unlines . lines idempotent:

(unlines . lines) . (unlines . lines) = (unlines . lines)
Examples
Example1 expression
lines ""           -- empty input contains no lines[]
Example1 expression
lines "\n"         -- single empty line[""]
Example1 expression
lines "one"        -- single unterminated line["one"]
Example1 expression
lines "one\n"      -- single non-empty line["one"]
Example1 expression
lines "one\n\n"    -- second line is empty["one",""]
Example1 expression
lines "one\ntwo"   -- second line is unterminated["one","two"]
Example1 expression
lines "one\ntwo\n" -- two non-empty lines["one","two"]
valueunlines :: [String] -> String
#

Appends a \n character to each input string, then concatenates the results. Equivalent to foldMap (s -> s ++ "\n").

Examples
Example1 expression
unlines ["Hello", "World", "!"]"Hello\nWorld\n!\n"

Note that unlines . lines /= id when the input is not \n-terminated:

Example1 expression
unlines . lines $ "foo\nbar""foo\nbar\n"
valueunwords :: [String] -> String
#

unwords joins words with separating spaces (U+0020 SPACE).

unwords is neither left nor right inverse of words:

Example2 expressions
words (unwords [" "])[]unwords (words "foo\nbar")"foo bar"
Examples
Example1 expression
unwords ["Lorem", "ipsum", "dolor"]"Lorem ipsum dolor"
Example1 expression
unwords ["foo", "bar", "", "baz"]"foo bar  baz"
valuewords :: String -> [String]
#

words breaks a string up into a list of words, which were delimited by white space (as defined by isSpace). This function trims any white spaces at the beginning and at the end.

Examples
Example1 expression
words "Lorem ipsum\ndolor"["Lorem","ipsum","dolor"]
Example1 expression
words " foo bar "["foo","bar"]
valuecurry :: ((a, b) -> c) -> a -> b -> c
#

Convert an uncurried function to a curried function.

Examples
Example1 expression
curry fst 1 21
valuefst :: (a, b) -> a
#

Extract the first component of a pair.

valuesnd :: (a, b) -> b
#

Extract the second component of a pair.

valueuncurry :: (a -> b -> c) -> (a, b) -> c
#

uncurry converts a curried function to a function on pairs.

Examples
Example1 expression
uncurry (+) (1,2)3
Example1 expression
uncurry ($) (show, 1)"1"
Example1 expression
map (uncurry max) [(1,2), (3,4), (6,8)][2,4,8]
valueundefined :: HasCallStack => a
#

A special case of error. It is expected that compilers will recognize this and insert error messages which are more appropriate to the context in which undefined appears.

valueuserError :: String -> IOError
#

Construct an IOError value with a string describing the error. The fail method of the IO instance of the Monad class raises a userError, thus:

instance Monad IO where
  ...
  fail s = ioError (userError s)
value(!!) :: HasCallStack => [a] -> Int -> a
#

List index (subscript) operator, starting from 0. It is an instance of the more general genericIndex, which takes an index of any integral type.

WARNING: This function is partial, and should only be used if you are sure that the indexing will not fail. Otherwise, use Data.List.!?.

WARNING: This function takes linear time in the index.

Examples
Example1 expression
['a', 'b', 'c'] !! 0'a'
Example1 expression
['a', 'b', 'c'] !! 2'c'
Example1 expression
['a', 'b', 'c'] !! 3*** Exception: Prelude.!!: index too large
Example1 expression
['a', 'b', 'c'] !! (-1)*** Exception: Prelude.!!: negative index
valuebreak :: (a -> Bool) -> [a] -> ([a], [a])
#

break, applied to a predicate p and a list xs, returns a tuple where first element is longest prefix (possibly empty) of xs of elements that do not satisfy p and second element is the remainder of the list:

break p is equivalent to span (not . p) and consequently to (takeWhile (not . p) xs, dropWhile (not . p) xs), even if p is _|_.

Laziness
Example1 expression
break undefined []([],[])
Example1 expression
fst (break (const True) undefined)*** Exception: Prelude.undefined
Example1 expression
fst (break (const True) (undefined : undefined))[]
Example1 expression
take 1 (fst (break (const False) (1 : undefined)))[1]

break produces the first component of the tuple lazily:

Example1 expression
take 10 (fst (break (const False) [1..]))[1,2,3,4,5,6,7,8,9,10]
Examples
Example1 expression
break (> 3) [1,2,3,4,1,2,3,4]([1,2,3],[4,1,2,3,4])
Example1 expression
break (< 9) [1,2,3]([],[1,2,3])
Example1 expression
break (> 9) [1,2,3]([1,2,3],[])
valuecycle :: HasCallStack => [a] -> [a]
#

cycle ties a finite list into a circular one, or equivalently, the infinite repetition of the original list. It is the identity on infinite lists.

Examples
Example1 expression
cycle []*** Exception: Prelude.cycle: empty list
Example1 expression
take 10 (cycle [42])[42,42,42,42,42,42,42,42,42,42]
Example1 expression
take 10 (cycle [2, 5, 7])[2,5,7,2,5,7,2,5,7,2]
Example1 expression
take 1 (cycle (42 : undefined))[42]
valuedrop :: Int -> [a] -> [a]
#

drop n xs returns the suffix of xs after the first n elements, or [] if n >= length xs.

It is an instance of the more general genericDrop, in which n may be of any integral type.

Examples
Example1 expression
drop 6 "Hello World!""World!"
Example1 expression
drop 3 [1,2,3,4,5][4,5]
Example1 expression
drop 3 [1,2][]
Example1 expression
drop 3 [][]
Example1 expression
drop (-1) [1,2][1,2]
Example1 expression
drop 0 [1,2][1,2]
valuedropWhile :: (a -> Bool) -> [a] -> [a]
#

dropWhile p xs returns the suffix remaining after takeWhile p xs.

Examples
Example1 expression
dropWhile (< 3) [1,2,3,4,5,1,2,3][3,4,5,1,2,3]
Example1 expression
dropWhile (< 9) [1,2,3][]
Example1 expression
dropWhile (< 0) [1,2,3][1,2,3]
valuefilter :: (a -> Bool) -> [a] -> [a]
#

\mathcal{O}(n). filter, applied to a predicate and a list, returns the list of those elements that satisfy the predicate; i.e.,

filter p xs = [ x | x <- xs, p x]
Examples
Example1 expression
filter odd [1, 2, 3][1,3]
Example1 expression
filter (\l -> length l > 3) ["Hello", ", ", "World", "!"]["Hello","World"]
Example1 expression
filter (/= 3) [1, 2, 3, 4, 3, 2, 1][1,2,4,2,1]
valueiterate :: (a -> a) -> a -> [a]
#

iterate f x returns an infinite list of repeated applications of f to x:

iterate f x == [x, f x, f (f x), ...]
Laziness

Note that iterate is lazy, potentially leading to thunk build-up if the consumer doesn't force each element. See iterate' for a strict variant of this function.

Example3 expressions
let xs = iterate (\x -> if x == 0 then undefined else x - 1) 2xs[2,1,0,*** Exception: Prelude.undefinedlength (take 10 xs)10

In xs every element following 0 is bottom, but the list itself is infinitely long because it is generated without forcing its elements.

Examples
Example1 expression
take 10 $ iterate not True[True,False,True,False,True,False,True,False,True,False]
Example1 expression
take 10 $ iterate (+3) 42[42,45,48,51,54,57,60,63,66,69]

iterate id == repeat:

Example1 expression
take 10 $ iterate id 1[1,1,1,1,1,1,1,1,1,1]
valuelookup :: Eq a => a -> [(a, b)] -> Maybe b
#

\mathcal{O}(n). lookup key assocs looks up a key in an association list. For the result to be Nothing, the list must be finite.

Examples
Example1 expression
lookup 2 []Nothing
Example1 expression
lookup 2 [(1, "first")]Nothing
Example1 expression
lookup 2 [(1, "first"), (2, "second"), (3, "third")]Just "second"
valuerepeat :: a -> [a]
#

repeat x is an infinite list, with x the value of every element.

Examples
Example1 expression
take 10 $ repeat 17[17,17,17,17,17,17,17,17,17, 17]
Example1 expression
repeat undefined[*** Exception: Prelude.undefined
valuereplicate :: Int -> a -> [a]
#

replicate n x is a list of length n with x the value of every element. It is an instance of the more general genericReplicate, in which n may be of any integral type.

Examples
Example1 expression
replicate 0 True[]
Example1 expression
replicate (-1) True[]
Example1 expression
replicate 4 True[True,True,True,True]
valuereverse :: [a] -> [a]
#

\mathcal{O}(n). reverse xs returns the elements of xs in reverse order. xs must be finite.

Laziness

reverse is lazy in its elements.

Example1 expression
head (reverse [undefined, 1])1
Example1 expression
reverse (1 : 2 : undefined)*** Exception: Prelude.undefined
Examples
Example1 expression
reverse [][]
Example1 expression
reverse [42][42]
Example1 expression
reverse [2,5,7][7,5,2]
Example1 expression
reverse [1..]* Hangs forever *
valuescanl :: (b -> a -> b) -> b -> [a] -> [b]
#

\mathcal{O}(n). scanl is similar to foldl, but returns a list of successive reduced values from the left:

scanl f z [x1, x2, ...] == [z, z `f` x1, (z `f` x1) `f` x2, ...]

Note that

last (scanl f z xs) == foldl f z xs
Examples
Example1 expression
scanl (+) 0 [1..4][0,1,3,6,10]
Example1 expression
scanl (+) 42 [][42]
Example1 expression
scanl (-) 100 [1..4][100,99,97,94,90]
Example1 expression
scanl (\reversedString nextChar -> nextChar : reversedString) "foo" ['a', 'b', 'c', 'd']["foo","afoo","bafoo","cbafoo","dcbafoo"]
Example1 expression
take 10 (scanl (+) 0 [1..])[0,1,3,6,10,15,21,28,36,45]
Example1 expression
take 1 (scanl undefined 'a' undefined)"a"
valuescanl1 :: (a -> a -> a) -> [a] -> [a]
#

\mathcal{O}(n). scanl1 is a variant of scanl that has no starting value argument:

scanl1 f [x1, x2, ...] == [x1, x1 `f` x2, ...]
Examples
Example1 expression
scanl1 (+) [1..4][1,3,6,10]
Example1 expression
scanl1 (+) [][]
Example1 expression
scanl1 (-) [1..4][1,-1,-4,-8]
Example1 expression
scanl1 (&&) [True, False, True, True][True,False,False,False]
Example1 expression
scanl1 (||) [False, False, True, True][False,False,True,True]
Example1 expression
take 10 (scanl1 (+) [1..])[1,3,6,10,15,21,28,36,45,55]
Example1 expression
take 1 (scanl1 undefined ('a' : undefined))"a"
valuescanr :: (a -> b -> b) -> b -> [a] -> [b]
#

\mathcal{O}(n). scanr is the right-to-left dual of scanl. Note that the order of parameters on the accumulating function are reversed compared to scanl. Also note that

head (scanr f z xs) == foldr f z xs.
Examples
Example1 expression
scanr (+) 0 [1..4][10,9,7,4,0]
Example1 expression
scanr (+) 42 [][42]
Example1 expression
scanr (-) 100 [1..4][98,-97,99,-96,100]
Example1 expression
scanr (\nextChar reversedString -> nextChar : reversedString) "foo" ['a', 'b', 'c', 'd']["abcdfoo","bcdfoo","cdfoo","dfoo","foo"]
Example1 expression
force $ scanr (+) 0 [1..]*** Exception: stack overflow
valuescanr1 :: (a -> a -> a) -> [a] -> [a]
#

\mathcal{O}(n). scanr1 is a variant of scanr that has no starting value argument.

Examples
Example1 expression
scanr1 (+) [1..4][10,9,7,4]
Example1 expression
scanr1 (+) [][]
Example1 expression
scanr1 (-) [1..4][-2,3,-1,4]
Example1 expression
scanr1 (&&) [True, False, True, True][False,False,True,True]
Example1 expression
scanr1 (||) [True, True, False, False][True,True,False,False]
Example1 expression
force $ scanr1 (+) [1..]*** Exception: stack overflow
valuespan :: (a -> Bool) -> [a] -> ([a], [a])
#

span, applied to a predicate p and a list xs, returns a tuple where first element is the longest prefix (possibly empty) of xs of elements that satisfy p and second element is the remainder of the list:

span p xs is equivalent to (takeWhile p xs, dropWhile p xs), even if p is _|_.

Laziness
Example4 expressions
span undefined []([],[])fst (span (const False) undefined)*** Exception: Prelude.undefinedfst (span (const False) (undefined : undefined))[]take 1 (fst (span (const True) (1 : undefined)))[1]

span produces the first component of the tuple lazily:

Example1 expression
take 10 (fst (span (const True) [1..]))[1,2,3,4,5,6,7,8,9,10]
Examples
Example1 expression
span (< 3) [1,2,3,4,1,2,3,4]([1,2],[3,4,1,2,3,4])
Example1 expression
span (< 9) [1,2,3]([1,2,3],[])
Example1 expression
span (< 0) [1,2,3]([],[1,2,3])
valuesplitAt :: Int -> [a] -> ([a], [a])
#

splitAt n xs returns a tuple where first element is xs prefix of length n and second element is the remainder of the list:

splitAt is an instance of the more general genericSplitAt, in which n may be of any integral type.

Laziness

It is equivalent to (take n xs, drop n xs) unless n is _|_: splitAt _|_ xs = _|_, not (_|_, _|_)).

The first component of the tuple is produced lazily:

Example1 expression
fst (splitAt 0 undefined)[]
Example1 expression
take 1 (fst (splitAt 10 (1 : undefined)))[1]
Examples
Example1 expression
splitAt 6 "Hello World!"("Hello ","World!")
Example1 expression
splitAt 3 [1,2,3,4,5]([1,2,3],[4,5])
Example1 expression
splitAt 1 [1,2,3]([1],[2,3])
Example1 expression
splitAt 3 [1,2,3]([1,2,3],[])
Example1 expression
splitAt 4 [1,2,3]([1,2,3],[])
Example1 expression
splitAt 0 [1,2,3]([],[1,2,3])
Example1 expression
splitAt (-1) [1,2,3]([],[1,2,3])
valuetake :: Int -> [a] -> [a]
#

take n, applied to a list xs, returns the prefix of xs of length n, or xs itself if n >= length xs.

It is an instance of the more general genericTake, in which n may be of any integral type.

Laziness
Example2 expressions
take 0 undefined[]take 2 (1 : 2 : undefined)[1,2]
Examples
Example1 expression
take 5 "Hello World!""Hello"
Example1 expression
take 3 [1,2,3,4,5][1,2,3]
Example1 expression
take 3 [1,2][1,2]
Example1 expression
take 3 [][]
Example1 expression
take (-1) [1,2][]
Example1 expression
take 0 [1,2][]
valuetakeWhile :: (a -> Bool) -> [a] -> [a]
#

takeWhile, applied to a predicate p and a list xs, returns the longest prefix (possibly empty) of xs of elements that satisfy p.

Laziness
Example1 expression
takeWhile (const False) undefined*** Exception: Prelude.undefined
Example1 expression
takeWhile (const False) (undefined : undefined)[]
Example1 expression
take 1 (takeWhile (const True) (1 : undefined))[1]
Examples
Example1 expression
takeWhile (< 3) [1,2,3,4,1,2,3,4][1,2]
Example1 expression
takeWhile (< 9) [1,2,3][1,2,3]
Example1 expression
takeWhile (< 0) [1,2,3][]
valueunzip3 :: [(a, b, c)] -> ([a], [b], [c])
#

The unzip3 function takes a list of triples and returns three lists of the respective components, analogous to unzip.

Examples
Example1 expression
unzip3 []([],[],[])
Example1 expression
unzip3 [(1, 'a', True), (2, 'b', False)]([1,2],"ab",[True,False])
valuezip :: [a] -> [b] -> [(a, b)]
#

\mathcal{O}(\min(m,n)). zip takes two lists and returns a list of corresponding pairs.

zip is right-lazy:

Example2 expressions
zip [] undefined[]zip undefined []*** Exception: Prelude.undefined...

zip is capable of list fusion, but it is restricted to its first list argument and its resulting list.

Examples
Example1 expression
zip [1, 2, 3] ['a', 'b', 'c'][(1,'a'),(2,'b'),(3,'c')]

If one input list is shorter than the other, excess elements of the longer list are discarded, even if one of the lists is infinite:

Example1 expression
zip [1] ['a', 'b'][(1,'a')]
Example1 expression
zip [1, 2] ['a'][(1,'a')]
Example1 expression
zip [] [1..][]
Example1 expression
zip [1..] [][]
valuezip3 :: [a] -> [b] -> [c] -> [(a, b, c)]
#

zip3 takes three lists and returns a list of triples, analogous to zip. It is capable of list fusion, but it is restricted to its first list argument and its resulting list.

valuezipWith :: (a -> b -> c) -> [a] -> [b] -> [c]
#

\mathcal{O}(\min(m,n)). zipWith generalises zip by zipping with the function given as the first argument, instead of a tupling function.

zipWith (,) xs ys == zip xs ys
zipWith f [x1,x2,x3..] [y1,y2,y3..] == [f x1 y1, f x2 y2, f x3 y3..]

zipWith is right-lazy:

Example2 expressions
let f = undefinedzipWith f [] undefined[]

zipWith is capable of list fusion, but it is restricted to its first list argument and its resulting list.

Examples

zipWith (+) can be applied to two lists to produce the list of corresponding sums:

Example1 expression
zipWith (+) [1, 2, 3] [4, 5, 6][5,7,9]
Example1 expression
zipWith (++) ["hello ", "foo"] ["world!", "bar"]["hello world!","foobar"]
valuezipWith3 :: (a -> b -> c -> d) -> [a] -> [b] -> [c] -> [d]
#

\mathcal{O}(\min(l,m,n)). The zipWith3 function takes a function which combines three elements, as well as three lists and returns a list of the function applied to corresponding elements, analogous to zipWith. It is capable of list fusion, but it is restricted to its first list argument and its resulting list.

zipWith3 (,,) xs ys zs == zip3 xs ys zs
zipWith3 f [x1,x2,x3..] [y1,y2,y3..] [z1,z2,z3..] == [f x1 y1 z1, f x2 y2 z2, f x3 y3 z3..]
Examples
Example1 expression
zipWith3 (\x y z -> [x, y, z]) "123" "abc" "xyz"["1ax","2by","3cz"]
Example1 expression
zipWith3 (\x y z -> (x * y) + z) [1, 2, 3] [4, 5, 6] [7, 8, 9][11,18,27]
valuesubtract :: Num a => a -> a -> a
#

the same as flip (-).

Because - is treated specially in the Haskell grammar, (- e) is not a section, but an application of prefix negation. However, (subtract exp) is equivalent to the disallowed section.

valuelex :: ReadS String
#

The lex function reads a single lexeme from the input, discarding initial white space, and returning the characters that constitute the lexeme. If the input string contains only white space, lex returns a single successful `lexeme' consisting of the empty string. (Thus lex "" = [("","")].) If there is no legal lexeme at the beginning of the input string, lex fails (i.e. returns []).

This lexer is not completely faithful to the Haskell lexical syntax in the following respects:

  • Qualified names are not handled properly

  • Octal and hexadecimal numerics are not recognized as a single token

  • Comments are not treated properly

value(^) :: (Num a, Integral b) => a -> b -> a
#

raise a number to a non-negative integral power

valuefromIntegral :: (Integral a, Num b) => a -> b
#

General coercion from Integral types.

WARNING: This function performs silent truncation if the result type is not at least as big as the argument's type.

valuegcd :: Integral a => a -> a -> a
#

gcd x y is the non-negative factor of both x and y of which every common factor of x and y is also a factor; for example gcd 4 2 = 2, gcd (-4) 6 = 2, gcd 0 4 = 4. gcd 0 0 = 0. (That is, the common divisor that is "greatest" in the divisibility preordering.)

Note: Since for signed fixed-width integer types, abs minBound < 0, the result may be negative if one of the arguments is minBound (and necessarily is if the other is 0 or minBound) for such types.

valuelcm :: Integral a => a -> a -> a
#

lcm x y is the smallest positive integer that both x and y divide.

valueshowChar :: Char -> ShowS
#

utility function converting a Char to a show function that simply prepends the character unchanged.

valueshowParen :: Bool -> ShowS -> ShowS
#

utility function that surrounds the inner show function with parentheses when the Bool parameter is True.

valueappendFile :: FilePath -> String -> IO ()
#

The computation appendFile file str function appends the string str, to the file file.

Note that writeFile and appendFile write a literal string to a file. To write a value of any printable type, as with print, use the show function to convert the value to a string first.

This operation may fail with the same errors as hPutStr and withFile.

Examples

The following example could be more efficently written by acquiring a handle instead with openFile and using the computations capable of writing to handles such as hPutStr.

Example2 expressions
let fn = "hello_world"in writeFile fn "hello" >> appendFile fn " world!" >> (readFile fn >>= putStrLn)"hello world!"
Example2 expressions
let fn = "foo"; output = readFile' fn >>= putStrLnin output >> appendFile fn (show [1,2,3]) >> outputthis is what's in the filethis is what's in the file[1,2,3]
valuegetChar :: IO Char
#

Read a single character from the standard input device.

getChar is implemented as hGetChar stdin.

This operation may fail with the same errors as hGetChar.

Examples
Example1 expression
getChara'a'
Example1 expression
getChar>'\n'
valuegetContents :: IO String
#

The getContents operation returns all user input as a single string, which is read lazily as it is needed.

getContents is implemented as hGetContents stdin.

This operation may fail with the same errors as hGetContents.

Examples
Example1 expression
getContents >>= putStr> aaabbbccc :Daaabbbccc :D> I hope you have a great dayI hope you have a great day> ^D
Example1 expression
getContents >>= print . length> abc> <3> def ^D11
valuegetLine :: IO String
#

Read a line from the standard input device.

getLine is implemented as hGetLine stdin.

This operation may fail with the same errors as hGetLine.

Examples
Example1 expression
getLine> Hello World!"Hello World!"
Example1 expression
getLine>""
valueinteract :: (String -> String) -> IO ()
#

interact f takes the entire input from stdin and applies f to it. The resulting string is written to the stdout device.

Note that this operation is lazy, which allows to produce output even before all input has been consumed.

This operation may fail with the same errors as getContents and putStr.

If it doesn't produce output the buffering settings may not be correct, use ^D (ctrl+D) to close stdin which forces the buffer to be consumed.

You may wish to set the buffering style appropriate to your program's needs before using this function, for example:

main :: IO ()
main = do
  hSetBuffering stdin LineBuffering
  hSetBuffering stdout NoBuffering
  interact (concatMap (str -> str ++ str) . L.lines)
Examples
Example1 expression
interact (\str -> str ++ str)> hi :)hi :)> ^Dhi :)
Example1 expression
interact (const ":D"):D
Example1 expression
interact (show . words)> hello world!> I hope you have a great day> ^D["hello","world!","I","hope","you","have","a","great","day"]
valueprint :: Show a => a -> IO ()
#

The print function outputs a value of any printable type to the standard output device. Printable types are those that are instances of class Show; print converts values to strings for output using the show operation and adds a newline.

print is implemented as putStrLn . show

This operation may fail with the same errors, and has the same issues with concurrency, as hPutStr!

Examples
Example1 expression
print [1, 2, 3][1,2,3]

Be careful when using print for outputting strings, as this will invoke show and cause strings to be printed with quotation marks and non-ascii symbols escaped.

Example1 expression
print "λ :D""\995 :D"

A program to print the first 8 integers and their powers of 2 could be written as:

Example1 expression
print [(n, 2^n) | n <- [0..8]][(0,1),(1,2),(2,4),(3,8),(4,16),(5,32),(6,64),(7,128),(8,256)]
valueputChar :: Char -> IO ()
#

Write a character to the standard output device

putChar is implemented as hPutChar stdout.

This operation may fail with the same errors as hPutChar.

Examples

Note that the following do not put a newline.

Example1 expression
putChar 'x'x
Example1 expression
putChar '\0042'*
valueputStr :: String -> IO ()
#

Write a string to the standard output device

putStr is implemented as hPutStr stdout.

This operation may fail with the same errors, and has the same issues with concurrency, as hPutStr!

Examples

Note that the following do not put a newline.

Example1 expression
putStr "Hello, World!"Hello, World!
Example1 expression
putStr "\0052\0042\0050"4*2
valueputStrLn :: String -> IO ()
#

The same as putStr, but adds a newline character.

This operation may fail with the same errors, and has the same issues with concurrency, as hPutStr!

valuereadFile :: FilePath -> IO String
#

The readFile function reads a file and returns the contents of the file as a string.

The file is read lazily, on demand, as with getContents.

This operation may fail with the same errors as hGetContents and openFile.

Examples
Example1 expression
readFile "~/hello_world""Greetings!"
Example1 expression
take 5 <$> readFile "/dev/zero""\NUL\NUL\NUL\NUL\NUL"
valuereadIO :: Read a => String -> IO a
#

The readIO function is similar to read except that it signals parse failure to the IO monad instead of terminating the program.

This operation may fail with:

Examples
Example1 expression
fmap (+ 1) (readIO "1")2
Example1 expression
readIO "not quite ()" :: IO ()*** Exception: user error (Prelude.readIO: no parse)
valuereadLn :: Read a => IO a
#

The readLn function combines getLine and readIO.

This operation may fail with the same errors as getLine and readIO.

Examples
Example1 expression
fmap (+ 5) readLn> 2530
Example1 expression
readLn :: IO String> this is not a string literal*** Exception: user error (Prelude.readIO: no parse)
valuewriteFile :: FilePath -> String -> IO ()
#

The computation writeFile file str function writes the string str, to the file file.

This operation may fail with the same errors as hPutStr and withFile.

Examples
Example1 expression
writeFile "hello" "world" >> readFile "hello""world"
Example1 expression
writeFile "~/" "D:"*** Exception: ~/: withFile: inappropriate type (Is a directory)
valueread :: Read a => String -> a
#

The read function reads input from a string, which must be completely consumed by the input process. read fails with an error if the parse is unsuccessful, and it is therefore discouraged from being used in real applications. Use readMaybe or readEither for safe alternatives.

Example1 expression
read "123" :: Int123
Example1 expression
read "hello" :: Int*** Exception: Prelude.read: no parse
valueseq :: a -> b -> b
#

The value of seq a b is bottom if a is bottom, and otherwise equal to b. In other words, it evaluates the first argument a to weak head normal form (WHNF). seq is usually introduced to improve performance by avoiding unneeded laziness.

A note on evaluation order: the expression seq a b does not guarantee that a will be evaluated before b. The only guarantee given by seq is that the both a and b will be evaluated before seq returns a value. In particular, this means that b may be evaluated before a. If you need to guarantee a specific order of evaluation, you must use the function pseq from the "parallel" package.

classclass Foldable t => Foldable1 (t :: Type -> Type) where
#

Non-empty data structures that can be folded.

Methods

  • fold1 :: Semigroup m => t m -> m

    Given a structure with elements whose type is a Semigroup, combine them via the semigroup's (<>) operator. This fold is right-associative and lazy in the accumulator. When you need a strict left-associative fold, use foldMap1' instead, with id as the map.

  • foldMap1 :: Semigroup m => (a -> m) -> t a -> m

    Map each element of the structure to a semigroup, and combine the results with (<>). This fold is right-associative and lazy in the accumulator. For strict left-associative folds consider foldMap1' instead.

    Example1 expression
    foldMap1 (:[]) (1 :| [2, 3, 4])[1,2,3,4]
  • foldMap1' :: Semigroup m => (a -> m) -> t a -> m

    A left-associative variant of foldMap1 that is strict in the accumulator. Use this for strict reduction when partial results are merged via (<>).

    Example1 expression
    foldMap1' Sum (1 :| [2, 3, 4])Sum {getSum = 10}
  • toNonEmpty :: t a -> NonEmpty a

    NonEmpty list of elements of a structure, from left to right.

    Example1 expression
    toNonEmpty (Identity 2)2 :| []
  • maximum :: Ord a => t a -> a

    The largest element of a non-empty structure. This function is equivalent to foldr1 max, and its behavior on structures with multiple largest elements depends on the relevant implementation of max. For the default implementation of max (max x y = if x <= y then y else x), structure order is used as a tie-breaker: if there are multiple largest elements, the rightmost of them is chosen (this is equivalent to maximumBy compare).

    Example1 expression
    maximum (32 :| [64, 8, 128, 16])128
  • minimum :: Ord a => t a -> a

    The least element of a non-empty structure. This function is equivalent to foldr1 min, and its behavior on structures with multiple largest elements depends on the relevant implementation of min. For the default implementation of min (min x y = if x <= y then x else y), structure order is used as a tie-breaker: if there are multiple least elements, the leftmost of them is chosen (this is equivalent to minimumBy compare).

    Example1 expression
    minimum (32 :| [64, 8, 128, 16])8
  • foldrMap1 :: (a -> b) -> (a -> b -> b) -> t a -> b

    Right-associative fold of a structure, lazy in the accumulator.

    In case of NonEmpty lists, foldrMap1, when given a function f, a binary operator g, and a list, reduces the list using g from right to left applying f to the rightmost element:

    foldrMap1 f g (x1 :| [x2, ..., xn1, xn]) == x1 `g` (x2 `g` ... (xn1 `g` (f xn))...)

    Note that since the head of the resulting expression is produced by an application of g to the first element of the list, if g is lazy in its right argument, foldrMap1 can produce a terminating expression from an unbounded list.

    For a general Foldable1 structure this should be semantically identical to:

    foldrMap1 f g = foldrMap1 f g . toNonEmpty
  • foldlMap1' :: (a -> b) -> (b -> a -> b) -> t a -> b

    Left-associative fold of a structure but with strict application of the operator.

    This ensures that each step of the fold is forced to Weak Head Normal Form before being applied, avoiding the collection of thunks that would otherwise occur. This is often what you want to strictly reduce a finite structure to a single strict result.

    For a general Foldable1 structure this should be semantically identical to:

    foldlMap1' f z = foldlMap1' f z . toNonEmpty
  • foldlMap1 :: (a -> b) -> (b -> a -> b) -> t a -> b

    Left-associative fold of a structure, lazy in the accumulator. This is rarely what you want, but can work well for structures with efficient right-to-left sequencing and an operator that is lazy in its left argument.

    In case of NonEmpty lists, foldlMap1, when given a function f, a binary operator g, and a list, reduces the list using g from left to right applying f to the leftmost element:

    foldlMap1 f g (x1 :| [x2, ..., xn]) == (...(((f x1) `g` x2) `g`...) `g` xn

    Note that to produce the outermost application of the operator the entire input list must be traversed. This means that foldlMap1 will diverge if given an infinite list.

    If you want an efficient strict left-fold, you probably want to use foldlMap1' instead of foldlMap1. The reason for this is that the latter does not force the inner results (e.g. (f x1) `g` x2 in the above example) before applying them to the operator (e.g. to (`g` x3)). This results in a thunk chain O(n) elements long, which then must be evaluated from the outside-in.

    For a general Foldable1 structure this should be semantically identical to:

    foldlMap1 f g = foldlMap1 f g . toNonEmpty
  • foldrMap1' :: (a -> b) -> (a -> b -> b) -> t a -> b

    foldrMap1' is a variant of foldrMap1 that performs strict reduction from right to left, i.e. starting with the right-most element. The input structure must be finite, otherwise foldrMap1' runs out of space (diverges).

    If you want a strict right fold in constant space, you need a structure that supports faster than O(n) access to the right-most element.

    This method does not run in constant space for structures such as NonEmpty lists that don't support efficient right-to-left iteration and so require O(n) space to perform right-to-left reduction. Use of this method with such a structure is a hint that the chosen structure may be a poor fit for the task at hand. If the order in which the elements are combined is not important, use foldlMap1' instead.

Instances33Foldable1, …
classclass Functor (f :: Type -> Type) where
#

A type f is a Functor if it provides a function fmap which, given any types a and b lets you apply any function from (a -> b) to turn an f a into an f b, preserving the structure of f. Furthermore f needs to adhere to the following:

Identity

fmap id == id

Composition

fmap (f . g) == fmap f . fmap g

Note, that the second law follows from the free theorem of the type fmap and the first law, so you need only check that the former condition holds. See these articles by School of Haskell or David Luposchainsky for an explanation.

Methods

  • fmap :: (a -> b) -> f a -> f b

    fmap is used to apply a function of type (a -> b) to a value of type f a, where f is a functor, to produce a value of type f b. Note that for any type constructor with more than one parameter (e.g., Either), only the last type parameter can be modified with fmap (e.g., b in Either a b).

    Some type constructors with two parameters or more have a Bifunctor instance that allows both the last and the penultimate parameters to be mapped over.

    Examples

    Convert from a Maybe Int to a Maybe String using show:

    Example2 expressions
    fmap show NothingNothingfmap show (Just 3)Just "3"

    Convert from an Either Int Int to an Either Int String using show:

    Example2 expressions
    fmap show (Left 17)Left 17fmap show (Right 17)Right "17"

    Double each element of a list:

    Example1 expression
    fmap (*2) [1,2,3][2,4,6]

    Apply even to the second element of a pair:

    Example1 expression
    fmap even (2,2)(2,True)

    It may seem surprising that the function is only applied to the last element of the tuple compared to the list example above which applies it to every element in the list. To understand, remember that tuples are type constructors with multiple type parameters: a tuple of 3 elements (a,b,c) can also be written (,,) a b c and its Functor instance is defined for Functor ((,,) a b) (i.e., only the third parameter is free to be mapped over with fmap).

    It explains why fmap can be used with tuples containing values of different types as in the following example:

    Example1 expression
    fmap even ("hello", 1.0, 4)("hello",1.0,True)
  • (<$) :: a -> f b -> f ainfixl 4

    Replace all locations in the input with the same value. The default definition is fmap . const, but this may be overridden with a more efficient version.

    Examples

    Perform a computation with Maybe and replace the result with a constant value if it is Just:

    Example2 expressions
    'a' <$ Just 2Just 'a''a' <$ NothingNothing
Instances273Functor, …
  • Functor ComplexDefined in base-4.23.0.0 · Data.Complex
  • Functor FirstDefined in base-4.23.0.0 · Data.Semigroup
  • Functor LastDefined in base-4.23.0.0 · Data.Semigroup
  • Functor MaxDefined in base-4.23.0.0 · Data.Semigroup
  • Functor MinDefined in base-4.23.0.0 · Data.Semigroup
  • Functor ArgDescrDefined in base-4.23.0.0 · System.Console.GetOpt
  • Functor ArgOrderDefined in base-4.23.0.0 · System.Console.GetOpt
  • Functor OptDescrDefined in base-4.23.0.0 · System.Console.GetOpt
  • Functor DecoderDefined in binary-0.8.9.3 · Data.Binary.Get.Internal
  • Functor GetDefined in binary-0.8.9.3 · Data.Binary.Get.Internal
  • Functor PutMDefined in binary-0.8.9.3 · Data.Binary.Put
  • Functor PutDefined in bytestring-0.12.2.0 · Data.ByteString.Builder.Internal
  • Functor SCCDefined in containers-0.8 · Data.Graph
  • Functor IntMapDefined in containers-0.8 · Data.IntMap.Internal
  • Functor DigitDefined in containers-0.8 · Data.Sequence.Internal
  • Functor ElemDefined in containers-0.8 · Data.Sequence.Internal
  • Functor FingerTreeDefined in containers-0.8 · Data.Sequence.Internal
  • Functor NodeDefined in containers-0.8 · Data.Sequence.Internal
  • Functor SeqDefined in containers-0.8 · Data.Sequence.Internal
  • Functor ViewLDefined in containers-0.8 · Data.Sequence.Internal
  • Functor ViewRDefined in containers-0.8 · Data.Sequence.Internal
  • Functor PostOrderDefined in containers-0.8 · Data.Tree
  • Functor TreeDefined in containers-0.8 · Data.Tree
  • Functor InspectAsmDefined in ghc-10.0.0.20260917 · GHC.ByteCode.Asm
  • Functor OneOrTwoDefined in ghc-10.0.0.20260917 · GHC.ByteCode.Asm
  • Functor RunAsmDefined in ghc-10.0.0.20260917 · GHC.ByteCode.Asm
  • Functor GenBasicBlockDefined in ghc-10.0.0.20260917 · GHC.Cmm
  • Functor ListGraphDefined in ghc-10.0.0.20260917 · GHC.Cmm
  • Functor LabelMapDefined in ghc-10.0.0.20260917 · GHC.Cmm.Dataflow.Label
  • Functor CmmOptMDefined in ghc-10.0.0.20260917 · GHC.Cmm.GenericOpt
  • Functor CmmLintDefined in ghc-10.0.0.20260917 · GHC.Cmm.Lint
  • Functor PDDefined in ghc-10.0.0.20260917 · GHC.Cmm.Parser.Monad
  • Functor NatMDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.Monad
  • Functor InstrSRDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.Reg.Liveness
  • Functor LiveInstrDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.Reg.Liveness
  • Functor WasmAsmMDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.Wasm.Asm
  • Functor TEDefined in ghc-10.0.0.20260917 · GHC.CmmToC
  • Functor LlvmMDefined in ghc-10.0.0.20260917 · GHC.CmmToLlvm.Base
  • Functor NormaliseStepResultDefined in ghc-10.0.0.20260917 · GHC.Core.Coercion
  • Functor NormMDefined in ghc-10.0.0.20260917 · GHC.Core.FamInstEnv
  • Functor LintMDefined in ghc-10.0.0.20260917 · GHC.Core.Lint
  • Functor AltMapDefined in ghc-10.0.0.20260917 · GHC.Core.Map.Expr
  • Functor CoreMapDefined in ghc-10.0.0.20260917 · GHC.Core.Map.Expr
  • Functor CoreMapXDefined in ghc-10.0.0.20260917 · GHC.Core.Map.Expr
  • Functor BndrMapDefined in ghc-10.0.0.20260917 · GHC.Core.Map.Type
  • Functor CoercionMapDefined in ghc-10.0.0.20260917 · GHC.Core.Map.Type
  • Functor CoercionMapXDefined in ghc-10.0.0.20260917 · GHC.Core.Map.Type
  • Functor LooseTypeMapDefined in ghc-10.0.0.20260917 · GHC.Core.Map.Type
  • Functor TyLitMapDefined in ghc-10.0.0.20260917 · GHC.Core.Map.Type
  • Functor TypeMapDefined in ghc-10.0.0.20260917 · GHC.Core.Map.Type
  • Functor TypeMapXDefined in ghc-10.0.0.20260917 · GHC.Core.Map.Type
  • Functor VarMapDefined in ghc-10.0.0.20260917 · GHC.Core.Map.Type
  • Functor RuleMDefined in ghc-10.0.0.20260917 · GHC.Core.Opt.ConstantFold
  • Functor CoreMDefined in ghc-10.0.0.20260917 · GHC.Core.Opt.Monad
  • Functor SimplMDefined in ghc-10.0.0.20260917 · GHC.Core.Opt.Simplify.Monad
  • Functor RoughMapDefined in ghc-10.0.0.20260917 · GHC.Core.RoughMap
  • Functor UMDefined in ghc-10.0.0.20260917 · GHC.Core.Unify
  • Functor UnifyResultMDefined in ghc-10.0.0.20260917 · GHC.Core.Unify
  • Functor CtsMDefined in ghc-10.0.0.20260917 · GHC.CoreToStg
  • Functor BagDefined in ghc-10.0.0.20260917 · GHC.Data.Bag
  • Functor FlatBagDefined in ghc-10.0.0.20260917 · GHC.Data.FlatBag
  • Functor NullCollapseVizDefined in ghc-10.0.0.20260917 · GHC.Data.Graph.Collapse
  • Functor InfiniteDefined in ghc-10.0.0.20260917 · GHC.Data.List.Infinite
  • Functor OrdListDefined in ghc-10.0.0.20260917 · GHC.Data.OrdList
  • Functor PairDefined in ghc-10.0.0.20260917 · GHC.Data.Pair
  • Functor MaybeDefined in ghc-10.0.0.20260917 · GHC.Data.Strict
  • Functor Word64MapDefined in ghc-10.0.0.20260917 · GHC.Data.Word64Map.Internal
  • Functor KnotVarsDefined in ghc-10.0.0.20260917 · GHC.Driver.Env.KnotVars
  • Functor HscDefined in ghc-10.0.0.20260917 · GHC.Driver.Env.Types
  • Functor ModNodeMapDefined in ghc-10.0.0.20260917 · GHC.Driver.Make
  • Functor ResultVarDefined in ghc-10.0.0.20260917 · GHC.Driver.Make
  • Functor GhcDefined in ghc-10.0.0.20260917 · GHC.Driver.Monad
  • Functor HookedUseDefined in ghc-10.0.0.20260917 · GHC.Driver.Pipeline.Execute
  • Functor MatchResultDefined in ghc-10.0.0.20260917 · GHC.HsToCore.Monad
  • Functor CheckActionDefined in ghc-10.0.0.20260917 · GHC.HsToCore.Pmc.Check
  • Functor CheckResultDefined in ghc-10.0.0.20260917 · GHC.HsToCore.Pmc.Types
  • Functor TMDefined in ghc-10.0.0.20260917 · GHC.HsToCore.Ticks
  • Functor HieASTDefined in ghc-10.0.0.20260917 · GHC.Iface.Ext.Types
  • Functor HieASTsDefined in ghc-10.0.0.20260917 · GHC.Iface.Ext.Types
  • Functor HieArgsDefined in ghc-10.0.0.20260917 · GHC.Iface.Ext.Types
  • Functor HieTypeDefined in ghc-10.0.0.20260917 · GHC.Iface.Ext.Types
  • Functor IdentifierDetailsDefined in ghc-10.0.0.20260917 · GHC.Iface.Ext.Types
  • Functor NodeInfoDefined in ghc-10.0.0.20260917 · GHC.Iface.Ext.Types
  • Functor SourcedNodeInfoDefined in ghc-10.0.0.20260917 · GHC.Iface.Ext.Types
  • Functor EvidenceInfoDefined in ghc-10.0.0.20260917 · GHC.Iface.Ext.Utils
  • Functor MaybeValidatedDefined in ghc-10.0.0.20260917 · GHC.Iface.Recomp
  • Functor DFFVDefined in ghc-10.0.0.20260917 · GHC.Iface.Tidy
  • Functor LinkableWithDefined in ghc-10.0.0.20260917 · GHC.Linker.Types
  • Functor EpAnnDefined in ghc-10.0.0.20260917 · GHC.Parser.Annotation
  • Functor PDefined in ghc-10.0.0.20260917 · GHC.Parser.Lexer
  • Functor PVDefined in ghc-10.0.0.20260917 · GHC.Parser.PostProcess
  • Functor PV_ResultDefined in ghc-10.0.0.20260917 · GHC.Parser.PostProcess
  • Functor HdkADefined in ghc-10.0.0.20260917 · GHC.Parser.PostProcess.Haddock
  • Functor HdkMDefined in ghc-10.0.0.20260917 · GHC.Parser.PostProcess.Haddock
  • Functor CpsRnDefined in ghc-10.0.0.20260917 · GHC.Rename.Pat
  • Functor TPRnMDefined in ghc-10.0.0.20260917 · GHC.Rename.Pat
  • Functor ConAppMapDefined in ghc-10.0.0.20260917 · GHC.Stg.CSE
  • Functor StgArgMapDefined in ghc-10.0.0.20260917 · GHC.Stg.CSE
  • Functor RMDefined in ghc-10.0.0.20260917 · GHC.Stg.EnforceEpt.Rewrite
  • Functor LiftMDefined in ghc-10.0.0.20260917 · GHC.Stg.Lift.Monad
  • Functor LintMDefined in ghc-10.0.0.20260917 · GHC.Stg.Lint
  • Functor StgMDefined in ghc-10.0.0.20260917 · GHC.Stg.Pipeline
  • Functor BcMDefined in ghc-10.0.0.20260917 · GHC.StgToByteCode
  • Functor CmmParseDefined in ghc-10.0.0.20260917 · GHC.StgToCmm.ExtCode
  • Functor FCodeDefined in ghc-10.0.0.20260917 · GHC.StgToCmm.Monad
  • Functor BranchDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Expr
  • Functor KindRepMDefined in ghc-10.0.0.20260917 · GHC.Tc.Instance.Typeable
  • Functor SolverStageDefined in ghc-10.0.0.20260917 · GHC.Tc.Solver.Monad
  • Functor StopOrContinueDefined in ghc-10.0.0.20260917 · GHC.Tc.Solver.Monad
  • Functor TcSDefined in ghc-10.0.0.20260917 · GHC.Tc.Solver.Monad
  • Functor RewriteMDefined in ghc-10.0.0.20260917 · GHC.Tc.Solver.Rewrite
  • Functor RoleMDefined in ghc-10.0.0.20260917 · GHC.Tc.TyCl.Utils
  • Functor SynCycleMDefined in ghc-10.0.0.20260917 · GHC.Tc.TyCl.Utils
  • Functor TcPluginMDefined in ghc-10.0.0.20260917 · GHC.Tc.Types
  • Functor ZonkMDefined in ghc-10.0.0.20260917 · GHC.Tc.Zonk.Monad
  • Functor AnnTargetDefined in ghc-10.0.0.20260917 · GHC.Types.Annotations
  • Functor TyConFlavourDefined in ghc-10.0.0.20260917 · GHC.Types.Basic
  • Functor MessagesDefined in ghc-10.0.0.20260917 · GHC.Types.Error
  • Functor MsgEnvelopeDefined in ghc-10.0.0.20260917 · GHC.Types.Error
  • Functor OccEnvDefined in ghc-10.0.0.20260917 · GHC.Types.Name.Occurrence
  • Functor WithUserRdrDefined in ghc-10.0.0.20260917 · GHC.Types.Name.Reader
  • Functor TaggedValDefined in ghc-10.0.0.20260917 · GHC.Types.Unique.DFM
  • Functor UniqDSMDefined in ghc-10.0.0.20260917 · GHC.Types.Unique.DSM
  • Functor UniqSMDefined in ghc-10.0.0.20260917 · GHC.Types.Unique.Supply
  • Functor UnitEnvGraphDefined in ghc-10.0.0.20260917 · GHC.Unit.Home.Graph
  • Functor NodeMapDefined in ghc-10.0.0.20260917 · GHC.Unit.Module.Graph
  • Functor DefiniteDefined in ghc-10.0.0.20260917 · GHC.Unit.Types
  • Functor GenModuleDefined in ghc-10.0.0.20260917 · GHC.Unit.Types
  • Functor GenWithIsBootDefined in ghc-10.0.0.20260917 · GHC.Unit.Types
  • Functor BinaryReaderDefined in ghc-10.0.0.20260917 · GHC.Utils.Binary
  • Functor FingerprintWithValueDefined in ghc-10.0.0.20260917 · GHC.Utils.Binary
  • Functor Validity'Defined in ghc-10.0.0.20260917 · GHC.Utils.Error
  • Functor DataDefnConsDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Decls
  • Functor PprMDefined in ghc-boot-th-10.0.0.20260917 · GHC.Boot.TH.PprLib
  • Functor NonEmptyDefined in ghc-internal-10.0.0 · GHC.Internal.Data.NonEmpty · orphan
  • Functor HandlerDefined in ghc-internal-10.0.0 · GHC.Internal.Control.Exception
  • Functor IdentityDefined in ghc-internal-10.0.0 · GHC.Internal.Data.Functor.Identity
  • Functor FirstDefined in ghc-internal-10.0.0 · GHC.Internal.Data.Monoid
  • Functor LastDefined in ghc-internal-10.0.0 · GHC.Internal.Data.Monoid
  • Functor DownDefined in ghc-internal-10.0.0 · GHC.Internal.Data.Ord
  • Functor DualDefined in ghc-internal-10.0.0 · GHC.Internal.Data.Semigroup.Internal
  • Functor ProductDefined in ghc-internal-10.0.0 · GHC.Internal.Data.Semigroup.Internal
  • Functor SumDefined in ghc-internal-10.0.0 · GHC.Internal.Data.Semigroup.Internal
  • Functor ZipListDefined in ghc-internal-10.0.0 · GHC.Internal.Functor.ZipList
  • Functor NoIODefined in ghc-internal-10.0.0 · GHC.Internal.GHCi
  • Functor Par1Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Functor GenClosureDefined in ghc-internal-10.0.0 · GHC.Internal.Heap.Closures
  • Functor GenStackFieldDefined in ghc-internal-10.0.0 · GHC.Internal.Heap.Closures
  • Functor GenStackFrameDefined in ghc-internal-10.0.0 · GHC.Internal.Heap.Closures
  • Functor GenStgStackClosureDefined in ghc-internal-10.0.0 · GHC.Internal.Heap.Closures
  • Functor MaybeDefined in ghc-internal-10.0.0 · GHC.Internal.Base
  • Functor STMDefined in ghc-internal-10.0.0 · GHC.Internal.STM
  • Functor QDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Monad
  • Functor TyVarBndrDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Functor PDefined in ghc-internal-10.0.0 · GHC.Internal.Text.ParserCombinators.ReadP
  • Functor ReadPDefined in ghc-internal-10.0.0 · GHC.Internal.Text.ParserCombinators.ReadP
  • Functor ReadPrecDefined in ghc-internal-10.0.0 · GHC.Internal.Text.ParserCombinators.ReadPrec
  • Functor SoloDefined in ghc-internal-10.0.0 · GHC.Internal.Base
  • Functor IODefined in ghc-internal-10.0.0 · GHC.Internal.Base
  • Functor MDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Monad
  • Functor GHCiQDefined in ghci-10.0.0.20260917 · GHCi.TH
  • Functor AnnotDetailsDefined in pretty-1.1.3.6 · Text.PrettyPrint.Annotated.HughesPJ
  • Functor DocDefined in pretty-1.1.3.6 · Text.PrettyPrint.Annotated.HughesPJ
  • Functor SpanDefined in pretty-1.1.3.6 · Text.PrettyPrint.Annotated.HughesPJ
  • Functor STMDefined in stm-2.5.3.1 · Control.Sequential.STM
  • Functor []Defined in ghc-internal-10.0.0 · GHC.Internal.Base
  • Functor ProxyDefined in ghc-internal-10.0.0 · GHC.Internal.Data.Proxy
  • Functor U1Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Functor V1Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Functor (Arg a)Defined in base-4.23.0.0 · Data.Semigroup
  • Functor (Map k)Defined in containers-0.8 · Data.Map.Internal
  • Functor (State s)Defined in containers-0.8 · Utils.Containers.Internal.State
  • Functor (MaybeO ex)Defined in ghc-10.0.0.20260917 · GHC.Cmm.Dataflow.Block
  • Functor (RegAllocStats statics)Defined in ghc-10.0.0.20260917 · GHC.CmmToAsm.Reg.Graph.Stats
  • Functor (RegM freeRegs)Defined in ghc-10.0.0.20260917 · GHC.CmmToAsm.Reg.Linear.State
  • Functor (WasmCodeGenM w)Defined in ghc-10.0.0.20260917 · GHC.CmmToAsm.Wasm.Types
  • Functor (Node key)Defined in ghc-10.0.0.20260917 · GHC.Data.Graph.Directed
  • Functor (Gr a)Defined in ghc-10.0.0.20260917 · GHC.Data.Graph.Inductive.PatriciaTree
  • Functor (IOEnv env)Defined in ghc-10.0.0.20260917 · GHC.Data.IOEnv
  • Functor (MaybeErr err)Defined in ghc-10.0.0.20260917 · GHC.Data.Maybe
  • Functor (Pair a)Defined in ghc-10.0.0.20260917 · GHC.Data.Strict
  • Functor (CmdLineP s)Defined in ghc-10.0.0.20260917 · GHC.Driver.Session
  • Functor (IfaceBindingX r)Defined in ghc-10.0.0.20260917 · GHC.Iface.Syntax
  • Functor (PuResult a)Defined in ghc-10.0.0.20260917 · GHC.Tc.Utils.Unify
  • Functor (ZonkBndrT m)Defined in ghc-10.0.0.20260917 · GHC.Tc.Zonk.Env
  • Functor (CvtM' err)Defined in ghc-10.0.0.20260917 · GHC.ThToHs
  • Functor (GenLocated l)Defined in ghc-10.0.0.20260917 · GHC.Types.SrcLoc
  • Functor (UniqMap k)Defined in ghc-10.0.0.20260917 · GHC.Types.Unique.Map
  • Functor (Codensity k)Defined in ghc-10.0.0.20260917 · GHC.Utils.Monad.Codensity
  • Functor (State s)Defined in ghc-10.0.0.20260917 · GHC.Utils.Monad.State.Strict
  • Functor (HsFieldBind lhs)Defined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Pat
  • Functor (DbOpenMode mode)Defined in ghc-boot-10.0.0.20260917 · GHC.Unit.Database
  • Functor (Array i)Defined in ghc-internal-10.0.0 · GHC.Internal.Arr
  • Functor (ST s)Defined in ghc-internal-10.0.0 · GHC.Internal.Control.Monad.ST.Lazy.Imp
  • Functor (Either a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Either
  • Functor (StateL s)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Functor.Utils
  • Functor (StateR s)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Functor.Utils
  • Functor (ST s)Defined in ghc-internal-10.0.0 · GHC.Internal.ST
  • Functor (Tuple2 a)Defined in ghc-internal-10.0.0 · GHC.Internal.Base
  • Functor (IParser t)Defined in text-2.1.4 · Data.Text.Internal.Read
  • Functor f => Functor (Lift f)Defined in transformers-0.6.3.0 · Control.Applicative.Lift
  • Functor m => Functor (GenMap m)Defined in ghc-10.0.0.20260917 · GHC.Data.TrieMap
  • Functor m => Functor (ListMap m)Defined in ghc-10.0.0.20260917 · GHC.Data.TrieMap
  • Functor m => Functor (MaybeMap m)Defined in ghc-10.0.0.20260917 · GHC.Data.TrieMap
  • Functor m => Functor (EwM m)Defined in ghc-10.0.0.20260917 · GHC.Driver.CmdLine
  • Functor m => Functor (GhcT m)Defined in ghc-10.0.0.20260917 · GHC.Driver.Monad
  • Functor m => Functor (ZonkT m)Defined in ghc-10.0.0.20260917 · GHC.Tc.Zonk.Env
  • Functor m => Functor (UniqDSMT m)Defined in ghc-10.0.0.20260917 · GHC.Types.Unique.DSM
  • Functor m => Functor (MaybeT m)Defined in transformers-0.6.3.0 · Control.Monad.Trans.Maybe
  • Monad m => Functor (WrappedMonad m)Defined in base-4.23.0.0 · Control.Applicative
  • Monad m => Functor (Handler m)Defined in exceptions-0.10.12 · Control.Monad.Catch
  • Monad m => Functor (CatchT m)Defined in exceptions-0.10.12 · Control.Monad.Catch.Pure
  • Arrow a => Functor (ArrowMonad a)Defined in ghc-internal-10.0.0 · GHC.Internal.Control.Arrow
  • Functor (GenCmmDecl d h)Defined in ghc-10.0.0.20260917 · GHC.Cmm
  • Functor (S z s)Defined in ghc-10.0.0.20260917 · GHC.CmmToAsm.CFG.Dominators
  • Functor (Stream f a)Defined in ghc-10.0.0.20260917 · GHC.Data.Stream
  • Functor (UniqDFM key)Defined in ghc-10.0.0.20260917 · GHC.Types.Unique.DFM
  • Functor (NonDetUniqFM key)Defined in ghc-10.0.0.20260917 · GHC.Types.Unique.FM
  • Functor (UniqFM key)Defined in ghc-10.0.0.20260917 · GHC.Types.Unique.FM
  • Functor (Const m)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Functor.Const
  • Functor (URec Char)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Functor (URec Double)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Functor (URec Float)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Functor (URec Int)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Functor (URec Word)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Functor (URec (Ptr ()))Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Functor (Tuple3 a b)Defined in ghc-internal-10.0.0 · GHC.Internal.Base
  • Functor (Constant a)Defined in transformers-0.6.3.0 · Data.Functor.Constant
  • Functor (t m) => Functor (LiftingAccum t m)Defined in mtl-2.3.2 · Control.Monad.Accum
  • Functor (t m) => Functor (LiftingSelect t m)Defined in mtl-2.3.2 · Control.Monad.Select
  • Functor f => Functor (Ap f)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Monoid
  • Functor f => Functor (Alt f)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Semigroup.Internal
  • Functor f => Functor (Rec1 f)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Functor f => Functor (Backwards f)Defined in transformers-0.6.3.0 · Control.Applicative.Backwards

    Derived instance.

  • Functor f => Functor (Reverse f)Defined in transformers-0.6.3.0 · Data.Functor.Reverse

    Derived instance.

  • Functor m => Functor (StreamS m a)Defined in ghc-10.0.0.20260917 · GHC.Data.Stream
  • Functor m => Functor (Kleisli m a)Defined in ghc-internal-10.0.0 · GHC.Internal.Control.Arrow
  • Functor m => Functor (AccumT w m)Defined in transformers-0.6.3.0 · Control.Monad.Trans.Accum
  • Functor m => Functor (ExceptT e m)Defined in transformers-0.6.3.0 · Control.Monad.Trans.Except
  • Functor m => Functor (IdentityT m)Defined in transformers-0.6.3.0 · Control.Monad.Trans.Identity
  • Functor m => Functor (ReaderT r m)Defined in transformers-0.6.3.0 · Control.Monad.Trans.Reader
  • Functor m => Functor (SelectT r m)Defined in transformers-0.6.3.0 · Control.Monad.Trans.Select
  • Functor m => Functor (StateT s m)Defined in transformers-0.6.3.0 · Control.Monad.Trans.State.Lazy
  • Functor m => Functor (StateT s m)Defined in transformers-0.6.3.0 · Control.Monad.Trans.State.Strict
  • Functor m => Functor (WriterT w m)Defined in transformers-0.6.3.0 · Control.Monad.Trans.Writer.CPS
  • Functor m => Functor (WriterT w m)Defined in transformers-0.6.3.0 · Control.Monad.Trans.Writer.Lazy
  • Functor m => Functor (WriterT w m)Defined in transformers-0.6.3.0 · Control.Monad.Trans.Writer.Strict
  • Monad m => Functor (StateT s m)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Functor.Utils
  • Arrow a => Functor (WrappedArrow a b)Defined in base-4.23.0.0 · Control.Applicative
  • (Applicative f, Monad f) => Functor (WhenMissing f x)Defined in containers-0.8 · Data.IntMap.Internal
  • (Applicative f, Monad f) => Functor (WhenMissing f x)Defined in ghc-10.0.0.20260917 · GHC.Data.Word64Map.Internal
  • (Generic1 f, Functor (Rep1 f)) => Functor (Generically1 f)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Functor (K1 i c)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Functor (Tuple4 a b c)Defined in ghc-internal-10.0.0 · GHC.Internal.Base
  • Functor (ContT r m)Defined in transformers-0.6.3.0 · Control.Monad.Trans.Cont
  • Functor ((->) r)Defined in ghc-internal-10.0.0 · GHC.Internal.Base
  • Functor f => Functor (WhenMatched f x y)Defined in containers-0.8 · Data.IntMap.Internal
  • Functor f => Functor (WhenMatched f x y)Defined in ghc-10.0.0.20260917 · GHC.Data.Word64Map.Internal
  • (Applicative f, Monad f) => Functor (WhenMissing f k x)Defined in containers-0.8 · Data.Map.Internal
  • (Functor f, Functor g) => Functor (Product f g)Defined in base-4.23.0.0 · Data.Functor.Product
  • (Functor f, Functor g) => Functor (Sum f g)Defined in base-4.23.0.0 · Data.Functor.Sum
  • (Functor f, Functor g) => Functor (f :*: g)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • (Functor f, Functor g) => Functor (f :+: g)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Functor (Tuple5 a b c d)Defined in ghc-internal-10.0.0 · GHC.Internal.Base
  • Functor f => Functor (WhenMatched f k x y)Defined in containers-0.8 · Data.Map.Internal
  • Functor f => Functor (M1 i c f)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Functor m => Functor (RWST r w s m)Defined in transformers-0.6.3.0 · Control.Monad.Trans.RWS.CPS
  • Functor m => Functor (RWST r w s m)Defined in transformers-0.6.3.0 · Control.Monad.Trans.RWS.Lazy
  • Functor m => Functor (RWST r w s m)Defined in transformers-0.6.3.0 · Control.Monad.Trans.RWS.Strict
  • (Functor f, Functor g) => Functor (Compose f g)Defined in base-4.23.0.0 · Data.Functor.Compose
  • (Functor f, Functor g) => Functor (f :.: g)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Functor (Tuple6 a b c d e)Defined in ghc-internal-10.0.0 · GHC.Internal.Base
  • Functor (Tuple7 a b c d e f)Defined in ghc-internal-10.0.0 · GHC.Internal.Base
classclass Applicative m => Monad (m :: Type -> Type) where
#

The Monad class defines the basic operations over a monad, a concept from a branch of mathematics known as category theory. From the perspective of a Haskell programmer, however, it is best to think of a monad as an abstract datatype of actions. Haskell's do expressions provide a convenient syntax for writing monadic expressions.

Instances of Monad should satisfy the following:

Left identity

return a >>= k = k a

Right identity

m >>= return = m

Associativity

m >>= (\x -> k x >>= h) = (m >>= k) >>= h

Furthermore, the Monad and Applicative operations should relate as follows:

The above laws imply:

and that pure and (<*>) satisfy the applicative functor laws.

The instances of Monad for List, Maybe and System.IO.IO defined in the Prelude satisfy these laws.

Methods

  • (>>=) :: m a -> (a -> m b) -> m binfixl 1

    Sequentially compose two actions, passing any value produced by the first as an argument to the second.

    'as >>= bs' can be understood as the do expression

    do a <- as
       bs a
    

    An alternative name for this function is 'bind', because it is used to introduce bindings in monadic contexts, but some people may refer to it as 'flatMap', which results from it being equivalent to

    \x f -> join (fmap f x) :: Monad m => m a -> (a -> m b) -> m b

    which can be seen as mapping a value with Monad m => m a -> m (m b) and then 'flattening' m (m b) to m b using join.

  • (>>) :: m a -> m b -> m binfixl 1

    Sequentially compose two actions, discarding any value produced by the first, like sequencing operators (such as the semicolon) in imperative languages.

    'as >> bs' can be understood as the do expression

    do as
       bs
    

    or in terms of (>>=) as

    as >>= const bs
  • return :: a -> m a

    Inject a value into the monadic type. This function should not be different from its default implementation as pure. The justification for the existence of this function is merely historic.

Instances141Monad, …
  • Monad ComplexDefined in base-4.23.0.0 · Data.Complex
  • Monad FirstDefined in base-4.23.0.0 · Data.Semigroup
  • Monad LastDefined in base-4.23.0.0 · Data.Semigroup
  • Monad MaxDefined in base-4.23.0.0 · Data.Semigroup
  • Monad MinDefined in base-4.23.0.0 · Data.Semigroup
  • Monad GetDefined in binary-0.8.9.3 · Data.Binary.Get.Internal
  • Monad PutMDefined in binary-0.8.9.3 · Data.Binary.Put
  • Monad PutDefined in bytestring-0.12.2.0 · Data.ByteString.Builder.Internal
  • Monad SeqDefined in containers-0.8 · Data.Sequence.Internal
  • Monad TreeDefined in containers-0.8 · Data.Tree
  • Monad InspectAsmDefined in ghc-10.0.0.20260917 · GHC.ByteCode.Asm
  • Monad RunAsmDefined in ghc-10.0.0.20260917 · GHC.ByteCode.Asm
  • Monad CmmOptMDefined in ghc-10.0.0.20260917 · GHC.Cmm.GenericOpt
  • Monad CmmLintDefined in ghc-10.0.0.20260917 · GHC.Cmm.Lint
  • Monad PDDefined in ghc-10.0.0.20260917 · GHC.Cmm.Parser.Monad
  • Monad NatMDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.Monad
  • Monad WasmAsmMDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.Wasm.Asm
  • Monad TEDefined in ghc-10.0.0.20260917 · GHC.CmmToC
  • Monad LlvmMDefined in ghc-10.0.0.20260917 · GHC.CmmToLlvm.Base
  • Monad NormMDefined in ghc-10.0.0.20260917 · GHC.Core.FamInstEnv
  • Monad LintMDefined in ghc-10.0.0.20260917 · GHC.Core.Lint
  • Monad RuleMDefined in ghc-10.0.0.20260917 · GHC.Core.Opt.ConstantFold
  • Monad CoreMDefined in ghc-10.0.0.20260917 · GHC.Core.Opt.Monad
  • Monad SimplMDefined in ghc-10.0.0.20260917 · GHC.Core.Opt.Simplify.Monad
  • Monad UMDefined in ghc-10.0.0.20260917 · GHC.Core.Unify
  • Monad UnifyResultMDefined in ghc-10.0.0.20260917 · GHC.Core.Unify
  • Monad CtsMDefined in ghc-10.0.0.20260917 · GHC.CoreToStg
  • Monad NullCollapseVizDefined in ghc-10.0.0.20260917 · GHC.Data.Graph.Collapse
  • Monad InfiniteDefined in ghc-10.0.0.20260917 · GHC.Data.List.Infinite
  • Monad HscDefined in ghc-10.0.0.20260917 · GHC.Driver.Env.Types
  • Monad GhcDefined in ghc-10.0.0.20260917 · GHC.Driver.Monad
  • Monad HookedUseDefined in ghc-10.0.0.20260917 · GHC.Driver.Pipeline.Execute
  • Monad TMDefined in ghc-10.0.0.20260917 · GHC.HsToCore.Ticks
  • Monad DFFVDefined in ghc-10.0.0.20260917 · GHC.Iface.Tidy
  • Monad PDefined in ghc-10.0.0.20260917 · GHC.Parser.Lexer
  • Monad PVDefined in ghc-10.0.0.20260917 · GHC.Parser.PostProcess
  • Monad HdkMDefined in ghc-10.0.0.20260917 · GHC.Parser.PostProcess.Haddock
  • Monad CpsRnDefined in ghc-10.0.0.20260917 · GHC.Rename.Pat
  • Monad TPRnMDefined in ghc-10.0.0.20260917 · GHC.Rename.Pat
  • Monad RMDefined in ghc-10.0.0.20260917 · GHC.Stg.EnforceEpt.Rewrite
  • Monad LiftMDefined in ghc-10.0.0.20260917 · GHC.Stg.Lift.Monad
  • Monad LintMDefined in ghc-10.0.0.20260917 · GHC.Stg.Lint
  • Monad StgMDefined in ghc-10.0.0.20260917 · GHC.Stg.Pipeline
  • Monad BcMDefined in ghc-10.0.0.20260917 · GHC.StgToByteCode
  • Monad CmmParseDefined in ghc-10.0.0.20260917 · GHC.StgToCmm.ExtCode
  • Monad FCodeDefined in ghc-10.0.0.20260917 · GHC.StgToCmm.Monad
  • Monad KindRepMDefined in ghc-10.0.0.20260917 · GHC.Tc.Instance.Typeable
  • Monad SolverStageDefined in ghc-10.0.0.20260917 · GHC.Tc.Solver.Monad
  • Monad TcSDefined in ghc-10.0.0.20260917 · GHC.Tc.Solver.Monad
  • Monad RewriteMDefined in ghc-10.0.0.20260917 · GHC.Tc.Solver.Rewrite
  • Monad RoleMDefined in ghc-10.0.0.20260917 · GHC.Tc.TyCl.Utils
  • Monad SynCycleMDefined in ghc-10.0.0.20260917 · GHC.Tc.TyCl.Utils
  • Monad TcPluginMDefined in ghc-10.0.0.20260917 · GHC.Tc.Types
  • Monad ZonkMDefined in ghc-10.0.0.20260917 · GHC.Tc.Zonk.Monad
  • Monad UniqDSMDefined in ghc-10.0.0.20260917 · GHC.Types.Unique.DSM
  • Monad UniqSMDefined in ghc-10.0.0.20260917 · GHC.Types.Unique.Supply
  • Monad PprMDefined in ghc-boot-th-10.0.0.20260917 · GHC.Boot.TH.PprLib
  • Monad NonEmptyDefined in ghc-internal-10.0.0 · GHC.Internal.Data.NonEmpty · orphan
  • Monad IdentityDefined in ghc-internal-10.0.0 · GHC.Internal.Data.Functor.Identity
  • Monad FirstDefined in ghc-internal-10.0.0 · GHC.Internal.Data.Monoid
  • Monad LastDefined in ghc-internal-10.0.0 · GHC.Internal.Data.Monoid
  • Monad DownDefined in ghc-internal-10.0.0 · GHC.Internal.Data.Ord
  • Monad DualDefined in ghc-internal-10.0.0 · GHC.Internal.Data.Semigroup.Internal
  • Monad ProductDefined in ghc-internal-10.0.0 · GHC.Internal.Data.Semigroup.Internal
  • Monad SumDefined in ghc-internal-10.0.0 · GHC.Internal.Data.Semigroup.Internal
  • Monad NoIODefined in ghc-internal-10.0.0 · GHC.Internal.GHCi
  • Monad Par1Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Monad MaybeDefined in ghc-internal-10.0.0 · GHC.Internal.Base
  • Monad STMDefined in ghc-internal-10.0.0 · GHC.Internal.STM
  • Monad QDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Monad
  • Monad PDefined in ghc-internal-10.0.0 · GHC.Internal.Text.ParserCombinators.ReadP
  • Monad ReadPDefined in ghc-internal-10.0.0 · GHC.Internal.Text.ParserCombinators.ReadP
  • Monad ReadPrecDefined in ghc-internal-10.0.0 · GHC.Internal.Text.ParserCombinators.ReadPrec
  • Monad SoloDefined in ghc-internal-10.0.0 · GHC.Internal.Base
  • Monad IODefined in ghc-internal-10.0.0 · GHC.Internal.Base
  • Monad MDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Monad
  • Monad GHCiQDefined in ghci-10.0.0.20260917 · GHCi.TH
  • Monad STMDefined in stm-2.5.3.1 · Control.Sequential.STM
  • Monad []Defined in ghc-internal-10.0.0 · GHC.Internal.Base
  • Monad ProxyDefined in ghc-internal-10.0.0 · GHC.Internal.Data.Proxy
  • Monad U1Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Monad (State s)Defined in containers-0.8 · Utils.Containers.Internal.State
  • Monad (RegM freeRegs)Defined in ghc-10.0.0.20260917 · GHC.CmmToAsm.Reg.Linear.State
  • Monad (WasmCodeGenM w)Defined in ghc-10.0.0.20260917 · GHC.CmmToAsm.Wasm.Types
  • Monad (IOEnv m)Defined in ghc-10.0.0.20260917 · GHC.Data.IOEnv
  • Monad (MaybeErr err)Defined in ghc-10.0.0.20260917 · GHC.Data.Maybe
  • Monad (CmdLineP s)Defined in ghc-10.0.0.20260917 · GHC.Driver.Session
  • Monad (ZonkBndrT m)Defined in ghc-10.0.0.20260917 · GHC.Tc.Zonk.Env
  • Monad (CvtM' err)Defined in ghc-10.0.0.20260917 · GHC.ThToHs
  • Monad (Codensity f)Defined in ghc-10.0.0.20260917 · GHC.Utils.Monad.Codensity
  • Monad (State s)Defined in ghc-10.0.0.20260917 · GHC.Utils.Monad.State.Strict
  • Monad (ST s)Defined in ghc-internal-10.0.0 · GHC.Internal.Control.Monad.ST.Lazy.Imp
  • Monad (Either e)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Either
  • Monad (ST s)Defined in ghc-internal-10.0.0 · GHC.Internal.ST
  • Monad (IParser t)Defined in text-2.1.4 · Data.Text.Internal.Read
  • Monad m => Monad (WrappedMonad m)Defined in base-4.23.0.0 · Control.Applicative
  • Monad m => Monad (CatchT m)Defined in exceptions-0.10.12 · Control.Monad.Catch.Pure
  • Monad m => Monad (EwM m)Defined in ghc-10.0.0.20260917 · GHC.Driver.CmdLine
  • Monad m => Monad (GhcT m)Defined in ghc-10.0.0.20260917 · GHC.Driver.Monad
  • Monad m => Monad (ZonkT m)Defined in ghc-10.0.0.20260917 · GHC.Tc.Zonk.Env
  • Monad m => Monad (UniqDSMT m)Defined in ghc-10.0.0.20260917 · GHC.Types.Unique.DSM
  • Monad m => Monad (MaybeT m)Defined in transformers-0.6.3.0 · Control.Monad.Trans.Maybe
  • Monoid a => Monad (Tuple2 a)Defined in ghc-internal-10.0.0 · GHC.Internal.Base
  • ArrowApply a => Monad (ArrowMonad a)Defined in ghc-internal-10.0.0 · GHC.Internal.Control.Arrow
  • Monad (S z s)Defined in ghc-10.0.0.20260917 · GHC.CmmToAsm.CFG.Dominators
  • Monad (Stream m a)Defined in ghc-10.0.0.20260917 · GHC.Data.Stream
  • Monad (t m) => Monad (LiftingAccum t m)Defined in mtl-2.3.2 · Control.Monad.Accum
  • Monad (t m) => Monad (LiftingSelect t m)Defined in mtl-2.3.2 · Control.Monad.Select
  • Monad f => Monad (Ap f)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Monoid
  • Monad f => Monad (Alt f)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Semigroup.Internal
  • Monad f => Monad (Rec1 f)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Monad m => Monad (StreamS m a)Defined in ghc-10.0.0.20260917 · GHC.Data.Stream
  • Monad m => Monad (Kleisli m a)Defined in ghc-internal-10.0.0 · GHC.Internal.Control.Arrow
  • Monad m => Monad (StateT s m)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Functor.Utils
  • Monad m => Monad (ExceptT e m)Defined in transformers-0.6.3.0 · Control.Monad.Trans.Except
  • Monad m => Monad (IdentityT m)Defined in transformers-0.6.3.0 · Control.Monad.Trans.Identity
  • Monad m => Monad (ReaderT r m)Defined in transformers-0.6.3.0 · Control.Monad.Trans.Reader
  • Monad m => Monad (SelectT r m)Defined in transformers-0.6.3.0 · Control.Monad.Trans.Select
  • Monad m => Monad (StateT s m)Defined in transformers-0.6.3.0 · Control.Monad.Trans.State.Lazy
  • Monad m => Monad (StateT s m)Defined in transformers-0.6.3.0 · Control.Monad.Trans.State.Strict
  • Monad m => Monad (WriterT w m)Defined in transformers-0.6.3.0 · Control.Monad.Trans.Writer.CPS
  • Monad m => Monad (Reverse m)Defined in transformers-0.6.3.0 · Data.Functor.Reverse

    Derived instance.

  • (Applicative f, Monad f) => Monad (WhenMissing f x)Defined in containers-0.8 · Data.IntMap.Internal

    Equivalent to ReaderT k (ReaderT x (MaybeT f)).

  • (Applicative f, Monad f) => Monad (WhenMissing f x)Defined in ghc-10.0.0.20260917 · GHC.Data.Word64Map.Internal

    Equivalent to ReaderT k (ReaderT x (MaybeT f)).

  • (Monoid a, Monoid b) => Monad (Tuple3 a b)Defined in ghc-internal-10.0.0 · GHC.Internal.Base
  • (Monoid w, Functor m, Monad m) => Monad (AccumT w m)Defined in transformers-0.6.3.0 · Control.Monad.Trans.Accum
  • (Monoid w, Monad m) => Monad (WriterT w m)Defined in transformers-0.6.3.0 · Control.Monad.Trans.Writer.Lazy
  • (Monoid w, Monad m) => Monad (WriterT w m)Defined in transformers-0.6.3.0 · Control.Monad.Trans.Writer.Strict
  • Monad (ContT r m)Defined in transformers-0.6.3.0 · Control.Monad.Trans.Cont
  • Monad ((->) r)Defined in ghc-internal-10.0.0 · GHC.Internal.Base
  • (Applicative f, Monad f) => Monad (WhenMissing f k x)Defined in containers-0.8 · Data.Map.Internal

    Equivalent to ReaderT k (ReaderT x (MaybeT f)) .

  • (Monad f, Applicative f) => Monad (WhenMatched f x y)Defined in containers-0.8 · Data.IntMap.Internal

    Equivalent to ReaderT Key (ReaderT x (ReaderT y (MaybeT f)))

  • (Monad f, Applicative f) => Monad (WhenMatched f x y)Defined in ghc-10.0.0.20260917 · GHC.Data.Word64Map.Internal

    Equivalent to ReaderT Key (ReaderT x (ReaderT y (MaybeT f)))

  • (Monad f, Monad g) => Monad (Product f g)Defined in base-4.23.0.0 · Data.Functor.Product
  • (Monad f, Monad g) => Monad (f :*: g)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • (Monoid a, Monoid b, Monoid c) => Monad (Tuple4 a b c)Defined in ghc-internal-10.0.0 · GHC.Internal.Base
  • Monad f => Monad (M1 i c f)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Monad m => Monad (RWST r w s m)Defined in transformers-0.6.3.0 · Control.Monad.Trans.RWS.CPS
  • (Monad f, Applicative f) => Monad (WhenMatched f k x y)Defined in containers-0.8 · Data.Map.Internal

    Equivalent to ReaderT k (ReaderT x (ReaderT y (MaybeT f)))

  • (Monoid w, Monad m) => Monad (RWST r w s m)Defined in transformers-0.6.3.0 · Control.Monad.Trans.RWS.Lazy
  • (Monoid w, Monad m) => Monad (RWST r w s m)Defined in transformers-0.6.3.0 · Control.Monad.Trans.RWS.Strict
classclass Semigroup a => Monoid a where
#

The class of monoids (types with an associative binary operation that has an identity). Instances should satisfy the following:

Right identity

x <> mempty = x

Left identity

mempty <> x = x

Associativity

x <> (y <> z) = (x <> y) <> z

(

Semigroup

law)

Concatenation

mconcat = foldr (<>) mempty

You can alternatively define mconcat instead of mempty, in which case the laws are:

Unit

mconcat (pure x) = x

Multiplication

mconcat (join xss) = mconcat (fmap mconcat xss)

Subclass

mconcat (toList xs) = sconcat xs

The method names refer to the monoid of lists under concatenation, but there are many other instances.

Some types can be viewed as a monoid in more than one way, e.g. both addition and multiplication on numbers. In such cases we often define newtypes and make those instances of Monoid, e.g. Data.Semigroup.Sum and Data.Semigroup.Product.

NOTE: Semigroup is a superclass of Monoid since base-4.11.0.0.

Methods

  • mempty :: a

    Identity of mappend

    Examples
    Example1 expression
    "Hello world" <> mempty"Hello world"
    Example1 expression
    mempty <> [1, 2, 3][1,2,3]
  • mappend :: a -> a -> a

    An associative operation

    NOTE: This method is redundant and has the default implementation mappend = (<>) since base-4.11.0.0. Should it be implemented manually, since mappend is a synonym for (<>), it is expected that the two functions are defined the same way. In a future GHC release mappend will be removed from Monoid.

  • mconcat :: [a] -> a

    Fold a list using the monoid.

    For most types, the default definition for mconcat will be used, but the function is included in the class definition so that an optimized version can be provided for specific types.

    Example1 expression
    mconcat ["Hello", " ", "Haskell", "!"]"Hello Haskell!"
Instances152Monoid, …
  • Monoid ByteArrayDefined in base-4.23.0.0 · Data.Array.Byte
  • Monoid BuilderDefined in bytestring-0.12.2.0 · Data.ByteString.Builder.Internal
  • Monoid ByteStringDefined in bytestring-0.12.2.0 · Data.ByteString.Internal.Type
  • Monoid ByteStringDefined in bytestring-0.12.2.0 · Data.ByteString.Lazy.Internal
  • Monoid ShortByteStringDefined in bytestring-0.12.2.0 · Data.ByteString.Short.Internal
  • Monoid IntSetDefined in containers-0.8 · Data.IntSet.Internal

    mempty = empty

  • Monoid UnitDefined in deepseq-1.5.2.0 · Control.DeepSeq
  • Monoid LabelSetDefined in ghc-10.0.0.20260917 · GHC.Cmm.Dataflow.Label
  • Monoid LoadArgsDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.X86.CodeGen
  • Monoid LlvmAccumDefined in ghc-10.0.0.20260917 · GHC.CmmToLlvm.CodeGen
  • Monoid CoHoleSetDefined in ghc-10.0.0.20260917 · GHC.Core.TyCo.Rep
  • Monoid FastStringDefined in ghc-10.0.0.20260917 · GHC.Data.FastString
  • Monoid Word64SetDefined in ghc-10.0.0.20260917 · GHC.Data.Word64Set.Internal
  • Monoid PluginRecompileDefined in ghc-10.0.0.20260917 · GHC.Driver.Plugins
  • Monoid HsTyPatRnBuilderDefined in ghc-10.0.0.20260917 · GHC.Hs.Type
  • Monoid CIRBDefined in ghc-10.0.0.20260917 · GHC.HsToCore.Pmc
  • Monoid NablasDefined in ghc-10.0.0.20260917 · GHC.HsToCore.Pmc.Solver.Types
  • Monoid PrecisionDefined in ghc-10.0.0.20260917 · GHC.HsToCore.Pmc.Types
  • Monoid RecompileRequiredDefined in ghc-10.0.0.20260917 · GHC.Iface.Recomp
  • Monoid IfaceAppArgsDefined in ghc-10.0.0.20260917 · GHC.Iface.Type
  • Monoid JStgStatDefined in ghc-10.0.0.20260917 · GHC.JS.JStg.Syntax
  • Monoid MultiplicityDefined in ghc-10.0.0.20260917 · GHC.JS.Opt.Simple
  • Monoid VarUsageDefined in ghc-10.0.0.20260917 · GHC.JS.Opt.Simple
  • Monoid VarValueDefined in ghc-10.0.0.20260917 · GHC.JS.Opt.Simple
  • Monoid BlockOptDefined in ghc-10.0.0.20260917 · GHC.JS.Optimizer
  • Monoid JStatDefined in ghc-10.0.0.20260917 · GHC.JS.Syntax
  • Monoid UnitLinkOptsDefined in ghc-10.0.0.20260917 · GHC.Linker.Unit
  • Monoid ColumnBoundDefined in ghc-10.0.0.20260917 · GHC.Parser.PostProcess.Haddock
  • Monoid LocRangeDefined in ghc-10.0.0.20260917 · GHC.Parser.PostProcess.Haddock
  • Monoid LowerLocBoundDefined in ghc-10.0.0.20260917 · GHC.Parser.PostProcess.Haddock
  • Monoid UpperLocBoundDefined in ghc-10.0.0.20260917 · GHC.Parser.PostProcess.Haddock
  • Monoid DisambigInfoDefined in ghc-10.0.0.20260917 · GHC.Rename.Env
  • Monoid IPEStatsDefined in ghc-10.0.0.20260917 · GHC.StgToCmm.Utils
  • Monoid CIStaticDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Monoid ArchiveDefined in ghc-10.0.0.20260917 · GHC.SysTools.Ar
  • Monoid TcMBoolDefined in ghc-10.0.0.20260917 · GHC.Tc.Gen.App
  • Monoid TcMUnitDefined in ghc-10.0.0.20260917 · GHC.Tc.Gen.App
  • Monoid TcTyClGroupsAccumDefined in ghc-10.0.0.20260917 · GHC.Tc.TyCl
  • Monoid CheckTyEqResultDefined in ghc-10.0.0.20260917 · GHC.Tc.Types.Constraint
  • Monoid HasGivenEqsDefined in ghc-10.0.0.20260917 · GHC.Tc.Types.Constraint
  • Monoid WantedConstraintsDefined in ghc-10.0.0.20260917 · GHC.Tc.Types.Constraint
  • Monoid CtExplanationsDefined in ghc-10.0.0.20260917 · GHC.Tc.Types.CtLoc
  • Monoid HsWrapperDefined in ghc-10.0.0.20260917 · GHC.Tc.Types.Evidence
  • Monoid CandidatesQTvsDefined in ghc-10.0.0.20260917 · GHC.Tc.Utils.TcMType
  • Monoid UnfilledCoercionHoleMonoidDefined in ghc-10.0.0.20260917 · GHC.Tc.Zonk.TcType
  • Monoid InsideLamDefined in ghc-10.0.0.20260917 · GHC.Types.Basic
  • Monoid InterestingCxtDefined in ghc-10.0.0.20260917 · GHC.Types.Basic
  • Monoid CHeaderDefined in ghc-10.0.0.20260917 · GHC.Types.ForeignStubs
  • Monoid CStubDefined in ghc-10.0.0.20260917 · GHC.Types.ForeignStubs
  • Monoid ShadowedFieldGREsDefined in ghc-10.0.0.20260917 · GHC.Types.Name.Reader
  • Monoid ShadowedGREsDefined in ghc-10.0.0.20260917 · GHC.Types.Name.Reader
  • Monoid NonCaffySetDefined in ghc-10.0.0.20260917 · GHC.Types.Name.Set
  • Monoid UniqueSetDefined in ghc-10.0.0.20260917 · GHC.Types.Unique.Set
  • Monoid ModuleOriginDefined in ghc-10.0.0.20260917 · GHC.Unit.External.ModuleOrigin
  • Monoid UnitVisibilityDefined in ghc-10.0.0.20260917 · GHC.Unit.External.Visibility
  • Monoid PprColourDefined in ghc-10.0.0.20260917 · GHC.Utils.Ppr.Colour
  • Monoid ShortTextDefined in ghc-boot-10.0.0.20260917 · GHC.Data.ShortText
  • Monoid AllDefined in ghc-internal-10.0.0 · GHC.Internal.Data.Semigroup.Internal
  • Monoid AnyDefined in ghc-internal-10.0.0 · GHC.Internal.Data.Semigroup.Internal
  • Monoid EventDefined in ghc-internal-10.0.0 · GHC.Internal.Event.Internal.Types
  • Monoid EventLifetimeDefined in ghc-internal-10.0.0 · GHC.Internal.Event.Internal.Types
  • Monoid LifetimeDefined in ghc-internal-10.0.0 · GHC.Internal.Event.Internal.Types

    mappend takes the longer of two lifetimes.

  • Monoid ExceptionContextDefined in ghc-internal-10.0.0 · GHC.Internal.Exception.Context
  • Monoid OrderingDefined in ghc-internal-10.0.0 · GHC.Internal.Base
  • Monoid OsStringDefined in os-string-2.0.11 · System.OsString.Internal.Types

    "String-Concatenation" for OsString. This is not the same as (</>).

  • Monoid PosixStringDefined in os-string-2.0.11 · System.OsString.Internal.Types
  • Monoid WindowsStringDefined in os-string-2.0.11 · System.OsString.Internal.Types
  • Monoid DocDefined in pretty-1.1.3.6 · Text.PrettyPrint.HughesPJ
  • Monoid TextDefined in text-2.1.4 · Data.Text · orphan
  • Monoid BuilderDefined in text-2.1.4 · Data.Text.Internal.Builder
  • Monoid TextDefined in text-2.1.4 · Data.Text.Lazy · orphan
  • Monoid StrictTextBuilderDefined in text-2.1.4 · Data.Text.Internal.StrictBuilder
  • Monoid CalendarDiffDaysDefined in time-1.16.0.1 · Data.Time.Calendar.CalendarDiffDays

    Additive

  • Monoid CalendarDiffTimeDefined in time-1.16.0.1 · Data.Time.LocalTime.Internal.CalendarDiffTime

    Additive

  • Monoid StatxFlagsDefined in unix-2.8.8.0 · System.Posix.Files.Common
  • Monoid StatxMaskDefined in unix-2.8.8.0 · System.Posix.Files.Common
  • Monoid ()Defined in ghc-internal-10.0.0 · GHC.Internal.Base
  • Monoid (Comparison a)Defined in base-4.23.0.0 · Data.Functor.Contravariant

    mempty on comparisons always returns EQ. Without newtypes this equals pure (pure EQ).

    mempty :: Comparison a
    mempty = Comparison _ _ -> EQ
    
  • Monoid (Equivalence a)Defined in base-4.23.0.0 · Data.Functor.Contravariant

    mempty on equivalences always returns True. Without newtypes this equals pure (pure True).

    mempty :: Equivalence a
    mempty = Equivalence _ _ -> True
    
  • Monoid (Predicate a)Defined in base-4.23.0.0 · Data.Functor.Contravariant

    mempty on predicates always returns True. Without newtypes this equals pure True.

    mempty :: Predicate a
    mempty = _ -> True
    
  • Monoid (PutM ())Defined in binary-0.8.9.3 · Data.Binary.Put
  • Monoid (IntMap a)Defined in containers-0.8 · Data.IntMap.Internal

    mempty = empty

  • Monoid (Seq a)Defined in containers-0.8 · Data.Sequence.Internal

    mempty = empty

  • Monoid (MergeSet a)Defined in containers-0.8 · Data.Set.Internal
  • Monoid (EqM a)Defined in containers-0.8 · Utils.Containers.Internal.EqOrdUtil
  • Monoid (OrdM a)Defined in containers-0.8 · Utils.Containers.Internal.EqOrdUtil
  • Monoid (Bag a)Defined in ghc-10.0.0.20260917 · GHC.Data.Bag
  • Monoid (OrdList a)Defined in ghc-10.0.0.20260917 · GHC.Data.OrdList
  • Monoid (Word64Map a)Defined in ghc-10.0.0.20260917 · GHC.Data.Word64Map.Internal
  • Monoid (IdentifierDetails a)Defined in ghc-10.0.0.20260917 · GHC.Iface.Ext.Types
  • Monoid (AnnSortKey tag)Defined in ghc-10.0.0.20260917 · GHC.Parser.Annotation
  • Monoid (TyVarCheckResult m)Defined in ghc-10.0.0.20260917 · GHC.Tc.Utils.Unify
  • Monoid (Messages e)Defined in ghc-10.0.0.20260917 · GHC.Types.Error
  • Monoid (UniqDSet a)Defined in ghc-10.0.0.20260917 · GHC.Types.Unique.DSet
  • Monoid (UniqSet a)Defined in ghc-10.0.0.20260917 · GHC.Types.Unique.Set
  • Monoid (EndoOS a)Defined in ghc-10.0.0.20260917 · GHC.Utils.EndoOS
  • Monoid (First a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Monoid
  • Monoid (Last a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Monoid
  • Monoid (Endo a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Semigroup.Internal
  • Monoid (Doc a)Defined in pretty-1.1.3.6 · Text.PrettyPrint.Annotated.HughesPJ
  • Monoid [a]Defined in ghc-internal-10.0.0 · GHC.Internal.Base
  • Monoid a => Monoid (WasmAsmM a)Defined in ghc-10.0.0.20260917 · GHC.CmmToAsm.Wasm.Asm
  • Monoid a => Monoid (Pair a)Defined in ghc-10.0.0.20260917 · GHC.Data.Pair
  • Monoid a => Monoid (Identity a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Functor.Identity
  • Monoid a => Monoid (Down a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Ord
  • Monoid a => Monoid (Dual a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Semigroup.Internal
  • Monoid a => Monoid (STM a)Defined in ghc-internal-10.0.0 · GHC.Internal.STM
  • Monoid a => Monoid (Q a)Defined in ghc-internal-10.0.0 · GHC.Internal.TH.Monad
  • Monoid a => Monoid (IO a)Defined in ghc-internal-10.0.0 · GHC.Internal.Base
  • Monoid a => Monoid (a)Defined in ghc-internal-10.0.0 · GHC.Internal.Base
  • Monoid m => Monoid (WrappedMonoid m)Defined in base-4.23.0.0 · Data.Semigroup
  • Monoid p => Monoid (Par1 p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Semigroup a => Monoid (Maybe a)Defined in ghc-10.0.0.20260917 · GHC.Data.Strict
  • Semigroup a => Monoid (Maybe a)Defined in ghc-internal-10.0.0 · GHC.Internal.Base

    Lift a semigroup into Maybe forming a Monoid according to http://en.wikipedia.org/wiki/Monoid: "Any semigroup S may be turned into a monoid simply by adjoining an element e not in S and defining e*e = e and e*s = s = s*e for all s ∈ S."

    Since 4.11.0: constraint on inner a value generalised from Monoid to Semigroup.

  • Bits a => Monoid (Ior a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Bits
  • Bits a => Monoid (Xor a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Bits
  • FiniteBits a => Monoid (And a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Bits

    This constraint is arguably too strong. However, as some types (such as Natural) have undefined complement, this is the only safe choice.

  • FiniteBits a => Monoid (Iff a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Bits

    This constraint is arguably too strong. However, as some types (such as Natural) have undefined complement, this is the only safe choice.

  • Ord a => Monoid (Set a)Defined in containers-0.8 · Data.Set.Internal

    mempty = empty

  • Ord a => Monoid (Max a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Functor.Utils
  • Ord a => Monoid (Min a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Functor.Utils
  • Num a => Monoid (Product a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Semigroup.Internal
  • Num a => Monoid (Sum a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Semigroup.Internal
  • (Ord a, Bounded a) => Monoid (Max a)Defined in base-4.23.0.0 · Data.Semigroup
  • (Ord a, Bounded a) => Monoid (Min a)Defined in base-4.23.0.0 · Data.Semigroup
  • (Generic a, Monoid (Rep a ())) => Monoid (Generically a)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Monoid (EnumSet a)Defined in ghc-10.0.0.20260917 · GHC.Data.EnumSet
  • Monoid (UniqMap k a)Defined in ghc-10.0.0.20260917 · GHC.Types.Unique.Map
  • Monoid (Proxy s)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Proxy
  • Monoid (U1 p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Monoid a => Monoid (Op a b)Defined in base-4.23.0.0 · Data.Functor.Contravariant

    mempty @(Op a b) without newtypes is mempty @(b->a) = _ -> mempty.

    mempty :: Op a b
    mempty = Op _ -> mempty
    
  • Monoid a => Monoid (FV env a)Defined in ghc-10.0.0.20260917 · GHC.Types.Var.FV
  • Monoid a => Monoid (ST s a)Defined in ghc-internal-10.0.0 · GHC.Internal.Control.Monad.ST.Lazy.Imp
  • Monoid a => Monoid (ST s a)Defined in ghc-internal-10.0.0 · GHC.Internal.ST
  • Monoid b => Monoid (a -> b)Defined in ghc-internal-10.0.0 · GHC.Internal.Base
  • Ord k => Monoid (Map k v)Defined in containers-0.8 · Data.Map.Internal

    mempty = empty

  • (Monoid a, Monoid b) => Monoid (a, b)Defined in ghc-internal-10.0.0 · GHC.Internal.Base
  • Alternative f => Monoid (Alt f a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Semigroup.Internal
  • Monoid (UniqFM key a)Defined in ghc-10.0.0.20260917 · GHC.Types.Unique.FM
  • Monoid (f p) => Monoid (Rec1 f p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Monoid a => Monoid (Const a b)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Functor.Const
  • Monoid a => Monoid (Constant a b)Defined in transformers-0.6.3.0 · Data.Functor.Constant
  • (Applicative f, Monoid a) => Monoid (Ap f a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Monoid
  • (Monoid a, Monoid b, Monoid c) => Monoid (a, b, c)Defined in ghc-internal-10.0.0 · GHC.Internal.Base
  • Monoid c => Monoid (K1 i c p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • (Monoid (f a), Monoid (g a)) => Monoid (Product f g a)Defined in base-4.23.0.0 · Data.Functor.Product
  • (Monoid (f p), Monoid (g p)) => Monoid ((:*:) f g p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • (Monoid a, Monoid b, Monoid c, Monoid d) => Monoid (a, b, c, d)Defined in ghc-internal-10.0.0 · GHC.Internal.Base
  • Monoid (f (g a)) => Monoid (Compose f g a)Defined in base-4.23.0.0 · Data.Functor.Compose
  • Monoid (f (g p)) => Monoid ((:.:) f g p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Monoid (f p) => Monoid (M1 i c f p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • (Monoid a, Monoid b, Monoid c, Monoid d, Monoid e) => Monoid (a, b, c, d, e)Defined in ghc-internal-10.0.0 · GHC.Internal.Base
classclass Semigroup a where
#

The class of semigroups (types with an associative binary operation).

Instances should satisfy the following:

Associativity

x <> (y <> z) = (x <> y) <> z

You can alternatively define sconcat instead of (<>), in which case the laws are:

Unit

sconcat (pure x) = x

Multiplication

sconcat (join xss) = sconcat (fmap sconcat xss)

Instances175Semigroup, …
  • Semigroup ByteArrayDefined in base-4.23.0.0 · Data.Array.Byte
  • Semigroup BuilderDefined in bytestring-0.12.2.0 · Data.ByteString.Builder.Internal
  • Semigroup ByteStringDefined in bytestring-0.12.2.0 · Data.ByteString.Internal.Type
  • Semigroup ByteStringDefined in bytestring-0.12.2.0 · Data.ByteString.Lazy.Internal
  • Semigroup ShortByteStringDefined in bytestring-0.12.2.0 · Data.ByteString.Short.Internal
  • Semigroup IntSetDefined in containers-0.8 · Data.IntSet.Internal

    (<>) = union

  • Semigroup IntersectionDefined in containers-0.8 · Data.IntSet.Internal
  • Semigroup UnitDefined in deepseq-1.5.2.0 · Control.DeepSeq
  • Semigroup LabelSetDefined in ghc-10.0.0.20260917 · GHC.Cmm.Dataflow.Label
  • Semigroup CmmSuperDefined in ghc-10.0.0.20260917 · GHC.Cmm.Reducibility
  • Semigroup LoadArgsDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.X86.CodeGen
  • Semigroup LlvmAccumDefined in ghc-10.0.0.20260917 · GHC.CmmToLlvm.CodeGen
  • Semigroup PotentialUnifiersDefined in ghc-10.0.0.20260917 · GHC.Core.InstEnv
  • Semigroup CoHoleSetDefined in ghc-10.0.0.20260917 · GHC.Core.TyCo.Rep
  • Semigroup MaybeApartReasonDefined in ghc-10.0.0.20260917 · GHC.Core.Unify
  • Semigroup FastStringDefined in ghc-10.0.0.20260917 · GHC.Data.FastString
  • Semigroup Word64SetDefined in ghc-10.0.0.20260917 · GHC.Data.Word64Set.Internal
  • Semigroup PluginRecompileDefined in ghc-10.0.0.20260917 · GHC.Driver.Plugins
  • Semigroup HsTyPatRnBuilderDefined in ghc-10.0.0.20260917 · GHC.Hs.Type
  • Semigroup CIRBDefined in ghc-10.0.0.20260917 · GHC.HsToCore.Pmc
  • Semigroup NablasDefined in ghc-10.0.0.20260917 · GHC.HsToCore.Pmc.Solver.Types
  • Semigroup PrecisionDefined in ghc-10.0.0.20260917 · GHC.HsToCore.Pmc.Types
  • Semigroup RecompileRequiredDefined in ghc-10.0.0.20260917 · GHC.Iface.Recomp
  • Semigroup IfaceAppArgsDefined in ghc-10.0.0.20260917 · GHC.Iface.Type
  • Semigroup JStgStatDefined in ghc-10.0.0.20260917 · GHC.JS.JStg.Syntax
  • Semigroup MultiplicityDefined in ghc-10.0.0.20260917 · GHC.JS.Opt.Simple
  • Semigroup VarDeclDefined in ghc-10.0.0.20260917 · GHC.JS.Opt.Simple
  • Semigroup VarUsageDefined in ghc-10.0.0.20260917 · GHC.JS.Opt.Simple
  • Semigroup VarValueDefined in ghc-10.0.0.20260917 · GHC.JS.Opt.Simple
  • Semigroup BlockOptDefined in ghc-10.0.0.20260917 · GHC.JS.Optimizer

    To merge two BlockOpt we first run the left-hand side optimization and capture the right-hand side in the continuation

  • Semigroup JStatDefined in ghc-10.0.0.20260917 · GHC.JS.Syntax
  • Semigroup UnitLinkOptsDefined in ghc-10.0.0.20260917 · GHC.Linker.Unit
  • Semigroup AnnListItemDefined in ghc-10.0.0.20260917 · GHC.Parser.Annotation
  • Semigroup EpAnnCommentsDefined in ghc-10.0.0.20260917 · GHC.Parser.Annotation
  • Semigroup EpaLocationDefined in ghc-10.0.0.20260917 · GHC.Parser.Annotation
  • Semigroup ColumnBoundDefined in ghc-10.0.0.20260917 · GHC.Parser.PostProcess.Haddock
  • Semigroup LocRangeDefined in ghc-10.0.0.20260917 · GHC.Parser.PostProcess.Haddock
  • Semigroup LowerLocBoundDefined in ghc-10.0.0.20260917 · GHC.Parser.PostProcess.Haddock
  • Semigroup UpperLocBoundDefined in ghc-10.0.0.20260917 · GHC.Parser.PostProcess.Haddock
  • Semigroup DisambigInfoDefined in ghc-10.0.0.20260917 · GHC.Rename.Env
  • Semigroup IPEStatsDefined in ghc-10.0.0.20260917 · GHC.StgToCmm.Utils
  • Semigroup JSOptionsDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Object
  • Semigroup CIStaticDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Semigroup ArchiveDefined in ghc-10.0.0.20260917 · GHC.SysTools.Ar
  • Semigroup TcMBoolDefined in ghc-10.0.0.20260917 · GHC.Tc.Gen.App
  • Semigroup TcMUnitDefined in ghc-10.0.0.20260917 · GHC.Tc.Gen.App
  • Semigroup TcTyClGroupsAccumDefined in ghc-10.0.0.20260917 · GHC.Tc.TyCl
  • Semigroup CheckTyEqResultDefined in ghc-10.0.0.20260917 · GHC.Tc.Types.Constraint
  • Semigroup HasGivenEqsDefined in ghc-10.0.0.20260917 · GHC.Tc.Types.Constraint
  • Semigroup WantedConstraintsDefined in ghc-10.0.0.20260917 · GHC.Tc.Types.Constraint
  • Semigroup CtExplanationsDefined in ghc-10.0.0.20260917 · GHC.Tc.Types.CtLoc
  • Semigroup HsWrapperDefined in ghc-10.0.0.20260917 · GHC.Tc.Types.Evidence

    The Semigroup instance is a bit fishy, since WpCompose, as a data constructor, is "syntactic" and not associative. Concretely, if a, b, and c aren't WpHole:

    (a <> b) <> c ?= a <> (b <> c)

    >

    (a `WpCompose` b) `WpCompose` c /= @ a `WpCompose` (b `WpCompose` c)

    However these two associations are are "semantically equal" in the sense that they produce equal functions when passed to GHC.HsToCore.Binds.dsHsWrapper.

  • Semigroup CandidatesQTvsDefined in ghc-10.0.0.20260917 · GHC.Tc.Utils.TcMType
  • Semigroup SimpleUnifyResultDefined in ghc-10.0.0.20260917 · GHC.Tc.Utils.Unify
  • Semigroup UnfilledCoercionHoleMonoidDefined in ghc-10.0.0.20260917 · GHC.Tc.Zonk.TcType
  • Semigroup InsideLamDefined in ghc-10.0.0.20260917 · GHC.Types.Basic

    If any occurrence of an identifier is inside a lambda, then the occurrence info of that identifier marks it as occurring inside a lambda

  • Semigroup InterestingCxtDefined in ghc-10.0.0.20260917 · GHC.Types.Basic

    If there is any interesting identifier occurrence, then the aggregated occurrence info of that identifier is considered interesting.

  • Semigroup SuccessFlagDefined in ghc-10.0.0.20260917 · GHC.Types.Basic
  • Semigroup CHeaderDefined in ghc-10.0.0.20260917 · GHC.Types.ForeignStubs
  • Semigroup CStubDefined in ghc-10.0.0.20260917 · GHC.Types.ForeignStubs
  • Semigroup ShadowedFieldGREsDefined in ghc-10.0.0.20260917 · GHC.Types.Name.Reader
  • Semigroup ShadowedGREsDefined in ghc-10.0.0.20260917 · GHC.Types.Name.Reader
  • Semigroup NonCaffySetDefined in ghc-10.0.0.20260917 · GHC.Types.Name.Set
  • Semigroup BufSpanDefined in ghc-10.0.0.20260917 · GHC.Types.SrcLoc
  • Semigroup UniqueSetDefined in ghc-10.0.0.20260917 · GHC.Types.Unique.Set
  • Semigroup ModuleOriginDefined in ghc-10.0.0.20260917 · GHC.Unit.External.ModuleOrigin
  • Semigroup UnitVisibilityDefined in ghc-10.0.0.20260917 · GHC.Unit.External.Visibility
  • Semigroup PprColourDefined in ghc-10.0.0.20260917 · GHC.Utils.Ppr.Colour
  • Semigroup ShortTextDefined in ghc-boot-10.0.0.20260917 · GHC.Data.ShortText
  • Semigroup VoidDefined in ghc-internal-10.0.0 · GHC.Internal.Base
  • Semigroup AllDefined in ghc-internal-10.0.0 · GHC.Internal.Data.Semigroup.Internal
  • Semigroup AnyDefined in ghc-internal-10.0.0 · GHC.Internal.Data.Semigroup.Internal
  • Semigroup EventDefined in ghc-internal-10.0.0 · GHC.Internal.Event.Internal.Types
  • Semigroup EventLifetimeDefined in ghc-internal-10.0.0 · GHC.Internal.Event.Internal.Types
  • Semigroup LifetimeDefined in ghc-internal-10.0.0 · GHC.Internal.Event.Internal.Types
  • Semigroup ExceptionContextDefined in ghc-internal-10.0.0 · GHC.Internal.Exception.Context
  • Semigroup OrderingDefined in ghc-internal-10.0.0 · GHC.Internal.Base
  • Semigroup OsStringDefined in os-string-2.0.11 · System.OsString.Internal.Types
  • Semigroup PosixStringDefined in os-string-2.0.11 · System.OsString.Internal.Types
  • Semigroup WindowsStringDefined in os-string-2.0.11 · System.OsString.Internal.Types
  • Semigroup DocDefined in pretty-1.1.3.6 · Text.PrettyPrint.HughesPJ
  • Semigroup TextDefined in text-2.1.4 · Data.Text · orphan

    Beware: stimes will crash if the given number does not fit into an Int.

  • Semigroup BuilderDefined in text-2.1.4 · Data.Text.Internal.Builder
  • Semigroup TextDefined in text-2.1.4 · Data.Text.Lazy · orphan
  • Semigroup StrictTextBuilderDefined in text-2.1.4 · Data.Text.Internal.StrictBuilder

    Concatenation of StrictBuilder is right-biased: the right builder will be run first. This allows a builder to run tail-recursively when it was accumulated left-to-right.

  • Semigroup CalendarDiffDaysDefined in time-1.16.0.1 · Data.Time.Calendar.CalendarDiffDays

    Additive

  • Semigroup CalendarDiffTimeDefined in time-1.16.0.1 · Data.Time.LocalTime.Internal.CalendarDiffTime

    Additive

  • Semigroup StatxFlagsDefined in unix-2.8.8.0 · System.Posix.Files.Common

    ORs the flags.

  • Semigroup StatxMaskDefined in unix-2.8.8.0 · System.Posix.Files.Common

    ORs the masks.

  • Semigroup ()Defined in ghc-internal-10.0.0 · GHC.Internal.Base
  • Monoid m => Semigroup (WrappedMonoid m)Defined in base-4.23.0.0 · Data.Semigroup
  • Semigroup (FromMaybe b)Defined in base-4.23.0.0 · Data.Foldable1
  • Semigroup (NonEmptyDList a)Defined in base-4.23.0.0 · Data.Foldable1
  • Semigroup (Comparison a)Defined in base-4.23.0.0 · Data.Functor.Contravariant

    (<>) on comparisons combines results with (<>) @Ordering. Without newtypes this equals liftA2 (liftA2 (<>)).

    (<>) :: Comparison a -> Comparison a -> Comparison a
    Comparison cmp <> Comparison cmp' = Comparison a a' ->
      cmp a a' <> cmp a a'
    
  • Semigroup (Equivalence a)Defined in base-4.23.0.0 · Data.Functor.Contravariant

    (<>) on equivalences uses logical conjunction (&&) on the results. Without newtypes this equals liftA2 (liftA2 (&&)).

    (<>) :: Equivalence a -> Equivalence a -> Equivalence a
    Equivalence equiv <> Equivalence equiv' = Equivalence a b ->
      equiv a b && equiv' a b
    
  • Semigroup (Predicate a)Defined in base-4.23.0.0 · Data.Functor.Contravariant

    (<>) on predicates uses logical conjunction (&&) on the results. Without newtypes this equals liftA2 (&&).

    (<>) :: Predicate a -> Predicate a -> Predicate a
    Predicate pred <> Predicate pred' = Predicate a ->
      pred a && pred' a
    
  • Semigroup (First a)Defined in base-4.23.0.0 · Data.Semigroup
  • Semigroup (Last a)Defined in base-4.23.0.0 · Data.Semigroup
  • Semigroup (PutM ())Defined in binary-0.8.9.3 · Data.Binary.Put
  • Semigroup (IntMap a)Defined in containers-0.8 · Data.IntMap.Internal

    (<>) = union

  • Semigroup (Seq a)Defined in containers-0.8 · Data.Sequence.Internal

    (<>) = (><)

  • Semigroup (MergeSet a)Defined in containers-0.8 · Data.Set.Internal
  • Semigroup (EqM a)Defined in containers-0.8 · Utils.Containers.Internal.EqOrdUtil

    Composes left-to-right, short-circuits on False

  • Semigroup (OrdM a)Defined in containers-0.8 · Utils.Containers.Internal.EqOrdUtil

    Composes left-to-right, short-circuits on non-EQ

  • Semigroup (Bag a)Defined in ghc-10.0.0.20260917 · GHC.Data.Bag
  • Semigroup (OrdList a)Defined in ghc-10.0.0.20260917 · GHC.Data.OrdList
  • Semigroup (Word64Map a)Defined in ghc-10.0.0.20260917 · GHC.Data.Word64Map.Internal
  • Semigroup (IdentifierDetails a)Defined in ghc-10.0.0.20260917 · GHC.Iface.Ext.Types
  • Semigroup (AnnSortKey tag)Defined in ghc-10.0.0.20260917 · GHC.Parser.Annotation
  • Semigroup (TyVarCheckResult m)Defined in ghc-10.0.0.20260917 · GHC.Tc.Utils.Unify
  • Semigroup (Messages e)Defined in ghc-10.0.0.20260917 · GHC.Types.Error
  • Semigroup (UniqDSet a)Defined in ghc-10.0.0.20260917 · GHC.Types.Unique.DSet
  • Semigroup (UniqSet a)Defined in ghc-10.0.0.20260917 · GHC.Types.Unique.Set
  • Semigroup (EndoOS a)Defined in ghc-10.0.0.20260917 · GHC.Utils.EndoOS
  • Semigroup (NonEmpty a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.NonEmpty · orphan
  • Semigroup (First a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Monoid
  • Semigroup (Last a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Monoid
  • Semigroup (Endo a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Semigroup.Internal
  • Semigroup (Doc a)Defined in pretty-1.1.3.6 · Text.PrettyPrint.Annotated.HughesPJ
  • Semigroup [a]Defined in ghc-internal-10.0.0 · GHC.Internal.Base
  • Semigroup a => Semigroup (JoinWith a)Defined in base-4.23.0.0 · Data.Foldable1
  • Semigroup a => Semigroup (WasmAsmM a)Defined in ghc-10.0.0.20260917 · GHC.CmmToAsm.Wasm.Asm
  • Semigroup a => Semigroup (Pair a)Defined in ghc-10.0.0.20260917 · GHC.Data.Pair
  • Semigroup a => Semigroup (Maybe a)Defined in ghc-10.0.0.20260917 · GHC.Data.Strict
  • Semigroup a => Semigroup (EpAnn a)Defined in ghc-10.0.0.20260917 · GHC.Parser.Annotation
  • Semigroup a => Semigroup (Identity a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Functor.Identity
  • Semigroup a => Semigroup (Down a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Ord
  • Semigroup a => Semigroup (Dual a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Semigroup.Internal
  • Semigroup a => Semigroup (Maybe a)Defined in ghc-internal-10.0.0 · GHC.Internal.Base
  • Semigroup a => Semigroup (STM a)Defined in ghc-internal-10.0.0 · GHC.Internal.STM
  • Semigroup a => Semigroup (Q a)Defined in ghc-internal-10.0.0 · GHC.Internal.TH.Monad
  • Semigroup a => Semigroup (IO a)Defined in ghc-internal-10.0.0 · GHC.Internal.Base
  • Semigroup a => Semigroup (a)Defined in ghc-internal-10.0.0 · GHC.Internal.Base
  • Semigroup p => Semigroup (Par1 p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Bits a => Semigroup (And a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Bits
  • Bits a => Semigroup (Ior a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Bits
  • Bits a => Semigroup (Xor a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Bits
  • FiniteBits a => Semigroup (Iff a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Bits

    This constraint is arguably too strong. However, as some types (such as Natural) have undefined complement, this is the only safe choice.

  • Ord a => Semigroup (Max a)Defined in base-4.23.0.0 · Data.Semigroup
  • Ord a => Semigroup (Min a)Defined in base-4.23.0.0 · Data.Semigroup
  • Ord a => Semigroup (Intersection a)Defined in containers-0.8 · Data.Set.Internal
  • Ord a => Semigroup (Set a)Defined in containers-0.8 · Data.Set.Internal

    (<>) = union

  • Ord a => Semigroup (Max a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Functor.Utils
  • Ord a => Semigroup (Min a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Functor.Utils
  • Num a => Semigroup (Product a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Semigroup.Internal
  • Num a => Semigroup (Sum a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Semigroup.Internal
  • (Generic a, Semigroup (Rep a ())) => Semigroup (Generically a)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Semigroup (EnumSet a)Defined in ghc-10.0.0.20260917 · GHC.Data.EnumSet
  • Semigroup (UniqMap k a)Defined in ghc-10.0.0.20260917 · GHC.Types.Unique.Map
  • Semigroup (Either a b)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Either
  • Semigroup (Proxy s)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Proxy
  • Semigroup (U1 p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Semigroup (V1 p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Semigroup a => Semigroup (Op a b)Defined in base-4.23.0.0 · Data.Functor.Contravariant

    (<>) @(Op a b) without newtypes is (<>) @(b->a) = liftA2 (<>). This lifts the Semigroup operation (<>) over the output of a.

    (<>) :: Op a b -> Op a b -> Op a b
    Op f <> Op g = Op a -> f a <> g a
    
  • Semigroup a => Semigroup (FV env a)Defined in ghc-10.0.0.20260917 · GHC.Types.Var.FV
  • Semigroup a => Semigroup (ST s a)Defined in ghc-internal-10.0.0 · GHC.Internal.Control.Monad.ST.Lazy.Imp
  • Semigroup a => Semigroup (ST s a)Defined in ghc-internal-10.0.0 · GHC.Internal.ST
  • Semigroup b => Semigroup (a -> b)Defined in ghc-internal-10.0.0 · GHC.Internal.Base
  • Ord k => Semigroup (Map k v)Defined in containers-0.8 · Data.Map.Internal

    (<>) = union

  • (Semigroup a, Semigroup b) => Semigroup (a, b)Defined in ghc-internal-10.0.0 · GHC.Internal.Base
  • Alternative f => Semigroup (Alt f a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Semigroup.Internal
  • Semigroup (UniqFM key a)Defined in ghc-10.0.0.20260917 · GHC.Types.Unique.FM
  • Semigroup (f p) => Semigroup (Rec1 f p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Semigroup a => Semigroup (Const a b)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Functor.Const
  • Semigroup a => Semigroup (Constant a b)Defined in transformers-0.6.3.0 · Data.Functor.Constant
  • (Applicative f, Semigroup a) => Semigroup (Ap f a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Monoid
  • (Semigroup a, Semigroup b, Semigroup c) => Semigroup (a, b, c)Defined in ghc-internal-10.0.0 · GHC.Internal.Base
  • Semigroup c => Semigroup (K1 i c p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • (Semigroup (f a), Semigroup (g a)) => Semigroup (Product f g a)Defined in base-4.23.0.0 · Data.Functor.Product
  • (Semigroup (f p), Semigroup (g p)) => Semigroup ((:*:) f g p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • (Semigroup a, Semigroup b, Semigroup c, Semigroup d) => Semigroup (a, b, c, d)Defined in ghc-internal-10.0.0 · GHC.Internal.Base
  • Semigroup (f (g a)) => Semigroup (Compose f g a)Defined in base-4.23.0.0 · Data.Functor.Compose
  • Semigroup (f (g p)) => Semigroup ((:.:) f g p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Semigroup (f p) => Semigroup (M1 i c f p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • (Semigroup a, Semigroup b, Semigroup c, Semigroup d, Semigroup e) => Semigroup (a, b, c, d, e)Defined in ghc-internal-10.0.0 · GHC.Internal.Base
classclass Eq a where
#

The Eq class defines equality (==) and inequality (/=). All the basic datatypes exported by the Prelude are instances of Eq, and Eq may be derived for any datatype whose constituents are also instances of Eq.

The Haskell Report defines no laws for Eq. However, instances are encouraged to follow these properties:

Reflexivity

x == x

=

True

Symmetry

x == y

=

y == x

Transitivity

if

x == y && y == z

=

True

, then

x == z

=

True

Extensionality

if

x == y

=

True

and

f

is a function whose return type is an instance of

Eq

, then

f x == f y

=

True

Negation

x /= y

=

not (x == y)

Methods

Instances1064Eq, …
  • Eq ByteArrayDefined in base-4.23.0.0 · Data.Array.Byte
  • Eq IoManagerFlagDefined in base-4.23.0.0 · GHC.RTS.Flags
  • Eq TimeoutDefined in base-4.23.0.0 · System.Timeout
  • Eq FloatingDecimalDefined in bytestring-0.12.2.0 · Data.ByteString.Builder.RealFloat.D2S
  • Eq FloatingDecimalDefined in bytestring-0.12.2.0 · Data.ByteString.Builder.RealFloat.F2S
  • Eq ByteStringDefined in bytestring-0.12.2.0 · Data.ByteString.Internal.Type
  • Eq ByteStringDefined in bytestring-0.12.2.0 · Data.ByteString.Lazy.Internal
  • Eq ShortByteStringDefined in bytestring-0.12.2.0 · Data.ByteString.Short.Internal
  • Eq IntSetDefined in containers-0.8 · Data.IntSet.Internal
  • Eq IntersectionDefined in containers-0.8 · Data.IntSet.Internal
  • Eq PrefixDefined in containers-0.8 · Data.IntSet.Internal.IntTreeCommons
  • Eq FileTypeDefined in directory-1.3.11.0 · System.Directory.Internal.Common
  • Eq PermissionsDefined in directory-1.3.11.0 · System.Directory.Internal.Common
  • Eq XdgDirectoryDefined in directory-1.3.11.0 · System.Directory.Internal.Common
  • Eq XdgDirectoryListDefined in directory-1.3.11.0 · System.Directory.Internal.Common
  • Eq PrimOpDefined in ghc-10.0.0.20260917 · GHC.Builtin.PrimOps
  • Eq PrimOpEffectDefined in ghc-10.0.0.20260917 · GHC.Builtin.PrimOps
  • Eq InternalBreakLocDefined in ghc-10.0.0.20260917 · GHC.ByteCode.Breakpoints
  • Eq InternalBreakpointIdDefined in ghc-10.0.0.20260917 · GHC.ByteCode.Breakpoints
  • Eq LocalLabelDefined in ghc-10.0.0.20260917 · GHC.ByteCode.Instr
  • Eq BCOIxDefined in ghc-10.0.0.20260917 · GHC.ByteCode.Linker
  • Eq ByteOffDefined in ghc-10.0.0.20260917 · GHC.ByteCode.Types
  • Eq HalfWordDefined in ghc-10.0.0.20260917 · GHC.ByteCode.Types
  • Eq NativeCallTypeDefined in ghc-10.0.0.20260917 · GHC.ByteCode.Types
  • Eq RegBitmapDefined in ghc-10.0.0.20260917 · GHC.ByteCode.Types
  • Eq WordOffDefined in ghc-10.0.0.20260917 · GHC.ByteCode.Types
  • Eq CmmInfoTableDefined in ghc-10.0.0.20260917 · GHC.Cmm
  • Eq ProfilingInfoDefined in ghc-10.0.0.20260917 · GHC.Cmm
  • Eq SectionProtectionDefined in ghc-10.0.0.20260917 · GHC.Cmm
  • Eq CLabelDefined in ghc-10.0.0.20260917 · GHC.Cmm.CLabel
  • Eq CmmLabelInfoDefined in ghc-10.0.0.20260917 · GHC.Cmm.CLabel
  • Eq ConInfoTableLocationDefined in ghc-10.0.0.20260917 · GHC.Cmm.CLabel
  • Eq DynamicLinkerLabelInfoDefined in ghc-10.0.0.20260917 · GHC.Cmm.CLabel
  • Eq ForeignLabelSourceDefined in ghc-10.0.0.20260917 · GHC.Cmm.CLabel
  • Eq IdLabelInfoDefined in ghc-10.0.0.20260917 · GHC.Cmm.CLabel
  • Eq InfoProvEntDefined in ghc-10.0.0.20260917 · GHC.Cmm.CLabel
  • Eq ModuleLabelKindDefined in ghc-10.0.0.20260917 · GHC.Cmm.CLabel
  • Eq NeedExternDeclDefined in ghc-10.0.0.20260917 · GHC.Cmm.CLabel
  • Eq RtsLabelInfoDefined in ghc-10.0.0.20260917 · GHC.Cmm.CLabel
  • Eq TickyIdInfoDefined in ghc-10.0.0.20260917 · GHC.Cmm.CLabel
  • Eq LabelDefined in ghc-10.0.0.20260917 · GHC.Cmm.Dataflow.Label
  • Eq LabelSetDefined in ghc-10.0.0.20260917 · GHC.Cmm.Dataflow.Label
  • Eq UnwindExprDefined in ghc-10.0.0.20260917 · GHC.Cmm.DebugBlock
  • Eq DominatorSetDefined in ghc-10.0.0.20260917 · GHC.Cmm.Dominators
  • Eq RPNumDefined in ghc-10.0.0.20260917 · GHC.Cmm.Dominators
  • Eq AlignmentSpecDefined in ghc-10.0.0.20260917 · GHC.Cmm.Expr
  • Eq AreaDefined in ghc-10.0.0.20260917 · GHC.Cmm.Expr
  • Eq CmmExprDefined in ghc-10.0.0.20260917 · GHC.Cmm.Expr
  • Eq CmmLitDefined in ghc-10.0.0.20260917 · GHC.Cmm.Expr
  • Eq TransferDefined in ghc-10.0.0.20260917 · GHC.Cmm.Graph
  • Eq CAFfyLabelDefined in ghc-10.0.0.20260917 · GHC.Cmm.Info.Build
  • Eq SRTEntryDefined in ghc-10.0.0.20260917 · GHC.Cmm.Info.Build
  • Eq SomeLabelDefined in ghc-10.0.0.20260917 · GHC.Cmm.Info.Build
  • Eq AtomicMachOpDefined in ghc-10.0.0.20260917 · GHC.Cmm.MachOp
  • Eq CallishMachOpDefined in ghc-10.0.0.20260917 · GHC.Cmm.MachOp
  • Eq FMASignDefined in ghc-10.0.0.20260917 · GHC.Cmm.MachOp
  • Eq MachOpDefined in ghc-10.0.0.20260917 · GHC.Cmm.MachOp
  • Eq MemoryOrderingDefined in ghc-10.0.0.20260917 · GHC.Cmm.MachOp
  • Eq CmmReturnInfoDefined in ghc-10.0.0.20260917 · GHC.Cmm.Node
  • Eq CmmTickScopeDefined in ghc-10.0.0.20260917 · GHC.Cmm.Node
  • Eq ConventionDefined in ghc-10.0.0.20260917 · GHC.Cmm.Node
  • Eq ForeignConventionDefined in ghc-10.0.0.20260917 · GHC.Cmm.Node
  • Eq ForeignTargetDefined in ghc-10.0.0.20260917 · GHC.Cmm.Node
  • Eq ReducibilityDefined in ghc-10.0.0.20260917 · GHC.Cmm.Reducibility
  • Eq CmmRegDefined in ghc-10.0.0.20260917 · GHC.Cmm.Reg
  • Eq GlobalArgRegsDefined in ghc-10.0.0.20260917 · GHC.Cmm.Reg
  • Eq GlobalRegDefined in ghc-10.0.0.20260917 · GHC.Cmm.Reg
  • Eq GlobalRegUseDefined in ghc-10.0.0.20260917 · GHC.Cmm.Reg
  • Eq LocalRegDefined in ghc-10.0.0.20260917 · GHC.Cmm.Reg
  • Eq SwitchTargetsDefined in ghc-10.0.0.20260917 · GHC.Cmm.Switch
  • Eq CmmCatDefined in ghc-10.0.0.20260917 · GHC.Cmm.Type
  • Eq ForeignHintDefined in ghc-10.0.0.20260917 · GHC.Cmm.Type
  • Eq WidthDefined in ghc-10.0.0.20260917 · GHC.Cmm.Type
  • Eq CondDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.AArch64.Cond
  • Eq DMBISHFlagsDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.AArch64.Instr
  • Eq ExtModeDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.AArch64.Instr
  • Eq OperandDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.AArch64.Instr
  • Eq ShiftModeDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.AArch64.Instr
  • Eq TargetDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.AArch64.Instr
  • Eq AddrModeDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.AArch64.Regs
  • Eq ImmDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.AArch64.Regs
  • Eq BlockChainDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.BlockLayout
  • Eq BranchInfoDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.CFG
  • Eq CfgEdgeDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.CFG

    Careful! Since we assume there is at most one edge from A to B the Eq instance does not consider weight.

  • Eq EdgeInfoDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.CFG
  • Eq EdgeWeightDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.CFG
  • Eq TransitionSourceDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.CFG
  • Eq DwarfAbbrevDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.Dwarf.Types
  • Eq FormatDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.Format
  • Eq ScalarFormatDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.Format
  • Eq CondDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.LA64.Cond
  • Eq BarrierTypeDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.LA64.Instr
  • Eq OperandDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.LA64.Instr
  • Eq AddrModeDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.LA64.Regs
  • Eq ImmDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.LA64.Regs
  • Eq ReferenceKindDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.PIC
  • Eq CondDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.PPC.Cond
  • Eq CondDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.RV64.Cond
  • Eq OperandDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.RV64.Instr
  • Eq AddrModeDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.RV64.Regs
  • Eq ImmDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.RV64.Regs
  • Eq RegDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.Reg.Graph.Base
  • Eq RegClassDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.Reg.Graph.Base
  • Eq RegSubDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.Reg.Graph.Base
  • Eq ReadingOrWritingDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.Reg.Linear.Base
  • Eq VLocDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.Reg.Linear.Base
  • Eq RegsDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.Reg.Regs
  • Eq SomeWasmTypeDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.Wasm.Types
  • Eq SymKindDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.Wasm.Types
  • Eq SymNameDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.Wasm.Types
  • Eq PaddingDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.X86.CodeGen
  • Eq StackRefDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.X86.CodeGen
  • Eq CondDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.X86.Cond
  • Eq MinMaxTypeDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.X86.Instr
  • Eq MinOrMaxDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.X86.Instr
  • Eq FixityDefined in ghc-10.0.0.20260917 · GHC.CmmToC
  • Eq SignageDefined in ghc-10.0.0.20260917 · GHC.CmmToLlvm.CodeGen
  • Eq LlvmVersionDefined in ghc-10.0.0.20260917 · GHC.CmmToLlvm.Version.Type
  • Eq AltConDefined in ghc-10.0.0.20260917 · GHC.Core
  • Eq CaseLevityDefined in ghc-10.0.0.20260917 · GHC.Core
  • Eq UnfoldingCacheDefined in ghc-10.0.0.20260917 · GHC.Core
  • Eq UnfoldingGuidanceDefined in ghc-10.0.0.20260917 · GHC.Core
  • Eq ClassDefined in ghc-10.0.0.20260917 · GHC.Core.Class
  • Eq CoAxiomRuleDefined in ghc-10.0.0.20260917 · GHC.Core.Coercion.Axiom
  • Eq ConLikeDefined in ghc-10.0.0.20260917 · GHC.Core.ConLike
  • Eq DataConDefined in ghc-10.0.0.20260917 · GHC.Core.DataCon
  • Eq StrictnessMarkDefined in ghc-10.0.0.20260917 · GHC.Core.DataCon
  • Eq JoinOccDefined in ghc-10.0.0.20260917 · GHC.Core.Lint
  • Eq StaticPtrCheckDefined in ghc-10.0.0.20260917 · GHC.Core.Lint
  • Eq IsSubmultDefined in ghc-10.0.0.20260917 · GHC.Core.Multiplicity
  • Eq ArityTypeDefined in ghc-10.0.0.20260917 · GHC.Core.Opt.Arity
  • Eq CostDefined in ghc-10.0.0.20260917 · GHC.Core.Opt.Arity
  • Eq RangeDefined in ghc-10.0.0.20260917 · GHC.Core.Opt.Range
  • Eq LevelDefined in ghc-10.0.0.20260917 · GHC.Core.Opt.SetLevels
  • Eq SimplPhaseDefined in ghc-10.0.0.20260917 · GHC.Core.Opt.Simplify.Env
  • Eq TickDefined in ghc-10.0.0.20260917 · GHC.Core.Opt.Stats
  • Eq IsRecDataConResultDefined in ghc-10.0.0.20260917 · GHC.Core.Opt.WorkWrap.Utils
  • Eq PatSynDefined in ghc-10.0.0.20260917 · GHC.Core.PatSyn
  • Eq EqRelDefined in ghc-10.0.0.20260917 · GHC.Core.Predicate
  • Eq InvisibleBitDefined in ghc-10.0.0.20260917 · GHC.Core.TyCo.Compare
  • Eq TypeOrderingDefined in ghc-10.0.0.20260917 · GHC.Core.TyCo.Compare
  • Eq CoSelDefined in ghc-10.0.0.20260917 · GHC.Core.TyCo.Rep
  • Eq FunSelDefined in ghc-10.0.0.20260917 · GHC.Core.TyCo.Rep
  • Eq TyLitDefined in ghc-10.0.0.20260917 · GHC.Core.TyCo.Rep
  • Eq UnivCoProvenanceDefined in ghc-10.0.0.20260917 · GHC.Core.TyCo.Rep
  • Eq InjectivityDefined in ghc-10.0.0.20260917 · GHC.Core.TyCon
  • Eq PrimElemRepDefined in ghc-10.0.0.20260917 · GHC.Core.TyCon
  • Eq PrimOrVoidRepDefined in ghc-10.0.0.20260917 · GHC.Core.TyCon
  • Eq PrimRepDefined in ghc-10.0.0.20260917 · GHC.Core.TyCon
  • Eq TyConDefined in ghc-10.0.0.20260917 · GHC.Core.TyCon
  • Eq BindFlagDefined in ghc-10.0.0.20260917 · GHC.Core.Unify
  • Eq HowBoundDefined in ghc-10.0.0.20260917 · GHC.CoreToStg
  • Eq LetInfoDefined in ghc-10.0.0.20260917 · GHC.CoreToStg
  • Eq BindInfoDefined in ghc-10.0.0.20260917 · GHC.CoreToStg.Prep
  • Eq FloatInfoDefined in ghc-10.0.0.20260917 · GHC.CoreToStg.Prep
  • Eq OverridingBoolDefined in ghc-10.0.0.20260917 · GHC.Data.Bool
  • Eq FastStringDefined in ghc-10.0.0.20260917 · GHC.Data.FastString
  • Eq LexicalFastStringDefined in ghc-10.0.0.20260917 · GHC.Data.FastString
  • Eq NonDetFastStringDefined in ghc-10.0.0.20260917 · GHC.Data.FastString
  • Eq EdgeTypeDefined in ghc-10.0.0.20260917 · GHC.Data.Graph.Directed
  • Eq TimeDefined in ghc-10.0.0.20260917 · GHC.Data.Graph.Directed
  • Eq UnVarSetDefined in ghc-10.0.0.20260917 · GHC.Data.Graph.UnVar
  • Eq Word64SetDefined in ghc-10.0.0.20260917 · GHC.Data.Word64Set.Internal
  • Eq BackendNameDefined in ghc-10.0.0.20260917 · GHC.Driver.Backend.Internal
  • Eq SessionTypeDefined in ghc-10.0.0.20260917 · GHC.Driver.Backpack
  • Eq CodeGenEnableDefined in ghc-10.0.0.20260917 · GHC.Driver.Downsweep
  • Eq DynLibLoaderDefined in ghc-10.0.0.20260917 · GHC.Driver.DynFlags
  • Eq DynamicTooStateDefined in ghc-10.0.0.20260917 · GHC.Driver.DynFlags
  • Eq ExecutableLinkModeDefined in ghc-10.0.0.20260917 · GHC.Driver.DynFlags
  • Eq GhcLinkDefined in ghc-10.0.0.20260917 · GHC.Driver.DynFlags
  • Eq GhcModeDefined in ghc-10.0.0.20260917 · GHC.Driver.DynFlags
  • Eq IgnorePackageFlagDefined in ghc-10.0.0.20260917 · GHC.Driver.DynFlags
  • Eq ModRenamingDefined in ghc-10.0.0.20260917 · GHC.Driver.DynFlags
  • Eq PackageArgDefined in ghc-10.0.0.20260917 · GHC.Driver.DynFlags
  • Eq PackageDBFlagDefined in ghc-10.0.0.20260917 · GHC.Driver.DynFlags
  • Eq PackageFlagDefined in ghc-10.0.0.20260917 · GHC.Driver.DynFlags
  • Eq PkgDbRefDefined in ghc-10.0.0.20260917 · GHC.Driver.DynFlags
  • Eq TrustFlagDefined in ghc-10.0.0.20260917 · GHC.Driver.DynFlags
  • Eq DeprecationDefined in ghc-10.0.0.20260917 · GHC.Driver.Flags
  • Eq DumpFlagDefined in ghc-10.0.0.20260917 · GHC.Driver.Flags
  • Eq ExtensionDeprecationDefined in ghc-10.0.0.20260917 · GHC.Driver.Flags
  • Eq GeneralFlagDefined in ghc-10.0.0.20260917 · GHC.Driver.Flags
  • Eq LanguageDefined in ghc-10.0.0.20260917 · GHC.Driver.Flags
  • Eq WarningFlagDefined in ghc-10.0.0.20260917 · GHC.Driver.Flags
  • Eq WarningGroupDefined in ghc-10.0.0.20260917 · GHC.Driver.Flags
  • Eq WorkerLimitDefined in ghc-10.0.0.20260917 · GHC.Driver.MakeAction
  • Eq PhaseDefined in ghc-10.0.0.20260917 · GHC.Driver.Phases
  • Eq AnnsModuleDefined in ghc-10.0.0.20260917 · GHC.Hs
  • Eq NamespaceSpecifierDefined in ghc-10.0.0.20260917 · GHC.Hs.Basic
  • Eq ActivationAnnDefined in ghc-10.0.0.20260917 · GHC.Hs.Binds
  • Eq HsRuleBndrsAnnDefined in ghc-10.0.0.20260917 · GHC.Hs.Binds
  • Eq HsRuleAnnDefined in ghc-10.0.0.20260917 · GHC.Hs.Decls
  • Eq OverlapFlagDefined in ghc-10.0.0.20260917 · GHC.Hs.Decls.Overlap
  • Eq HsDocStringDefined in ghc-10.0.0.20260917 · GHC.Hs.DocString
  • Eq HsDocStringChunkDefined in ghc-10.0.0.20260917 · GHC.Hs.DocString
  • Eq HsDocStringDecoratorDefined in ghc-10.0.0.20260917 · GHC.Hs.DocString
  • Eq BlankEpAnnotationsDefined in ghc-10.0.0.20260917 · GHC.Hs.Dump
  • Eq BlankSrcSpanDefined in ghc-10.0.0.20260917 · GHC.Hs.Dump
  • Eq HsLitTcDefined in ghc-10.0.0.20260917 · GHC.Hs.Lit
  • Eq SynchronicityDefined in ghc-10.0.0.20260917 · GHC.HsToCore.Foreign.Wasm
  • Eq GenerateInhabitingPatternsModeDefined in ghc-10.0.0.20260917 · GHC.HsToCore.Pmc.Solver
  • Eq BotInfoDefined in ghc-10.0.0.20260917 · GHC.HsToCore.Pmc.Solver.Types
  • Eq PmAltConDefined in ghc-10.0.0.20260917 · GHC.HsToCore.Pmc.Solver.Types

    Syntactic equality.

  • Eq PmEqualityDefined in ghc-10.0.0.20260917 · GHC.HsToCore.Pmc.Solver.Types
  • Eq PmLitDefined in ghc-10.0.0.20260917 · GHC.HsToCore.Pmc.Solver.Types

    Syntactic equality. We want (Ord PmLit) so that we can use (Set PmLit) in PmAltConSet

  • Eq PrecisionDefined in ghc-10.0.0.20260917 · GHC.HsToCore.Pmc.Types
  • Eq TickDensityDefined in ghc-10.0.0.20260917 · GHC.HsToCore.Ticks
  • Eq TickishTypeDefined in ghc-10.0.0.20260917 · GHC.HsToCore.Ticks
  • Eq CheckHiWayDefined in ghc-10.0.0.20260917 · GHC.Iface.Binary
  • Eq CompressionIFaceDefined in ghc-10.0.0.20260917 · GHC.Iface.Binary
  • Eq BuildingCabalPackageDefined in ghc-10.0.0.20260917 · GHC.Iface.Errors.Types
  • Eq BindTypeDefined in ghc-10.0.0.20260917 · GHC.Iface.Ext.Types
  • Eq ContextInfoDefined in ghc-10.0.0.20260917 · GHC.Iface.Ext.Types
  • Eq DeclTypeDefined in ghc-10.0.0.20260917 · GHC.Iface.Ext.Types
  • Eq EntityInfoDefined in ghc-10.0.0.20260917 · GHC.Iface.Ext.Types
  • Eq EvBindDepsDefined in ghc-10.0.0.20260917 · GHC.Iface.Ext.Types
  • Eq EvVarSourceDefined in ghc-10.0.0.20260917 · GHC.Iface.Ext.Types
  • Eq HieNameDefined in ghc-10.0.0.20260917 · GHC.Iface.Ext.Types
  • Eq HieTypeFixDefined in ghc-10.0.0.20260917 · GHC.Iface.Ext.Types
  • Eq IETypeDefined in ghc-10.0.0.20260917 · GHC.Iface.Ext.Types
  • Eq NodeAnnotationDefined in ghc-10.0.0.20260917 · GHC.Iface.Ext.Types
  • Eq NodeOriginDefined in ghc-10.0.0.20260917 · GHC.Iface.Ext.Types
  • Eq RecFieldContextDefined in ghc-10.0.0.20260917 · GHC.Iface.Ext.Types
  • Eq ScopeDefined in ghc-10.0.0.20260917 · GHC.Iface.Ext.Types
  • Eq TyVarScopeDefined in ghc-10.0.0.20260917 · GHC.Iface.Ext.Types
  • Eq CompileReasonDefined in ghc-10.0.0.20260917 · GHC.Iface.Recomp
  • Eq RecompReasonDefined in ghc-10.0.0.20260917 · GHC.Iface.Recomp
  • Eq RecompileRequiredDefined in ghc-10.0.0.20260917 · GHC.Iface.Recomp
  • Eq IfaceBooleanFormulaDefined in ghc-10.0.0.20260917 · GHC.Iface.Syntax
  • Eq UnfoldingExposureDefined in ghc-10.0.0.20260917 · GHC.Iface.Tidy
  • Eq IfLclNameDefined in ghc-10.0.0.20260917 · GHC.Iface.Type
  • Eq IfaceAppArgsDefined in ghc-10.0.0.20260917 · GHC.Iface.Type
  • Eq IfaceAxiomRuleDefined in ghc-10.0.0.20260917 · GHC.Iface.Type
  • Eq IfaceBndrDefined in ghc-10.0.0.20260917 · GHC.Iface.Type
  • Eq IfaceCoercionDefined in ghc-10.0.0.20260917 · GHC.Iface.Type
  • Eq IfaceMCoercionDefined in ghc-10.0.0.20260917 · GHC.Iface.Type
  • Eq IfaceTyConDefined in ghc-10.0.0.20260917 · GHC.Iface.Type
  • Eq IfaceTyConInfoDefined in ghc-10.0.0.20260917 · GHC.Iface.Type
  • Eq IfaceTyConSortDefined in ghc-10.0.0.20260917 · GHC.Iface.Type
  • Eq IfaceTyLitDefined in ghc-10.0.0.20260917 · GHC.Iface.Type
  • Eq IfaceTypeDefined in ghc-10.0.0.20260917 · GHC.Iface.Type
  • Eq TupleOrSumDefined in ghc-10.0.0.20260917 · GHC.Iface.Type
  • Eq IdentDefined in ghc-10.0.0.20260917 · GHC.JS.Ident
  • Eq AOpDefined in ghc-10.0.0.20260917 · GHC.JS.JStg.Syntax
  • Eq JStgExprDefined in ghc-10.0.0.20260917 · GHC.JS.JStg.Syntax
  • Eq JStgStatDefined in ghc-10.0.0.20260917 · GHC.JS.JStg.Syntax
  • Eq JValDefined in ghc-10.0.0.20260917 · GHC.JS.JStg.Syntax
  • Eq OpDefined in ghc-10.0.0.20260917 · GHC.JS.JStg.Syntax
  • Eq UOpDefined in ghc-10.0.0.20260917 · GHC.JS.JStg.Syntax
  • Eq MultiplicityDefined in ghc-10.0.0.20260917 · GHC.JS.Opt.Simple
  • Eq VarDeclDefined in ghc-10.0.0.20260917 · GHC.JS.Opt.Simple
  • Eq AOpDefined in ghc-10.0.0.20260917 · GHC.JS.Syntax
  • Eq JExprDefined in ghc-10.0.0.20260917 · GHC.JS.Syntax
  • Eq JStatDefined in ghc-10.0.0.20260917 · GHC.JS.Syntax
  • Eq JValDefined in ghc-10.0.0.20260917 · GHC.JS.Syntax
  • Eq OpDefined in ghc-10.0.0.20260917 · GHC.JS.Syntax
  • Eq UOpDefined in ghc-10.0.0.20260917 · GHC.JS.Syntax
  • Eq MetaAnnotDefined in ghc-10.0.0.20260917 · GHC.Llvm.MetaData
  • Eq MetaExprDefined in ghc-10.0.0.20260917 · GHC.Llvm.MetaData
  • Eq MetaIdDefined in ghc-10.0.0.20260917 · GHC.Llvm.MetaData
  • Eq LlvmAtomicOpDefined in ghc-10.0.0.20260917 · GHC.Llvm.Syntax
  • Eq LlvmExpressionDefined in ghc-10.0.0.20260917 · GHC.Llvm.Syntax
  • Eq LlvmStatementDefined in ghc-10.0.0.20260917 · GHC.Llvm.Syntax
  • Eq LlvmSyncOrderingDefined in ghc-10.0.0.20260917 · GHC.Llvm.Syntax
  • Eq LMConstDefined in ghc-10.0.0.20260917 · GHC.Llvm.Types
  • Eq LlvmCallConventionDefined in ghc-10.0.0.20260917 · GHC.Llvm.Types
  • Eq LlvmCallTypeDefined in ghc-10.0.0.20260917 · GHC.Llvm.Types
  • Eq LlvmCastOpDefined in ghc-10.0.0.20260917 · GHC.Llvm.Types
  • Eq LlvmCmpOpDefined in ghc-10.0.0.20260917 · GHC.Llvm.Types
  • Eq LlvmFuncAttrDefined in ghc-10.0.0.20260917 · GHC.Llvm.Types
  • Eq LlvmFunctionDeclDefined in ghc-10.0.0.20260917 · GHC.Llvm.Types
  • Eq LlvmLinkageTypeDefined in ghc-10.0.0.20260917 · GHC.Llvm.Types
  • Eq LlvmLitDefined in ghc-10.0.0.20260917 · GHC.Llvm.Types
  • Eq LlvmMachOpDefined in ghc-10.0.0.20260917 · GHC.Llvm.Types
  • Eq LlvmParamAttrDefined in ghc-10.0.0.20260917 · GHC.Llvm.Types
  • Eq LlvmParameterListTypeDefined in ghc-10.0.0.20260917 · GHC.Llvm.Types
  • Eq LlvmTypeDefined in ghc-10.0.0.20260917 · GHC.Llvm.Types
  • Eq LlvmVarDefined in ghc-10.0.0.20260917 · GHC.Llvm.Types
  • Eq AnnListBracketsDefined in ghc-10.0.0.20260917 · GHC.Parser.Annotation
  • Eq AnnListItemDefined in ghc-10.0.0.20260917 · GHC.Parser.Annotation
  • Eq AnnPragmaDefined in ghc-10.0.0.20260917 · GHC.Parser.Annotation
  • Eq BindTagDefined in ghc-10.0.0.20260917 · GHC.Parser.Annotation
  • Eq DeclTagDefined in ghc-10.0.0.20260917 · GHC.Parser.Annotation
  • Eq EpAnnCommentsDefined in ghc-10.0.0.20260917 · GHC.Parser.Annotation
  • Eq EpaCommentDefined in ghc-10.0.0.20260917 · GHC.Parser.Annotation
  • Eq EpaCommentTokDefined in ghc-10.0.0.20260917 · GHC.Parser.Annotation
  • Eq HasEDefined in ghc-10.0.0.20260917 · GHC.Parser.Annotation
  • Eq IsUnicodeSyntaxDefined in ghc-10.0.0.20260917 · GHC.Parser.Annotation
  • Eq NameAdornmentDefined in ghc-10.0.0.20260917 · GHC.Parser.Annotation
  • Eq NameAnnDefined in ghc-10.0.0.20260917 · GHC.Parser.Annotation
  • Eq NoEpAnnsDefined in ghc-10.0.0.20260917 · GHC.Parser.Annotation
  • Eq TrailingAnnDefined in ghc-10.0.0.20260917 · GHC.Parser.Annotation
  • Eq LexErrDefined in ghc-10.0.0.20260917 · GHC.Parser.Errors.Types
  • Eq LexErrKindDefined in ghc-10.0.0.20260917 · GHC.Parser.Errors.Types
  • Eq NumUnderscoreReasonDefined in ghc-10.0.0.20260917 · GHC.Parser.Errors.Types
  • Eq ParseContextDefined in ghc-10.0.0.20260917 · GHC.Parser.Errors.Types
  • Eq PatIncompleteDoBlockDefined in ghc-10.0.0.20260917 · GHC.Parser.Errors.Types
  • Eq StringLexErrorDefined in ghc-10.0.0.20260917 · GHC.Parser.String
  • Eq BmiVersionDefined in ghc-10.0.0.20260917 · GHC.Platform
  • Eq PlatformDefined in ghc-10.0.0.20260917 · GHC.Platform
  • Eq PlatformWordSizeDefined in ghc-10.0.0.20260917 · GHC.Platform
  • Eq SseAvxVersionDefined in ghc-10.0.0.20260917 · GHC.Platform
  • Eq PlatformConstantsDefined in ghc-10.0.0.20260917 · GHC.Platform.Constants
  • Eq ProfileDefined in ghc-10.0.0.20260917 · GHC.Platform.Profile
  • Eq RealRegDefined in ghc-10.0.0.20260917 · GHC.Platform.Reg
  • Eq RegDefined in ghc-10.0.0.20260917 · GHC.Platform.Reg
  • Eq VirtualRegDefined in ghc-10.0.0.20260917 · GHC.Platform.Reg
  • Eq RegArchDefined in ghc-10.0.0.20260917 · GHC.Platform.Reg.Class
  • Eq RegClassDefined in ghc-10.0.0.20260917 · GHC.Platform.Reg.Class
  • Eq WayDefined in ghc-10.0.0.20260917 · GHC.Platform.Ways
  • Eq ArgDescrDefined in ghc-10.0.0.20260917 · GHC.Runtime.Heap.Layout
  • Eq ClosureTypeInfoDefined in ghc-10.0.0.20260917 · GHC.Runtime.Heap.Layout
  • Eq SMRepDefined in ghc-10.0.0.20260917 · GHC.Runtime.Heap.Layout
  • Eq StgHalfWordDefined in ghc-10.0.0.20260917 · GHC.Runtime.Heap.Layout
  • Eq StgWordDefined in ghc-10.0.0.20260917 · GHC.Runtime.Heap.Layout
  • Eq TagInfoDefined in ghc-10.0.0.20260917 · GHC.Stg.EnforceEpt.TagSig
  • Eq TagSigDefined in ghc-10.0.0.20260917 · GHC.Stg.EnforceEpt.TagSig
  • Eq StgLiftConfigDefined in ghc-10.0.0.20260917 · GHC.Stg.Lift.Config
  • Eq StgToDoDefined in ghc-10.0.0.20260917 · GHC.Stg.Pipeline
  • Eq CounterTypeDefined in ghc-10.0.0.20260917 · GHC.Stg.Stats
  • Eq NoExtFieldSilentDefined in ghc-10.0.0.20260917 · GHC.Stg.Syntax
  • Eq UpdateFlagDefined in ghc-10.0.0.20260917 · GHC.Stg.Syntax
  • Eq DiscrDefined in ghc-10.0.0.20260917 · GHC.StgToByteCode
  • Eq ArgRepDefined in ghc-10.0.0.20260917 · GHC.StgToCmm.ArgRep
  • Eq StandardFormInfoDefined in ghc-10.0.0.20260917 · GHC.StgToCmm.Types
  • Eq ApplyConvDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Apply
  • Eq ApplySpecDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Apply
  • Eq BlockRefDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Object
  • Eq ExportedFunDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Object
  • Eq JSOptionsDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Object
  • Eq ObjectKindDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Object
  • Eq SpecialDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Regs
  • Eq StgRegDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Regs
  • Eq StgRetDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Regs
  • Eq CILayoutDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Eq CIRegsDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Eq CIStaticDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Eq CITypeDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Eq ClosureInfoDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Eq ClosureTypeDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Eq ExpFunDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Eq ExprResultDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Eq ExprValDataDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Eq IdKeyDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Eq IdTypeDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Eq JSFFITypeDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Eq JSRepDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Eq OtherSymbDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Eq StackSlotDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Eq StaticAppKindDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Eq StaticArgDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Eq StaticInfoDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Eq StaticLitDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Eq StaticUnboxedDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Eq StaticValDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Eq ThreadStatusDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Eq SlotCountDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Utils
  • Eq ArchiveDefined in ghc-10.0.0.20260917 · GHC.SysTools.Ar
  • Eq ArchiveEntryDefined in ghc-10.0.0.20260917 · GHC.SysTools.Ar
  • Eq SourceCodePreprocessorDefined in ghc-10.0.0.20260917 · GHC.SysTools.Tasks
  • Eq HoleFitSortingAlgDefined in ghc-10.0.0.20260917 · GHC.Tc.Errors.Hole
  • Eq HoleFitCandidateDefined in ghc-10.0.0.20260917 · GHC.Tc.Errors.Hole.FitTypes
  • Eq TcHoleFitDefined in ghc-10.0.0.20260917 · GHC.Tc.Errors.Hole.FitTypes
  • Eq AssociatedTyLastVarInKindDefined in ghc-10.0.0.20260917 · GHC.Tc.Errors.Types
  • Eq AssociatedTyNotParamOverLastTyVarDefined in ghc-10.0.0.20260917 · GHC.Tc.Errors.Types
  • Eq DeriveAnyClassEnabledDefined in ghc-10.0.0.20260917 · GHC.Tc.Errors.Types
  • Eq ExportedDefined in ghc-10.0.0.20260917 · GHC.Tc.Errors.Types
  • Eq HasAssociatedDataFamInstsDefined in ghc-10.0.0.20260917 · GHC.Tc.Errors.Types
  • Eq HasKindsDefined in ghc-10.0.0.20260917 · GHC.Tc.Errors.Types
  • Eq HasWildcardDefined in ghc-10.0.0.20260917 · GHC.Tc.Errors.Types
  • Eq SuggestPartialTypeSignaturesDefined in ghc-10.0.0.20260917 · GHC.Tc.Errors.Types
  • Eq SuggestUndecidableInstancesDefined in ghc-10.0.0.20260917 · GHC.Tc.Errors.Types
  • Eq UnsupportedCallConventionDefined in ghc-10.0.0.20260917 · GHC.Tc.Errors.Types
  • Eq UsingGeneralizedNewtypeDerivingDefined in ghc-10.0.0.20260917 · GHC.Tc.Errors.Types
  • Eq WhatLookingDefined in ghc-10.0.0.20260917 · GHC.Tc.Errors.Types
  • Eq WhereToLookDefined in ghc-10.0.0.20260917 · GHC.Tc.Solver.InertSet
  • Eq IsPrefixConGADTDefined in ghc-10.0.0.20260917 · GHC.Tc.TyCl
  • Eq DocLocDefined in ghc-10.0.0.20260917 · GHC.Tc.Types
  • Eq CheckTyEqProblemDefined in ghc-10.0.0.20260917 · GHC.Tc.Types.Constraint
  • Eq CtFlavourDefined in ghc-10.0.0.20260917 · GHC.Tc.Types.Constraint
  • Eq HasGivenEqsDefined in ghc-10.0.0.20260917 · GHC.Tc.Types.Constraint
  • Eq SubGoalDepthDefined in ghc-10.0.0.20260917 · GHC.Tc.Types.CtLoc
  • Eq ReportRedundantConstraintsDefined in ghc-10.0.0.20260917 · GHC.Tc.Types.ErrCtxt
  • Eq UserTypeCtxtDefined in ghc-10.0.0.20260917 · GHC.Tc.Types.ErrCtxt
  • Eq SimpleUnifyResultDefined in ghc-10.0.0.20260917 · GHC.Tc.Utils.Unify
  • Eq TypeOrKindCtxtDefined in ghc-10.0.0.20260917 · GHC.Tc.Validity
  • Eq DetOrdAvailsDefined in ghc-10.0.0.20260917 · GHC.Types.Avail
  • Eq AlignmentDefined in ghc-10.0.0.20260917 · GHC.Types.Basic
  • Eq CbvMarkDefined in ghc-10.0.0.20260917 · GHC.Types.Basic
  • Eq DoPmcDefined in ghc-10.0.0.20260917 · GHC.Types.Basic
  • Eq FunctionOrDataDefined in ghc-10.0.0.20260917 · GHC.Types.Basic
  • Eq GenReasonDefined in ghc-10.0.0.20260917 · GHC.Types.Basic
  • Eq ImportLevelDefined in ghc-10.0.0.20260917 · GHC.Types.Basic
  • Eq InsideLamDefined in ghc-10.0.0.20260917 · GHC.Types.Basic
  • Eq IntWithInfDefined in ghc-10.0.0.20260917 · GHC.Types.Basic
  • Eq InterestingCxtDefined in ghc-10.0.0.20260917 · GHC.Types.Basic
  • Eq LeftOrRightDefined in ghc-10.0.0.20260917 · GHC.Types.Basic
  • Eq LevityDefined in ghc-10.0.0.20260917 · GHC.Types.Basic
  • Eq NewOrDataDefined in ghc-10.0.0.20260917 · GHC.Types.Basic
  • Eq OccInfoDefined in ghc-10.0.0.20260917 · GHC.Types.Basic
  • Eq OneShotInfoDefined in ghc-10.0.0.20260917 · GHC.Types.Basic
  • Eq OriginDefined in ghc-10.0.0.20260917 · GHC.Types.Basic
  • Eq PprPrecDefined in ghc-10.0.0.20260917 · GHC.Types.Basic
  • Eq RecFlagDefined in ghc-10.0.0.20260917 · GHC.Types.Basic
  • Eq SwapFlagDefined in ghc-10.0.0.20260917 · GHC.Types.Basic
  • Eq TailCallInfoDefined in ghc-10.0.0.20260917 · GHC.Types.Basic
  • Eq TupleSortDefined in ghc-10.0.0.20260917 · GHC.Types.Basic
  • Eq TypeOrConstraintDefined in ghc-10.0.0.20260917 · GHC.Types.Basic
  • Eq TypeOrDataDefined in ghc-10.0.0.20260917 · GHC.Types.Basic
  • Eq TypeOrKindDefined in ghc-10.0.0.20260917 · GHC.Types.Basic
  • Eq UnboxedTupleOrSumDefined in ghc-10.0.0.20260917 · GHC.Types.Basic
  • Eq CCFlavourDefined in ghc-10.0.0.20260917 · GHC.Types.CostCentre
  • Eq CostCentreDefined in ghc-10.0.0.20260917 · GHC.Types.CostCentre
  • Eq CostCentreStackDefined in ghc-10.0.0.20260917 · GHC.Types.CostCentre
  • Eq IndexedCCFlavourDefined in ghc-10.0.0.20260917 · GHC.Types.CostCentre
  • Eq CostCentreIndexDefined in ghc-10.0.0.20260917 · GHC.Types.CostCentre.State
  • Eq CprDefined in ghc-10.0.0.20260917 · GHC.Types.Cpr
  • Eq CprSigDefined in ghc-10.0.0.20260917 · GHC.Types.Cpr
  • Eq CprTypeDefined in ghc-10.0.0.20260917 · GHC.Types.Cpr
  • Eq DefaultProvenanceDefined in ghc-10.0.0.20260917 · GHC.Types.DefaultEnv
  • Eq CardDefined in ghc-10.0.0.20260917 · GHC.Types.Demand
  • Eq DemandDefined in ghc-10.0.0.20260917 · GHC.Types.Demand
  • Eq DivergenceDefined in ghc-10.0.0.20260917 · GHC.Types.Demand
  • Eq DmdEnvDefined in ghc-10.0.0.20260917 · GHC.Types.Demand
  • Eq DmdSigDefined in ghc-10.0.0.20260917 · GHC.Types.Demand
  • Eq DmdTypeDefined in ghc-10.0.0.20260917 · GHC.Types.Demand

    See Note [Demand env Equality].

  • Eq SubDemandDefined in ghc-10.0.0.20260917 · GHC.Types.Demand

    We have to respect Poly rewrites through viewCall and viewProd.

  • Eq DiagnosticCodeDefined in ghc-10.0.0.20260917 · GHC.Types.Error
  • Eq DiagnosticReasonDefined in ghc-10.0.0.20260917 · GHC.Types.Error
  • Eq SeverityDefined in ghc-10.0.0.20260917 · GHC.Types.Error
  • Eq DuplicateRecordFieldsDefined in ghc-10.0.0.20260917 · GHC.Types.FieldLabel
  • Eq FieldLabelDefined in ghc-10.0.0.20260917 · GHC.Types.FieldLabel
  • Eq FieldSelectorsDefined in ghc-10.0.0.20260917 · GHC.Types.FieldLabel
  • Eq CCallSpecDefined in ghc-10.0.0.20260917 · GHC.Types.ForeignCall
  • Eq CCallStaticTargetUnitDefined in ghc-10.0.0.20260917 · GHC.Types.ForeignCall
  • Eq CTypeGhcDefined in ghc-10.0.0.20260917 · GHC.Types.ForeignCall
  • Eq ForeignCallDefined in ghc-10.0.0.20260917 · GHC.Types.ForeignCall
  • Eq StaticTargetGhcDefined in ghc-10.0.0.20260917 · GHC.Types.ForeignCall
  • Eq ConFieldInfoDefined in ghc-10.0.0.20260917 · GHC.Types.GREInfo
  • Eq ConInfoDefined in ghc-10.0.0.20260917 · GHC.Types.GREInfo
  • Eq ConLikeInfoDefined in ghc-10.0.0.20260917 · GHC.Types.GREInfo
  • Eq ConLikeNameDefined in ghc-10.0.0.20260917 · GHC.Types.GREInfo
  • Eq RecFieldInfoDefined in ghc-10.0.0.20260917 · GHC.Types.GREInfo
  • Eq AssumedDerivingStrategyDefined in ghc-10.0.0.20260917 · GHC.Types.Hint
  • Eq SemaphoreUpgradeTargetDefined in ghc-10.0.0.20260917 · GHC.Types.Hint
  • Eq CafInfoDefined in ghc-10.0.0.20260917 · GHC.Types.Id.Info
  • Eq RecSelParentDefined in ghc-10.0.0.20260917 · GHC.Types.Id.Info
  • Eq CompilerPhaseDefined in ghc-10.0.0.20260917 · GHC.Types.InlinePragma
  • Eq InlineSaturationDefined in ghc-10.0.0.20260917 · GHC.Types.InlinePragma
  • Eq XInlinePragmaGhcDefined in ghc-10.0.0.20260917 · GHC.Types.InlinePragma
  • Eq XXActivationGhcDefined in ghc-10.0.0.20260917 · GHC.Types.InlinePragma
  • Eq LitNumTypeDefined in ghc-10.0.0.20260917 · GHC.Types.Literal
  • Eq LiteralDefined in ghc-10.0.0.20260917 · GHC.Types.Literal
  • Eq LitFloatingDefined in ghc-10.0.0.20260917 · GHC.Types.Literal.Floating

    This instance intentionally disagrees with the equality predicate (==) on Float or Double values: It is reflexive even on NaNs and distinguishes between positive and negative zero. Use litFloatingComparisonOp if you need to match Float or Double.

  • Eq LitFloatingTypeDefined in ghc-10.0.0.20260917 · GHC.Types.Literal.Floating
  • Eq NameDefined in ghc-10.0.0.20260917 · GHC.Types.Name

    The same comments as for Name's Ord instance apply.

  • Eq NameSpaceDefined in ghc-10.0.0.20260917 · GHC.Types.Name.Occurrence
  • Eq OccNameDefined in ghc-10.0.0.20260917 · GHC.Types.Name.Occurrence
  • Eq FieldsOrSelectorsDefined in ghc-10.0.0.20260917 · GHC.Types.Name.Reader
  • Eq ImpDeclSpecDefined in ghc-10.0.0.20260917 · GHC.Types.Name.Reader
  • Eq ImpItemSpecDefined in ghc-10.0.0.20260917 · GHC.Types.Name.Reader
  • Eq ImportSpecDefined in ghc-10.0.0.20260917 · GHC.Types.Name.Reader
  • Eq ParentDefined in ghc-10.0.0.20260917 · GHC.Types.Name.Reader
  • Eq ParentGREDefined in ghc-10.0.0.20260917 · GHC.Types.Name.Reader
  • Eq RdrNameDefined in ghc-10.0.0.20260917 · GHC.Types.Name.Reader
  • Eq PkgQualDefined in ghc-10.0.0.20260917 · GHC.Types.PkgQual
  • Eq ProfAutoDefined in ghc-10.0.0.20260917 · GHC.Types.ProfAuto
  • Eq SlotTyDefined in ghc-10.0.0.20260917 · GHC.Types.RepType
  • Eq SafeHaskellModeDefined in ghc-10.0.0.20260917 · GHC.Types.SafeHaskell
  • Eq SaneDoubleDefined in ghc-10.0.0.20260917 · GHC.Types.SaneDouble
  • Eq HsBootOrSigDefined in ghc-10.0.0.20260917 · GHC.Types.SourceFile
  • Eq HscSourceDefined in ghc-10.0.0.20260917 · GHC.Types.SourceFile
  • Eq FractionalExponentBaseDefined in ghc-10.0.0.20260917 · GHC.Types.SourceText
  • Eq FractionalLitDefined in ghc-10.0.0.20260917 · GHC.Types.SourceText

    Be wary of using this instance to compare for equal *values* when exponents are large. The same value expressed in different syntactic form won't compare as equal when any of the exponents is >= 100.

  • Eq IntegralLitDefined in ghc-10.0.0.20260917 · GHC.Types.SourceText
  • Eq SourceTextDefined in ghc-10.0.0.20260917 · GHC.Types.SourceText
  • Eq StringLiteralDefined in ghc-10.0.0.20260917 · GHC.Types.SourceText
  • Eq BufPosDefined in ghc-10.0.0.20260917 · GHC.Types.SrcLoc
  • Eq BufSpanDefined in ghc-10.0.0.20260917 · GHC.Types.SrcLoc
  • Eq DeltaPosDefined in ghc-10.0.0.20260917 · GHC.Types.SrcLoc
  • Eq GeneratedSrcSpanDetailsDefined in ghc-10.0.0.20260917 · GHC.Types.SrcLoc
  • Eq NoCommentsDefined in ghc-10.0.0.20260917 · GHC.Types.SrcLoc
  • Eq PsLocDefined in ghc-10.0.0.20260917 · GHC.Types.SrcLoc
  • Eq PsSpanDefined in ghc-10.0.0.20260917 · GHC.Types.SrcLoc
  • Eq RealSrcLocDefined in ghc-10.0.0.20260917 · GHC.Types.SrcLoc
  • Eq RealSrcSpanDefined in ghc-10.0.0.20260917 · GHC.Types.SrcLoc
  • Eq SrcLocDefined in ghc-10.0.0.20260917 · GHC.Types.SrcLoc
  • Eq SrcSpanDefined in ghc-10.0.0.20260917 · GHC.Types.SrcLoc
  • Eq UnhelpfulSpanReasonDefined in ghc-10.0.0.20260917 · GHC.Types.SrcLoc
  • Eq TargetIdDefined in ghc-10.0.0.20260917 · GHC.Types.Target
  • Eq ThLevelIndexDefined in ghc-10.0.0.20260917 · GHC.Types.ThLevelIndex
  • Eq BreakpointIdDefined in ghc-10.0.0.20260917 · GHC.Types.Tickish
  • Eq TickishPlacementDefined in ghc-10.0.0.20260917 · GHC.Types.Tickish
  • Eq UniqueDefined in ghc-10.0.0.20260917 · GHC.Types.Unique
  • Eq UniqueTagDefined in ghc-10.0.0.20260917 · GHC.Types.Unique
  • Eq UniqueSetDefined in ghc-10.0.0.20260917 · GHC.Types.Unique.Set
  • Eq FunTyFlagDefined in ghc-10.0.0.20260917 · GHC.Types.Var
  • Eq VarDefined in ghc-10.0.0.20260917 · GHC.Types.Var
  • Eq PackageIdDefined in ghc-10.0.0.20260917 · GHC.Unit.Info
  • Eq PackageNameDefined in ghc-10.0.0.20260917 · GHC.Unit.Info
  • Eq DependenciesDefined in ghc-10.0.0.20260917 · GHC.Unit.Module.Deps
  • Eq HomeModImportDefined in ghc-10.0.0.20260917 · GHC.Unit.Module.Deps
  • Eq HomeModImportedAvailsDefined in ghc-10.0.0.20260917 · GHC.Unit.Module.Deps
  • Eq IfaceImportLevelDefined in ghc-10.0.0.20260917 · GHC.Unit.Module.Deps
  • Eq UsageDefined in ghc-10.0.0.20260917 · GHC.Unit.Module.Deps
  • Eq NDModuleDefined in ghc-10.0.0.20260917 · GHC.Unit.Module.Env
  • Eq ModuleGraphInvariantErrorDefined in ghc-10.0.0.20260917 · GHC.Unit.Module.Graph
  • Eq ModuleGraphNodeDefined in ghc-10.0.0.20260917 · GHC.Unit.Module.Graph
  • Eq NodeKeyDefined in ghc-10.0.0.20260917 · GHC.Unit.Module.Graph
  • Eq ZeroScopeKeyDefined in ghc-10.0.0.20260917 · GHC.Unit.Module.Graph
  • Eq ModNodeKeyWithUidDefined in ghc-10.0.0.20260917 · GHC.Unit.Module.ModNodeKey
  • Eq ModuleStageDefined in ghc-10.0.0.20260917 · GHC.Unit.Module.Stage
  • Eq IsTrustedDefined in ghc-10.0.0.20260917 · GHC.Unit.State
  • Eq UnitIdDefined in ghc-10.0.0.20260917 · GHC.Unit.Types
  • Eq BindingNameDefined in ghc-10.0.0.20260917 · GHC.Utils.Binary
  • Eq FullBinDataDefined in ghc-10.0.0.20260917 · GHC.Utils.Binary
  • Eq OptionDefined in ghc-10.0.0.20260917 · GHC.Utils.CliOption
  • Eq PrintTimingsDefined in ghc-10.0.0.20260917 · GHC.Utils.Error
  • Eq DumpFormatDefined in ghc-10.0.0.20260917 · GHC.Utils.Logger
  • Eq BindingSiteDefined in ghc-10.0.0.20260917 · GHC.Utils.Outputable
  • Eq JoinPointHoodDefined in ghc-10.0.0.20260917 · GHC.Utils.Outputable
  • Eq BoxityDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Basic
  • Eq FieldLabelStringDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Basic
  • Eq FixityDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Basic
  • Eq FixityDirectionDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Basic
  • Eq LexicalFixityDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Basic
  • Eq RoleDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Basic
  • Eq SrcStrictnessDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Basic
  • Eq SrcUnpackednessDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Basic
  • Eq InlineSpecDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Binds.InlinePragma
  • Eq RuleMatchInfoDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Binds.InlinePragma
  • Eq SpliceDecorationDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Decls
  • Eq WarningCategoryDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Decls
  • Eq CCallConvDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Decls.Foreign
  • Eq ForeignKindDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Decls.Foreign
  • Eq SafetyDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Decls.Foreign
  • Eq HsDoFlavourDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Expr
  • Eq HsLamVariantDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Expr
  • Eq DataConCantHappenDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Extension
  • Eq NoExtFieldDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Extension
  • Eq IEWildcardDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.ImpExp
  • Eq ImportDeclLevelDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.ImpExp
  • Eq ImportDeclLevelStyleDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.ImpExp
  • Eq ImportDeclQualifiedStyleDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.ImpExp
  • Eq ImportListInterpretationDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.ImpExp
  • Eq IsBootInterfaceDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.ImpExp.IsBoot
  • Eq OverLitValDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Lit
  • Eq QualLitValDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Lit
  • Eq ModuleNameDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Module.Name
  • Eq RecFieldsDotDotDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Pat
  • Eq ForAllTyFlagDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Specificity
  • Eq SpecificityDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Specificity
  • Eq HsIPNameDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Type
  • Eq PromotionFlagDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Type
  • Eq ShortTextDefined in ghc-boot-10.0.0.20260917 · GHC.Data.ShortText
  • Eq DbInstUnitIdDefined in ghc-boot-10.0.0.20260917 · GHC.Unit.Database
  • Eq DbModuleDefined in ghc-boot-10.0.0.20260917 · GHC.Unit.Database
  • Eq VoidDefined in ghc-internal-10.0.0 · GHC.Internal.Base
  • Eq BigNatDefined in ghc-internal-10.0.0 · GHC.Internal.Bignum.BigNat
  • Eq IntegerDefined in ghc-internal-10.0.0 · GHC.Internal.Bignum.Integer
  • Eq NaturalDefined in ghc-internal-10.0.0 · GHC.Internal.Bignum.Natural
  • Eq ByteOrderDefined in ghc-internal-10.0.0 · GHC.Internal.ByteOrder
  • Eq ClosureTypeDefined in ghc-internal-10.0.0 · GHC.Internal.ClosureTypes
  • Eq BlockReasonDefined in ghc-internal-10.0.0 · GHC.Internal.Conc.Sync
  • Eq ThreadIdDefined in ghc-internal-10.0.0 · GHC.Internal.Conc.Sync
  • Eq ThreadStatusDefined in ghc-internal-10.0.0 · GHC.Internal.Conc.Sync
  • Eq ConstrDefined in ghc-internal-10.0.0 · GHC.Internal.Data.Data

    Equality of constructors

  • Eq ConstrRepDefined in ghc-internal-10.0.0 · GHC.Internal.Data.Data
  • Eq DataRepDefined in ghc-internal-10.0.0 · GHC.Internal.Data.Data
  • Eq FixityDefined in ghc-internal-10.0.0 · GHC.Internal.Data.Data
  • Eq AllDefined in ghc-internal-10.0.0 · GHC.Internal.Data.Semigroup.Internal
  • Eq AnyDefined in ghc-internal-10.0.0 · GHC.Internal.Data.Semigroup.Internal
  • Eq SomeTypeRepDefined in ghc-internal-10.0.0 · GHC.Internal.Data.Typeable.Internal
  • Eq UniqueDefined in ghc-internal-10.0.0 · GHC.Internal.Data.Unique
  • Eq VersionDefined in ghc-internal-10.0.0 · GHC.Internal.Data.Version
  • Eq ControlMessageDefined in ghc-internal-10.0.0 · GHC.Internal.Event.Control
  • Eq EPollFdDefined in ghc-internal-10.0.0 · GHC.Internal.Event.EPoll
  • Eq EventTypeDefined in ghc-internal-10.0.0 · GHC.Internal.Event.EPoll
  • Eq EventDefined in ghc-internal-10.0.0 · GHC.Internal.Event.Internal.Types
  • Eq EventLifetimeDefined in ghc-internal-10.0.0 · GHC.Internal.Event.Internal.Types
  • Eq LifetimeDefined in ghc-internal-10.0.0 · GHC.Internal.Event.Internal.Types
  • Eq FdKeyDefined in ghc-internal-10.0.0 · GHC.Internal.Event.Manager
  • Eq StateDefined in ghc-internal-10.0.0 · GHC.Internal.Event.Manager
  • Eq EventDefined in ghc-internal-10.0.0 · GHC.Internal.Event.Poll
  • Eq TimeoutKeyDefined in ghc-internal-10.0.0 · GHC.Internal.Event.TimeOut
  • Eq StateDefined in ghc-internal-10.0.0 · GHC.Internal.Event.TimerManager
  • Eq UniqueDefined in ghc-internal-10.0.0 · GHC.Internal.Event.Unique
  • Eq ErrorCallDefined in ghc-internal-10.0.0 · GHC.Internal.Exception
  • Eq ArithExceptionDefined in ghc-internal-10.0.0 · GHC.Internal.Exception.Type
  • Eq SpecConstrAnnotationDefined in ghc-internal-10.0.0 · GHC.Internal.Exts
  • Eq FingerprintDefined in ghc-internal-10.0.0 · GHC.Internal.Fingerprint.Type
  • Eq ErrnoDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Error
  • Eq CBoolDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Eq CCharDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Eq CClockDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Eq CDoubleDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Eq CFloatDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Eq CIntDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Eq CIntMaxDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Eq CIntPtrDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Eq CLLongDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Eq CLongDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Eq CPtrdiffDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Eq CSCharDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Eq CSUSecondsDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Eq CShortDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Eq CSigAtomicDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Eq CSizeDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Eq CTimeDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Eq CUCharDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Eq CUIntDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Eq CUIntMaxDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Eq CUIntPtrDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Eq CULLongDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Eq CULongDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Eq CUSecondsDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Eq CUShortDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Eq CWcharDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Eq IntPtrDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.Ptr
  • Eq WordPtrDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.Ptr
  • Eq ForeignSrcLangDefined in ghc-internal-10.0.0 · GHC.Internal.ForeignSrcLang
  • Eq AssociativityDefined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Eq DecidedStrictnessDefined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Eq FixityDefined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Eq SourceStrictnessDefined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Eq SourceUnpackednessDefined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Eq PrimTypeDefined in ghc-internal-10.0.0 · GHC.Internal.Heap.Closures
  • Eq TsoFlagsDefined in ghc-internal-10.0.0 · GHC.Internal.Heap.Closures
  • Eq WhatNextDefined in ghc-internal-10.0.0 · GHC.Internal.Heap.Closures
  • Eq WhyBlockedDefined in ghc-internal-10.0.0 · GHC.Internal.Heap.Closures
  • Eq HalfWordDefined in ghc-internal-10.0.0 · GHC.Internal.Heap.InfoTable.Types
  • Eq StgInfoTableDefined in ghc-internal-10.0.0 · GHC.Internal.Heap.InfoTable.Types
  • Eq CostCentreDefined in ghc-internal-10.0.0 · GHC.Internal.Heap.ProfInfo.Types
  • Eq CostCentreStackDefined in ghc-internal-10.0.0 · GHC.Internal.Heap.ProfInfo.Types
  • Eq IndexTableDefined in ghc-internal-10.0.0 · GHC.Internal.Heap.ProfInfo.Types
  • Eq StgTSOProfInfoDefined in ghc-internal-10.0.0 · GHC.Internal.Heap.ProfInfo.Types
  • Eq MaskingStateDefined in ghc-internal-10.0.0 · GHC.Internal.IO
  • Eq BufferStateDefined in ghc-internal-10.0.0 · GHC.Internal.IO.Buffer
  • Eq IODeviceTypeDefined in ghc-internal-10.0.0 · GHC.Internal.IO.Device
  • Eq SeekModeDefined in ghc-internal-10.0.0 · GHC.Internal.IO.Device
  • Eq CodingProgressDefined in ghc-internal-10.0.0 · GHC.Internal.IO.Encoding.Types
  • Eq ArrayExceptionDefined in ghc-internal-10.0.0 · GHC.Internal.IO.Exception
  • Eq AsyncExceptionDefined in ghc-internal-10.0.0 · GHC.Internal.IO.Exception
  • Eq ExitCodeDefined in ghc-internal-10.0.0 · GHC.Internal.IO.Exception
  • Eq IOErrorTypeDefined in ghc-internal-10.0.0 · GHC.Internal.IO.Exception
  • Eq IOExceptionDefined in ghc-internal-10.0.0 · GHC.Internal.IO.Exception
  • Eq HandlePosnDefined in ghc-internal-10.0.0 · GHC.Internal.IO.Handle
  • Eq BufferModeDefined in ghc-internal-10.0.0 · GHC.Internal.IO.Handle.Types
  • Eq HandleDefined in ghc-internal-10.0.0 · GHC.Internal.IO.Handle.Types
  • Eq NewlineDefined in ghc-internal-10.0.0 · GHC.Internal.IO.Handle.Types
  • Eq NewlineModeDefined in ghc-internal-10.0.0 · GHC.Internal.IO.Handle.Types
  • Eq IOModeDefined in ghc-internal-10.0.0 · GHC.Internal.IO.IOMode
  • Eq IoSubSystemDefined in ghc-internal-10.0.0 · GHC.Internal.IO.SubSystem
  • Eq InfoProvDefined in ghc-internal-10.0.0 · GHC.Internal.InfoProv.Types
  • Eq Int16Defined in ghc-internal-10.0.0 · GHC.Internal.Int
  • Eq Int32Defined in ghc-internal-10.0.0 · GHC.Internal.Int
  • Eq Int64Defined in ghc-internal-10.0.0 · GHC.Internal.Int
  • Eq Int8Defined in ghc-internal-10.0.0 · GHC.Internal.Int
  • Eq ExtensionDefined in ghc-internal-10.0.0 · GHC.Internal.LanguageExtensions
  • Eq IoManagerFlagDefined in ghc-internal-10.0.0 · GHC.Internal.RTS.Flags
  • Eq ByteOffsetDefined in ghc-internal-10.0.0 · GHC.Internal.Stack.Constants
  • Eq WordOffsetDefined in ghc-internal-10.0.0 · GHC.Internal.Stack.Constants
  • Eq ByteOffsetDefined in ghc-internal-10.0.0 · GHC.Internal.Stack.ConstantsProf
  • Eq WordOffsetDefined in ghc-internal-10.0.0 · GHC.Internal.Stack.ConstantsProf
  • Eq StackEntryDefined in ghc-internal-10.0.0 · GHC.Internal.Stack.Decode
  • Eq SrcLocDefined in ghc-internal-10.0.0 · GHC.Internal.Stack.Types
  • Eq CBlkCntDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Eq CBlkSizeDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Eq CCcDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Eq CClockIdDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Eq CDevDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Eq CFsBlkCntDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Eq CFsFilCntDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Eq CGidDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Eq CIdDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Eq CInoDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Eq CKeyDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Eq CModeDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Eq CNfdsDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Eq CNlinkDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Eq COffDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Eq CPidDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Eq CRLimDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Eq CSocklenDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Eq CSpeedDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Eq CSsizeDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Eq CTcflagDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Eq CTimerDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Eq CUidDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Eq FdDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Eq AnnLookupDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Eq AnnTargetDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Eq BangDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Eq BndrVisDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Eq BodyDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Eq BytesDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Eq CallconvDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Eq ClauseDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Eq ConDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Eq DecDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Eq DecidedStrictnessDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Eq DerivClauseDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Eq DerivStrategyDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Eq DocLocDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Eq ExpDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Eq FamilyResultSigDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Eq FixityDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Eq FixityDirectionDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Eq ForeignDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Eq FunDepDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Eq GuardDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Eq InfoDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Eq InjectivityAnnDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Eq InlineDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Eq LitDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Eq LocDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Eq MatchDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Eq ModNameDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Eq ModuleDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Eq ModuleInfoDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Eq NameDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Eq NameFlavourDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Eq NameSpaceDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Eq NamespaceSpecifierDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Eq OccNameDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Eq OverlapDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Eq PatDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Eq PatSynArgsDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Eq PatSynDirDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Eq PhasesDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Eq PkgNameDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Eq PragmaDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Eq RangeDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Eq RoleDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Eq RuleBndrDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Eq RuleMatchDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Eq SafetyDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Eq SourceStrictnessDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Eq SourceUnpackednessDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Eq SpecificityDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Eq StmtDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Eq TyLitDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Eq TySynEqnDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Eq TypeDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Eq TypeFamilyHeadDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Eq LexemeDefined in ghc-internal-10.0.0 · GHC.Internal.Text.Read.Lex
  • Eq NumberDefined in ghc-internal-10.0.0 · GHC.Internal.Text.Read.Lex
  • Eq SomeCharDefined in ghc-internal-10.0.0 · GHC.Internal.TypeLits
  • Eq SomeSymbolDefined in ghc-internal-10.0.0 · GHC.Internal.TypeLits
  • Eq SomeNatDefined in ghc-internal-10.0.0 · GHC.Internal.TypeNats
  • Eq BoolDefined in ghc-internal-10.0.0 · GHC.Internal.Classes
  • Eq CharDefined in ghc-internal-10.0.0 · GHC.Internal.Classes
  • Eq DoubleDefined in ghc-internal-10.0.0 · GHC.Internal.Classes

    Note that due to the presence of NaN, Double's Eq instance does not satisfy reflexivity.

    Example1 expression
    0/0 == (0/0 :: Double)False

    Also note that Double's Eq instance does not satisfy substitutivity:

    Example2 expressions
    0 == (-0 :: Double)Truerecip 0 == recip (-0 :: Double)False
  • Eq FloatDefined in ghc-internal-10.0.0 · GHC.Internal.Classes

    Note that due to the presence of NaN, Float's Eq instance does not satisfy reflexivity.

    Example1 expression
    0/0 == (0/0 :: Float)False

    Also note that Float's Eq instance does not satisfy extensionality:

    Example2 expressions
    0 == (-0 :: Float)Truerecip 0 == recip (-0 :: Float)False
  • Eq IntDefined in ghc-internal-10.0.0 · GHC.Internal.Classes
  • Eq ModuleDefined in ghc-internal-10.0.0 · GHC.Internal.Classes
  • Eq OrderingDefined in ghc-internal-10.0.0 · GHC.Internal.Classes
  • Eq TrNameDefined in ghc-internal-10.0.0 · GHC.Internal.Classes
  • Eq TyConDefined in ghc-internal-10.0.0 · GHC.Internal.Classes
  • Eq WordDefined in ghc-internal-10.0.0 · GHC.Internal.Classes
  • Eq GeneralCategoryDefined in ghc-internal-10.0.0 · GHC.Internal.Unicode
  • Eq Word16Defined in ghc-internal-10.0.0 · GHC.Internal.Word
  • Eq Word32Defined in ghc-internal-10.0.0 · GHC.Internal.Word
  • Eq Word64Defined in ghc-internal-10.0.0 · GHC.Internal.Word
  • Eq Word8Defined in ghc-internal-10.0.0 · GHC.Internal.Word
  • Eq ArchDefined in ghc-platform-0.1.0.0 · GHC.Platform.ArchOS
  • Eq ArchOSDefined in ghc-platform-0.1.0.0 · GHC.Platform.ArchOS
  • Eq ArmABIDefined in ghc-platform-0.1.0.0 · GHC.Platform.ArchOS
  • Eq ArmISADefined in ghc-platform-0.1.0.0 · GHC.Platform.ArchOS
  • Eq ArmISAExtDefined in ghc-platform-0.1.0.0 · GHC.Platform.ArchOS
  • Eq OSDefined in ghc-platform-0.1.0.0 · GHC.Platform.ArchOS
  • Eq PPC_64ABIDefined in ghc-platform-0.1.0.0 · GHC.Platform.ArchOS
  • Eq LibraryDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Library
  • Eq ProgramDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Program
  • Eq TargetDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Target
  • Eq WordSizeDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Target
  • Eq ArDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Tools.Ar
  • Eq CcDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Tools.Cc
  • Eq CmmCppDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Tools.Cpp
  • Eq CppDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Tools.Cpp
  • Eq HsCppDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Tools.Cpp
  • Eq JsCppDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Tools.Cpp
  • Eq CxxDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Tools.Cxx
  • Eq CcLinkDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Tools.Link
  • Eq MergeObjsDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Tools.MergeObjs
  • Eq NmDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Tools.Nm
  • Eq RanlibDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Tools.Ranlib
  • Eq BoxLabelDefined in hpc-0.7.0.2 · Trace.Hpc.Mix
  • Eq CondBoxDefined in hpc-0.7.0.2 · Trace.Hpc.Mix
  • Eq MixDefined in hpc-0.7.0.2 · Trace.Hpc.Mix
  • Eq TixDefined in hpc-0.7.0.2 · Trace.Hpc.Tix
  • Eq TixModuleDefined in hpc-0.7.0.2 · Trace.Hpc.Tix
  • Eq HashDefined in hpc-0.7.0.2 · Trace.Hpc.Util
  • Eq HpcPosDefined in hpc-0.7.0.2 · Trace.Hpc.Util
  • Eq EncodingExceptionDefined in os-string-2.0.11 · System.OsString.Encoding.Internal
  • Eq OsCharDefined in os-string-2.0.11 · System.OsString.Internal.Types

    Byte equality of the internal representation.

  • Eq OsStringDefined in os-string-2.0.11 · System.OsString.Internal.Types

    Byte equality of the internal representation.

  • Eq PosixCharDefined in os-string-2.0.11 · System.OsString.Internal.Types
  • Eq PosixStringDefined in os-string-2.0.11 · System.OsString.Internal.Types
  • Eq WindowsCharDefined in os-string-2.0.11 · System.OsString.Internal.Types
  • Eq WindowsStringDefined in os-string-2.0.11 · System.OsString.Internal.Types
  • Eq ModeDefined in pretty-1.1.3.6 · Text.PrettyPrint.Annotated.HughesPJ
  • Eq StyleDefined in pretty-1.1.3.6 · Text.PrettyPrint.Annotated.HughesPJ
  • Eq TextDetailsDefined in pretty-1.1.3.6 · Text.PrettyPrint.Annotated.HughesPJ
  • Eq PrettyLevelDefined in pretty-1.1.3.6 · Text.PrettyPrint.Annotated.HughesPJClass
  • Eq DocDefined in pretty-1.1.3.6 · Text.PrettyPrint.HughesPJ
  • Eq PrettyLevelDefined in pretty-1.1.3.6 · Text.PrettyPrint.HughesPJClass
  • Eq CmdSpecDefined in process-1.6.30.0 · System.Process.Common
  • Eq CreateProcessDefined in process-1.6.30.0 · System.Process.Common
  • Eq StdStreamDefined in process-1.6.30.0 · System.Process.Common
  • Eq CommunicationHandleDefined in process-1.6.30.0 · System.Process.CommunicationHandle.Internal
  • Eq SemaphoreErrorDefined in semaphore-compat-2.0.1 · System.Semaphore.Internal.Version
  • Eq SemaphoreNameDefined in semaphore-compat-2.0.1 · System.Semaphore.Internal.Version
  • Eq SemaphoreProtocolVersionDefined in semaphore-compat-2.0.1 · System.Semaphore.Internal.Version
  • Eq TSemDefined in stm-2.5.3.1 · Control.Concurrent.STM.TSem
  • Eq UnicodeExceptionDefined in text-2.1.4 · Data.Text.Encoding.Error
  • Eq I8Defined in text-2.1.4 · Data.Text.Foreign
  • Eq TextDefined in text-2.1.4 · Data.Text · orphan
  • Eq BuilderDefined in text-2.1.4 · Data.Text.Internal.Builder
  • Eq PartialUtf8CodePointDefined in text-2.1.4 · Data.Text.Internal.Encoding
  • Eq Utf8StateDefined in text-2.1.4 · Data.Text.Internal.Encoding
  • Eq DecoderStateDefined in text-2.1.4 · Data.Text.Internal.Encoding.Utf8
  • Eq SizeDefined in text-2.1.4 · Data.Text.Internal.Fusion.Size
  • Eq TextDefined in text-2.1.4 · Data.Text.Lazy · orphan
  • Eq CalendarDiffDaysDefined in time-1.16.0.1 · Data.Time.Calendar.CalendarDiffDays
  • Eq DayDefined in time-1.16.0.1 · Data.Time.Calendar.Days
  • Eq MonthDefined in time-1.16.0.1 · Data.Time.Calendar.Month
  • Eq QuarterDefined in time-1.16.0.1 · Data.Time.Calendar.Quarter
  • Eq QuarterOfYearDefined in time-1.16.0.1 · Data.Time.Calendar.Quarter
  • Eq DayOfWeekDefined in time-1.16.0.1 · Data.Time.Calendar.Week
  • Eq FirstWeekTypeDefined in time-1.16.0.1 · Data.Time.Calendar.WeekDate
  • Eq AbsoluteTimeDefined in time-1.16.0.1 · Data.Time.Clock.Internal.AbsoluteTime
  • Eq DiffTimeDefined in time-1.16.0.1 · Data.Time.Clock.Internal.DiffTime
  • Eq NominalDiffTimeDefined in time-1.16.0.1 · Data.Time.Clock.Internal.NominalDiffTime
  • Eq SystemTimeDefined in time-1.16.0.1 · Data.Time.Clock.Internal.SystemTime
  • Eq UTCTimeDefined in time-1.16.0.1 · Data.Time.Clock.Internal.UTCTime
  • Eq UniversalTimeDefined in time-1.16.0.1 · Data.Time.Clock.Internal.UniversalTime
  • Eq TimeLocaleDefined in time-1.16.0.1 · Data.Time.Format.Locale
  • Eq WeekTypeDefined in time-1.16.0.1 · Data.Time.Format.Parse.Instances
  • Eq CalendarDiffTimeDefined in time-1.16.0.1 · Data.Time.LocalTime.Internal.CalendarDiffTime
  • Eq LocalTimeDefined in time-1.16.0.1 · Data.Time.LocalTime.Internal.LocalTime
  • Eq TimeOfDayDefined in time-1.16.0.1 · Data.Time.LocalTime.Internal.TimeOfDay
  • Eq TimeZoneDefined in time-1.16.0.1 · Data.Time.LocalTime.Internal.TimeZone
  • Eq DirTypeDefined in unix-2.8.8.0 · System.Posix.Directory.Common
  • Eq AdviceDefined in unix-2.8.8.0 · System.Posix.Fcntl
  • Eq CAttributesDefined in unix-2.8.8.0 · System.Posix.Files.Common
  • Eq StatxFlagsDefined in unix-2.8.8.0 · System.Posix.Files.Common
  • Eq StatxMaskDefined in unix-2.8.8.0 · System.Posix.Files.Common
  • Eq OpenFileFlagsDefined in unix-2.8.8.0 · System.Posix.IO.Common
  • Eq OpenModeDefined in unix-2.8.8.0 · System.Posix.IO.Common
  • Eq ProcessStatusDefined in unix-2.8.8.0 · System.Posix.Process.Internals
  • Eq ResourceDefined in unix-2.8.8.0 · System.Posix.Resource
  • Eq ResourceLimitDefined in unix-2.8.8.0 · System.Posix.Resource
  • Eq ResourceLimitsDefined in unix-2.8.8.0 · System.Posix.Resource
  • Eq BaudRateDefined in unix-2.8.8.0 · System.Posix.Terminal.Common
  • Eq GroupEntryDefined in unix-2.8.8.0 · System.Posix.User.Common
  • Eq UserEntryDefined in unix-2.8.8.0 · System.Posix.User.Common
  • Eq ()Defined in ghc-internal-10.0.0 · GHC.Internal.Classes
  • IsPass p => Eq (CCallTarget (GhcPass p))Defined in ghc-10.0.0.20260917 · GHC.Types.ForeignCall · orphan
  • IsUnitId u => Eq (GenUnit u)Defined in ghc-10.0.0.20260917 · GHC.Unit.Types
  • Eq (Chan a)Defined in base-4.23.0.0 · Control.Concurrent.Chan
  • Eq (MutableByteArray s)Defined in base-4.23.0.0 · Data.Array.Byte
  • Eq (IgnoreFormat Loc)Defined in ghc-10.0.0.20260917 · GHC.CmmToAsm.Reg.Linear.Base
  • Eq (CoAxiom br)Defined in ghc-10.0.0.20260917 · GHC.Core.Coercion.Axiom
  • Eq (DeBruijn CoreAlt)Defined in ghc-10.0.0.20260917 · GHC.Core.Map.Expr · orphan
  • Eq (DeBruijn CoreExpr)Defined in ghc-10.0.0.20260917 · GHC.Core.Map.Expr · orphan
  • Eq (DeBruijn Coercion)Defined in ghc-10.0.0.20260917 · GHC.Core.Map.Type
  • Eq (DeBruijn Type)Defined in ghc-10.0.0.20260917 · GHC.Core.Map.Type
  • Eq (DeBruijn Var)Defined in ghc-10.0.0.20260917 · GHC.Core.Map.Type
  • Eq (DeBruijn a) => Eq (DeBruijn (Maybe a))Defined in ghc-10.0.0.20260917 · GHC.Core.Map.Type
  • Eq (DeBruijn a) => Eq (DeBruijn [a])Defined in ghc-10.0.0.20260917 · GHC.Core.Map.Type
  • Eq (IEThingAllExt GhcPs)Defined in ghc-10.0.0.20260917 · GHC.Hs.Instances · orphan
  • Eq (IEThingAllExt GhcRn)Defined in ghc-10.0.0.20260917 · GHC.Hs.Instances · orphan
  • Eq (IEThingAllExt GhcTc)Defined in ghc-10.0.0.20260917 · GHC.Hs.Instances · orphan
  • Eq (IEWholeNamespaceExt GhcPs)Defined in ghc-10.0.0.20260917 · GHC.Hs.Instances · orphan
  • Eq (IEWholeNamespaceExt GhcRn)Defined in ghc-10.0.0.20260917 · GHC.Hs.Instances · orphan
  • Eq (IEWholeNamespaceExt GhcTc)Defined in ghc-10.0.0.20260917 · GHC.Hs.Instances · orphan
  • Eq (FormatReportWarningsMode ann)Defined in ghc-10.0.0.20260917 · GHC.HsToCore.Pmc
  • Eq (EpToken tok)Defined in ghc-10.0.0.20260917 · GHC.Parser.Annotation
  • Eq (CompleteMatchX con)Defined in ghc-10.0.0.20260917 · GHC.Types.CompleteMatch
  • Eq (GenTickish 'TickishPassCmm)Defined in ghc-10.0.0.20260917 · GHC.Types.Tickish
  • Eq (GenTickish 'TickishPassCore)Defined in ghc-10.0.0.20260917 · GHC.Types.Tickish
  • Eq (UniqDSet a)Defined in ghc-10.0.0.20260917 · GHC.Types.Unique.DSet
  • Eq (UniqSet a)Defined in ghc-10.0.0.20260917 · GHC.Types.Unique.Set
  • Eq (GenInstantiatedUnit unit)Defined in ghc-10.0.0.20260917 · GHC.Unit.Types
  • Eq (InWarningCategory GhcPs)Defined in ghc-10.0.0.20260917 · GHC.Unit.Module.Warnings · orphan
  • Eq (InWarningCategory GhcRn)Defined in ghc-10.0.0.20260917 · GHC.Unit.Module.Warnings · orphan
  • Eq (InWarningCategory GhcTc)Defined in ghc-10.0.0.20260917 · GHC.Unit.Module.Warnings · orphan
  • Eq (WarningTxt GhcPs)Defined in ghc-10.0.0.20260917 · GHC.Unit.Module.Warnings · orphan
  • Eq (WarningTxt GhcRn)Defined in ghc-10.0.0.20260917 · GHC.Unit.Module.Warnings · orphan
  • Eq (WarningTxt GhcTc)Defined in ghc-10.0.0.20260917 · GHC.Unit.Module.Warnings · orphan
  • Eq (Header (GhcPass p))Defined in ghc-10.0.0.20260917 · GHC.Types.ForeignCall · orphan
  • Eq (XXLit x) => Eq (HsLit x)Defined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Lit
  • Eq (XXOverLit p) => Eq (HsOverLit p)Defined in ghc-10.0.0.20260917 · GHC.Hs.Lit · orphan
  • Eq (XXQualLit p) => Eq (HsQualLit p)Defined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Lit
  • Eq (IE GhcPs)Defined in ghc-10.0.0.20260917 · GHC.Hs.Instances · orphan
  • Eq (IE GhcRn)Defined in ghc-10.0.0.20260917 · GHC.Hs.Instances · orphan
  • Eq (IE GhcTc)Defined in ghc-10.0.0.20260917 · GHC.Hs.Instances · orphan
  • Eq (IEWrappedName GhcPs)Defined in ghc-10.0.0.20260917 · GHC.Hs.ImpExp · orphan
  • Eq (IEWrappedName GhcRn)Defined in ghc-10.0.0.20260917 · GHC.Hs.ImpExp · orphan
  • Eq (IEWrappedName GhcTc)Defined in ghc-10.0.0.20260917 · GHC.Hs.ImpExp · orphan
  • Eq (ConstPtr a)Defined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.ConstPtr
  • Eq (ForeignPtr a)Defined in ghc-internal-10.0.0 · GHC.Internal.ForeignPtr
  • Eq (IORef a)Defined in ghc-internal-10.0.0 · GHC.Internal.IORef

    Pointer equality.

  • Eq (MVar a)Defined in ghc-internal-10.0.0 · GHC.Internal.MVar

    Compares the underlying pointers.

  • Eq (FunPtr a)Defined in ghc-internal-10.0.0 · GHC.Internal.Ptr
  • Eq (Ptr a)Defined in ghc-internal-10.0.0 · GHC.Internal.Ptr
  • Eq (TVar a)Defined in ghc-internal-10.0.0 · GHC.Internal.STM
  • Eq (StablePtr a)Defined in ghc-internal-10.0.0 · GHC.Internal.Stable
  • Eq (StableName a)Defined in ghc-internal-10.0.0 · GHC.Internal.StableName
  • Eq (SChar c)Defined in ghc-internal-10.0.0 · GHC.Internal.TypeLits
  • Eq (SSymbol s)Defined in ghc-internal-10.0.0 · GHC.Internal.TypeLits
  • Eq (SNat n)Defined in ghc-internal-10.0.0 · GHC.Internal.TypeNats
  • Eq (Doc a)Defined in pretty-1.1.3.6 · Text.PrettyPrint.Annotated.HughesPJ
  • Eq (TBQueue a)Defined in stm-2.5.3.1 · Control.Concurrent.STM.TBQueue
  • Eq (TChan a)Defined in stm-2.5.3.1 · Control.Concurrent.STM.TChan
  • Eq (TMVar a)Defined in stm-2.5.3.1 · Control.Concurrent.STM.TMVar
  • Eq (TQueue a)Defined in stm-2.5.3.1 · Control.Concurrent.STM.TQueue
  • Eq (TVar a)Defined in stm-2.5.3.1 · Control.Sequential.STM
  • Eq a => Eq (Complex a)Defined in base-4.23.0.0 · Data.Complex
  • Eq a => Eq (First a)Defined in base-4.23.0.0 · Data.Semigroup
  • Eq a => Eq (Last a)Defined in base-4.23.0.0 · Data.Semigroup
  • Eq a => Eq (Max a)Defined in base-4.23.0.0 · Data.Semigroup
  • Eq a => Eq (Min a)Defined in base-4.23.0.0 · Data.Semigroup
  • Eq a => Eq (IntMap a)Defined in containers-0.8 · Data.IntMap.Internal
  • Eq a => Eq (Seq a)Defined in containers-0.8 · Data.Sequence.Internal
  • Eq a => Eq (ViewL a)Defined in containers-0.8 · Data.Sequence.Internal
  • Eq a => Eq (ViewR a)Defined in containers-0.8 · Data.Sequence.Internal
  • Eq a => Eq (Intersection a)Defined in containers-0.8 · Data.Set.Internal
  • Eq a => Eq (Set a)Defined in containers-0.8 · Data.Set.Internal
  • Eq a => Eq (PostOrder a)Defined in containers-0.8 · Data.Tree
  • Eq a => Eq (Tree a)Defined in containers-0.8 · Data.Tree
  • Eq a => Eq (LPath a)Defined in ghc-10.0.0.20260917 · GHC.Data.Graph.Inductive.Graph
  • Eq a => Eq (FromListCounting a)Defined in ghc-10.0.0.20260917 · GHC.Data.Graph.Inductive.PatriciaTree
  • Eq a => Eq (Maybe a)Defined in ghc-10.0.0.20260917 · GHC.Data.Strict
  • Eq a => Eq (Word64Map a)Defined in ghc-10.0.0.20260917 · GHC.Data.Word64Map.Internal
  • Eq a => Eq (OnOff a)Defined in ghc-10.0.0.20260917 · GHC.Driver.Flags
  • Eq a => Eq (HieArgs a)Defined in ghc-10.0.0.20260917 · GHC.Iface.Ext.Types
  • Eq a => Eq (HieType a)Defined in ghc-10.0.0.20260917 · GHC.Iface.Ext.Types
  • Eq a => Eq (IdentifierDetails a)Defined in ghc-10.0.0.20260917 · GHC.Iface.Ext.Types
  • Eq a => Eq (EvidenceInfo a)Defined in ghc-10.0.0.20260917 · GHC.Iface.Ext.Utils
  • Eq a => Eq (AnnList a)Defined in ghc-10.0.0.20260917 · GHC.Parser.Annotation
  • Eq a => Eq (NonVoid a)Defined in ghc-10.0.0.20260917 · GHC.StgToCmm.Closure
  • Eq a => Eq (Branch a)Defined in ghc-10.0.0.20260917 · GHC.StgToJS.Expr
  • Eq a => Eq (EpaLocation' a)Defined in ghc-10.0.0.20260917 · GHC.Types.SrcLoc
  • Eq a => Eq (Edit a)Defined in ghc-10.0.0.20260917 · GHC.Types.Unique.FM
  • Eq a => Eq (FixedLengthEncoding a)Defined in ghc-10.0.0.20260917 · GHC.Utils.Binary
  • Eq a => Eq (DataDefnCons a)Defined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Decls
  • Eq a => Eq (NonEmpty a)Defined in ghc-internal-10.0.0 · GHC.Internal.Base
  • Eq a => Eq (And a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Bits
  • Eq a => Eq (Iff a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Bits
  • Eq a => Eq (Ior a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Bits
  • Eq a => Eq (Xor a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Bits
  • Eq a => Eq (Identity a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Functor.Identity
  • Eq a => Eq (First a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Monoid
  • Eq a => Eq (Last a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Monoid
  • Eq a => Eq (Down a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Ord
  • Eq a => Eq (Dual a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Semigroup.Internal
  • Eq a => Eq (Product a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Semigroup.Internal
  • Eq a => Eq (Sum a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Semigroup.Internal
  • Eq a => Eq (ZipList a)Defined in ghc-internal-10.0.0 · GHC.Internal.Functor.ZipList
  • Eq a => Eq (Maybe a)Defined in ghc-internal-10.0.0 · GHC.Internal.Maybe
  • Eq a => Eq (Ratio a)Defined in ghc-internal-10.0.0 · GHC.Internal.Real
  • Eq a => Eq (AnnotDetails a)Defined in pretty-1.1.3.6 · Text.PrettyPrint.Annotated.HughesPJ
  • Eq a => Eq (Span a)Defined in pretty-1.1.3.6 · Text.PrettyPrint.Annotated.HughesPJ
  • Eq a => Eq (Stream a)Defined in text-2.1.4 · Data.Text.Internal.Fusion.Types
  • Eq a => Eq (a)Defined in ghc-internal-10.0.0 · GHC.Internal.Classes
  • Eq a => Eq [a]Defined in ghc-internal-10.0.0 · GHC.Internal.Classes
  • Eq ann => Eq (EpAnn ann)Defined in ghc-10.0.0.20260917 · GHC.Parser.Annotation
  • Eq b => Eq (GroupEdges b)Defined in ghc-10.0.0.20260917 · GHC.Data.Graph.Inductive.Graph
  • Eq e => Eq (ActivationX e)Defined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Binds.InlinePragma
  • Eq flag => Eq (TyVarBndr flag)Defined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Eq m => Eq (WrappedMonoid m)Defined in base-4.23.0.0 · Data.Semigroup
  • Eq mod => Eq (GenWithIsBoot mod)Defined in ghc-10.0.0.20260917 · GHC.Unit.Types
  • Eq p => Eq (Par1 p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Eq tag => Eq (AnnSortKey tag)Defined in ghc-10.0.0.20260917 · GHC.Parser.Annotation
  • Eq tc => Eq (TyConFlavour tc)Defined in ghc-10.0.0.20260917 · GHC.Types.Basic
  • Eq unit => Eq (Definite unit)Defined in ghc-10.0.0.20260917 · GHC.Unit.Types
  • Eq unit => Eq (GenModule unit)Defined in ghc-10.0.0.20260917 · GHC.Unit.Types
  • Eq v => Eq (LabelMap v)Defined in ghc-10.0.0.20260917 · GHC.Cmm.Dataflow.Label
  • Eq val => Eq (TaggedVal val)Defined in ghc-10.0.0.20260917 · GHC.Types.Unique.DFM
  • Eq vertex => Eq (SCC vertex)Defined in containers-0.8 · Data.Graph
  • (Eq (LIdP p), Eq (LBooleanFormula p)) => Eq (BooleanFormula p)Defined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.BooleanFormula
  • (Eq (LIdP pass), Eq (XCFieldOcc pass), Eq (XXFieldOcc pass)) => Eq (FieldOcc pass)Defined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Type
  • (Eq (XOverlapMode pass), Eq (XXOverlapMode pass)) => Eq (OverlapMode pass)Defined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Decls.Overlap
  • (Eq (XXActivation pass), Eq (XInlinePragma pass), Eq (XXInlinePragma pass)) => Eq (InlinePragma pass)Defined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Binds.InlinePragma
  • Eq (IOUArray i e)Defined in array-0.5.8.0 · Data.Array.IO.Internals
  • Eq (Fixed a)Defined in base-4.23.0.0 · Data.Fixed
  • Eq (CmmNode e x)Defined in ghc-10.0.0.20260917 · GHC.Cmm.Node
  • Eq (Point s a)Defined in ghc-10.0.0.20260917 · GHC.Data.UnionFind
  • Eq (EpUniToken tok utok)Defined in ghc-10.0.0.20260917 · GHC.Parser.Annotation
  • Eq (Bin a)Defined in ghc-10.0.0.20260917 · GHC.Utils.Binary
  • Eq (RelBin a)Defined in ghc-10.0.0.20260917 · GHC.Utils.Binary
  • Eq (RelBinPtr a)Defined in ghc-10.0.0.20260917 · GHC.Utils.Binary
  • Eq (Proxy s)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Proxy
  • Eq (TypeRep a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Typeable.Internal
  • Eq (U1 p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Eq (V1 p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Eq (IOArray i e)Defined in ghc-internal-10.0.0 · GHC.Internal.IOArray
  • Eq (STRef s a)Defined in ghc-internal-10.0.0 · GHC.Internal.STRef

    Pointer equality.

  • Eq a => Eq (Arg a b)Defined in base-4.23.0.0 · Data.Semigroup

    Note that Arg's Eq instance does not satisfy extensionality:

    Example2 expressions
    Arg 0 0 == Arg 0 1Truelet f (Arg _ x) = x in f (Arg 0 0) == f (Arg 0 1)False
  • (Eq1 f, Eq a) => Eq (Lift f a)Defined in transformers-0.6.3.0 · Control.Applicative.Lift
  • (Eq1 m, Eq a) => Eq (MaybeT m a)Defined in transformers-0.6.3.0 · Control.Monad.Trans.Maybe
  • (Eq (IdP pass), Eq a) => Eq (WithHsDocIdentifiers a pass)Defined in ghc-10.0.0.20260917 · GHC.Hs.Doc
  • (Eq a, Eq b) => Eq (Pair a b)Defined in ghc-10.0.0.20260917 · GHC.Data.Strict
  • (Eq a, Eq b) => Eq (Either a b)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Either
  • (Eq a, Eq b) => Eq (a, b)Defined in ghc-internal-10.0.0 · GHC.Internal.Classes
  • (Eq a, Ord b) => Eq (Gr a b)Defined in ghc-10.0.0.20260917 · GHC.Data.Graph.Inductive.PatriciaTree
  • (Eq b, Eq r) => Eq (IfaceBindingX r b)Defined in ghc-10.0.0.20260917 · GHC.Iface.Syntax
  • (Eq i, Eq e) => Eq (TArray i e)Defined in stm-2.5.3.1 · Control.Concurrent.STM.TArray
  • (Eq k, Eq a) => Eq (Map k a)Defined in containers-0.8 · Data.Map.Internal
  • (Eq k, Eq a) => Eq (UniqMap k a)Defined in ghc-10.0.0.20260917 · GHC.Types.Unique.Map
  • (Eq l, Eq e) => Eq (GenLocated l e)Defined in ghc-10.0.0.20260917 · GHC.Types.SrcLoc
  • (Eq var, Eq argf) => Eq (VarBndr var argf)Defined in ghc-10.0.0.20260917 · GHC.Types.Var
  • (Ix i, Eq e) => Eq (Array i e)Defined in ghc-internal-10.0.0 · GHC.Internal.Arr
  • (Ix ix, Eq e, IArray UArray e) => Eq (UArray ix e)Defined in array-0.5.8.0 · Data.Array.Base
  • Eq (STUArray s i e)Defined in array-0.5.8.0 · Data.Array.Base
  • Eq (STArray s i e)Defined in ghc-internal-10.0.0 · GHC.Internal.Arr
  • Eq (Coercion a b)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Type.Coercion
  • Eq (OrderingI a b)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Type.Ord
  • Eq (URec Char p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Eq (URec Double p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Eq (URec Float p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Eq (URec Int p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Eq (URec Word p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Eq (URec (Ptr ()) p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Eq (a :~: b)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Type.Equality
  • Eq (f a) => Eq (Ap f a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Monoid
  • Eq (f a) => Eq (Alt f a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Semigroup.Internal
  • Eq (f p) => Eq (Rec1 f p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Eq a => Eq (Const a b)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Functor.Const
  • Eq a => Eq (Constant a b)Defined in transformers-0.6.3.0 · Data.Functor.Constant
  • Eq ele => Eq (UniqFM key ele)Defined in ghc-10.0.0.20260917 · GHC.Types.Unique.FM
  • (Eq1 f, Eq a) => Eq (Backwards f a)Defined in transformers-0.6.3.0 · Control.Applicative.Backwards
  • (Eq1 f, Eq a) => Eq (IdentityT f a)Defined in transformers-0.6.3.0 · Control.Monad.Trans.Identity
  • (Eq1 f, Eq a) => Eq (Reverse f a)Defined in transformers-0.6.3.0 · Data.Functor.Reverse
  • (Eq a, Eq b, Eq c) => Eq (a, b, c)Defined in ghc-internal-10.0.0 · GHC.Internal.Classes
  • (Eq e, Eq1 m, Eq a) => Eq (ExceptT e m a)Defined in transformers-0.6.3.0 · Control.Monad.Trans.Except
  • (Eq w, Eq1 m, Eq a) => Eq (WriterT w m a)Defined in transformers-0.6.3.0 · Control.Monad.Trans.Writer.Lazy
  • (Eq w, Eq1 m, Eq a) => Eq (WriterT w m a)Defined in transformers-0.6.3.0 · Control.Monad.Trans.Writer.Strict
  • (Generic1 f, Eq (Rep1 f a)) => Eq (Generically1 f a)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Eq (a :~~: b)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Type.Equality
  • Eq c => Eq (K1 i c p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • (Eq (f a), Eq (g a)) => Eq (Product f g a)Defined in base-4.23.0.0 · Data.Functor.Product
  • (Eq (f a), Eq (g a)) => Eq (Sum f g a)Defined in base-4.23.0.0 · Data.Functor.Sum
  • (Eq (f p), Eq (g p)) => Eq ((:*:) f g p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • (Eq (f p), Eq (g p)) => Eq ((:+:) f g p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • (Eq a, Eq b, Eq c, Eq d) => Eq (a, b, c, d)Defined in ghc-internal-10.0.0 · GHC.Internal.Classes
  • Eq (f (g a)) => Eq (Compose f g a)Defined in base-4.23.0.0 · Data.Functor.Compose
  • Eq (f (g p)) => Eq ((:.:) f g p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Eq (f p) => Eq (M1 i c f p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • (Graph gr, Ord a, Ord b) => Eq (OrdGr gr a b)Defined in ghc-10.0.0.20260917 · GHC.Data.Graph.Inductive.Graph
  • (Eq a, Eq b, Eq c, Eq d, Eq e) => Eq (a, b, c, d, e)Defined in ghc-internal-10.0.0 · GHC.Internal.Classes
  • (Eq uid, Eq modulename, Eq mod, Eq srcpkgid, Eq srcpkgname) => Eq (GenericUnitInfo srcpkgid srcpkgname uid modulename mod)Defined in ghc-boot-10.0.0.20260917 · GHC.Unit.Database
  • (Eq a, Eq b, Eq c, Eq d, Eq e, Eq f) => Eq (a, b, c, d, e, f)Defined in ghc-internal-10.0.0 · GHC.Internal.Classes
  • (Eq a, Eq b, Eq c, Eq d, Eq e, Eq f, Eq g) => Eq (a, b, c, d, e, f, g)Defined in ghc-internal-10.0.0 · GHC.Internal.Classes
  • (Eq a, Eq b, Eq c, Eq d, Eq e, Eq f, Eq g, Eq h) => Eq (a, b, c, d, e, f, g, h)Defined in ghc-internal-10.0.0 · GHC.Internal.Classes
  • (Eq a, Eq b, Eq c, Eq d, Eq e, Eq f, Eq g, Eq h, Eq i) => Eq (a, b, c, d, e, f, g, h, i)Defined in ghc-internal-10.0.0 · GHC.Internal.Classes
  • (Eq a, Eq b, Eq c, Eq d, Eq e, Eq f, Eq g, Eq h, Eq i, Eq j) => Eq (a, b, c, d, e, f, g, h, i, j)Defined in ghc-internal-10.0.0 · GHC.Internal.Classes
  • (Eq a, Eq b, Eq c, Eq d, Eq e, Eq f, Eq g, Eq h, Eq i, Eq j, Eq k) => Eq (a, b, c, d, e, f, g, h, i, j, k)Defined in ghc-internal-10.0.0 · GHC.Internal.Classes
  • (Eq a, Eq b, Eq c, Eq d, Eq e, Eq f, Eq g, Eq h, Eq i, Eq j, Eq k, Eq l) => Eq (a, b, c, d, e, f, g, h, i, j, k, l)Defined in ghc-internal-10.0.0 · GHC.Internal.Classes
  • (Eq a, Eq b, Eq c, Eq d, Eq e, Eq f, Eq g, Eq h, Eq i, Eq j, Eq k, Eq l, Eq m) => Eq (a, b, c, d, e, f, g, h, i, j, k, l, m)Defined in ghc-internal-10.0.0 · GHC.Internal.Classes
  • (Eq a, Eq b, Eq c, Eq d, Eq e, Eq f, Eq g, Eq h, Eq i, Eq j, Eq k, Eq l, Eq m, Eq n) => Eq (a, b, c, d, e, f, g, h, i, j, k, l, m, n)Defined in ghc-internal-10.0.0 · GHC.Internal.Classes
  • (Eq a, Eq b, Eq c, Eq d, Eq e, Eq f, Eq g, Eq h, Eq i, Eq j, Eq k, Eq l, Eq m, Eq n, Eq o) => Eq (a, b, c, d, e, f, g, h, i, j, k, l, m, n, o)Defined in ghc-internal-10.0.0 · GHC.Internal.Classes
classclass 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.

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.

Methods

Instances604Ord, …
  • Ord ByteArrayDefined in base-4.23.0.0 · Data.Array.Byte

    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.

  • Ord ByteStringDefined in bytestring-0.12.2.0 · Data.ByteString.Internal.Type
  • Ord ByteStringDefined in bytestring-0.12.2.0 · Data.ByteString.Lazy.Internal
  • Ord ShortByteStringDefined in bytestring-0.12.2.0 · Data.ByteString.Short.Internal

    Lexicographic order.

  • Ord IntSetDefined in containers-0.8 · Data.IntSet.Internal
  • Ord IntersectionDefined in containers-0.8 · Data.IntSet.Internal
  • Ord FileTypeDefined in directory-1.3.11.0 · System.Directory.Internal.Common
  • Ord PermissionsDefined in directory-1.3.11.0 · System.Directory.Internal.Common
  • Ord XdgDirectoryDefined in directory-1.3.11.0 · System.Directory.Internal.Common
  • Ord XdgDirectoryListDefined in directory-1.3.11.0 · System.Directory.Internal.Common
  • Ord PrimOpDefined in ghc-10.0.0.20260917 · GHC.Builtin.PrimOps
  • Ord PrimOpEffectDefined in ghc-10.0.0.20260917 · GHC.Builtin.PrimOps
  • Ord InternalBreakpointIdDefined in ghc-10.0.0.20260917 · GHC.ByteCode.Breakpoints
  • Ord LocalLabelDefined in ghc-10.0.0.20260917 · GHC.ByteCode.Instr
  • Ord BCOIxDefined in ghc-10.0.0.20260917 · GHC.ByteCode.Linker
  • Ord ByteOffDefined in ghc-10.0.0.20260917 · GHC.ByteCode.Types
  • Ord HalfWordDefined in ghc-10.0.0.20260917 · GHC.ByteCode.Types
  • Ord RegBitmapDefined in ghc-10.0.0.20260917 · GHC.ByteCode.Types
  • Ord WordOffDefined in ghc-10.0.0.20260917 · GHC.ByteCode.Types
  • Ord CmmInfoTableDefined in ghc-10.0.0.20260917 · GHC.Cmm
  • Ord ProfilingInfoDefined in ghc-10.0.0.20260917 · GHC.Cmm
  • Ord CLabelDefined in ghc-10.0.0.20260917 · GHC.Cmm.CLabel
  • Ord CmmLabelInfoDefined in ghc-10.0.0.20260917 · GHC.Cmm.CLabel
  • Ord ConInfoTableLocationDefined in ghc-10.0.0.20260917 · GHC.Cmm.CLabel
  • Ord DynamicLinkerLabelInfoDefined in ghc-10.0.0.20260917 · GHC.Cmm.CLabel
  • Ord ForeignLabelSourceDefined in ghc-10.0.0.20260917 · GHC.Cmm.CLabel
  • Ord IdLabelInfoDefined in ghc-10.0.0.20260917 · GHC.Cmm.CLabel
  • Ord InfoProvEntDefined in ghc-10.0.0.20260917 · GHC.Cmm.CLabel
  • Ord ModuleLabelKindDefined in ghc-10.0.0.20260917 · GHC.Cmm.CLabel
  • Ord NeedExternDeclDefined in ghc-10.0.0.20260917 · GHC.Cmm.CLabel
  • Ord RtsLabelInfoDefined in ghc-10.0.0.20260917 · GHC.Cmm.CLabel
  • Ord TickyIdInfoDefined in ghc-10.0.0.20260917 · GHC.Cmm.CLabel

    Don't depend on this if you need determinism. No determinism in the ncg backend, so we use the unique for Ord. Even if it pains me slightly.

  • Ord LabelDefined in ghc-10.0.0.20260917 · GHC.Cmm.Dataflow.Label
  • Ord LabelSetDefined in ghc-10.0.0.20260917 · GHC.Cmm.Dataflow.Label
  • Ord RPNumDefined in ghc-10.0.0.20260917 · GHC.Cmm.Dominators
  • Ord AlignmentSpecDefined in ghc-10.0.0.20260917 · GHC.Cmm.Expr
  • Ord AreaDefined in ghc-10.0.0.20260917 · GHC.Cmm.Expr
  • Ord CAFfyLabelDefined in ghc-10.0.0.20260917 · GHC.Cmm.Info.Build
  • Ord SRTEntryDefined in ghc-10.0.0.20260917 · GHC.Cmm.Info.Build
  • Ord SomeLabelDefined in ghc-10.0.0.20260917 · GHC.Cmm.Info.Build
  • Ord MemoryOrderingDefined in ghc-10.0.0.20260917 · GHC.Cmm.MachOp
  • Ord CmmTickScopeDefined in ghc-10.0.0.20260917 · GHC.Cmm.Node
  • Ord CmmRegDefined in ghc-10.0.0.20260917 · GHC.Cmm.Reg
  • Ord GlobalArgRegsDefined in ghc-10.0.0.20260917 · GHC.Cmm.Reg
  • Ord GlobalRegDefined in ghc-10.0.0.20260917 · GHC.Cmm.Reg
  • Ord GlobalRegUseDefined in ghc-10.0.0.20260917 · GHC.Cmm.Reg
  • Ord LocalRegDefined in ghc-10.0.0.20260917 · GHC.Cmm.Reg
  • Ord WidthDefined in ghc-10.0.0.20260917 · GHC.Cmm.Type
  • Ord TargetDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.AArch64.Instr
  • Ord BlockChainDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.BlockLayout
  • Ord CfgEdgeDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.CFG

    Edges are sorted ascending pointwise by weight, source and destination

  • Ord EdgeWeightDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.CFG
  • Ord FormatDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.Format
  • Ord ScalarFormatDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.Format
  • Ord RegSubDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.Reg.Graph.Base
  • Ord ReadingOrWritingDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.Reg.Linear.Base
  • Ord VLocDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.Reg.Linear.Base
  • Ord SymNameDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.Wasm.Types
  • Ord PaddingDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.X86.CodeGen
  • Ord StackRefDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.X86.CodeGen
  • Ord LlvmVersionDefined in ghc-10.0.0.20260917 · GHC.CmmToLlvm.Version.Type
  • Ord AltConDefined in ghc-10.0.0.20260917 · GHC.Core
  • Ord TickDefined in ghc-10.0.0.20260917 · GHC.Core.Opt.Stats
  • Ord EqRelDefined in ghc-10.0.0.20260917 · GHC.Core.Predicate
  • Ord InvisibleBitDefined in ghc-10.0.0.20260917 · GHC.Core.TyCo.Compare
  • Ord TypeOrderingDefined in ghc-10.0.0.20260917 · GHC.Core.TyCo.Compare
  • Ord CoSelDefined in ghc-10.0.0.20260917 · GHC.Core.TyCo.Rep
  • Ord FunSelDefined in ghc-10.0.0.20260917 · GHC.Core.TyCo.Rep
  • Ord UnivCoProvenanceDefined in ghc-10.0.0.20260917 · GHC.Core.TyCo.Rep
  • Ord PrimElemRepDefined in ghc-10.0.0.20260917 · GHC.Core.TyCon
  • Ord PrimOrVoidRepDefined in ghc-10.0.0.20260917 · GHC.Core.TyCon
  • Ord PrimRepDefined in ghc-10.0.0.20260917 · GHC.Core.TyCon
  • Ord OverridingBoolDefined in ghc-10.0.0.20260917 · GHC.Data.Bool
  • Ord LexicalFastStringDefined in ghc-10.0.0.20260917 · GHC.Data.FastString
  • Ord NonDetFastStringDefined in ghc-10.0.0.20260917 · GHC.Data.FastString
  • Ord EdgeTypeDefined in ghc-10.0.0.20260917 · GHC.Data.Graph.Directed
  • Ord TimeDefined in ghc-10.0.0.20260917 · GHC.Data.Graph.Directed
  • Ord Word64SetDefined in ghc-10.0.0.20260917 · GHC.Data.Word64Set.Internal
  • Ord CodeGenEnableDefined in ghc-10.0.0.20260917 · GHC.Driver.Downsweep
  • Ord DynamicTooStateDefined in ghc-10.0.0.20260917 · GHC.Driver.DynFlags
  • Ord ModRenamingDefined in ghc-10.0.0.20260917 · GHC.Driver.DynFlags
  • Ord PackageArgDefined in ghc-10.0.0.20260917 · GHC.Driver.DynFlags
  • Ord PackageDBFlagDefined in ghc-10.0.0.20260917 · GHC.Driver.DynFlags
  • Ord PackageFlagDefined in ghc-10.0.0.20260917 · GHC.Driver.DynFlags
  • Ord PkgDbRefDefined in ghc-10.0.0.20260917 · GHC.Driver.DynFlags
  • Ord DeprecationDefined in ghc-10.0.0.20260917 · GHC.Driver.Flags
  • Ord WarningFlagDefined in ghc-10.0.0.20260917 · GHC.Driver.Flags
  • Ord HsDocStringChunkDefined in ghc-10.0.0.20260917 · GHC.Hs.DocString
  • Ord HsDocStringDecoratorDefined in ghc-10.0.0.20260917 · GHC.Hs.DocString
  • Ord PmLitDefined in ghc-10.0.0.20260917 · GHC.HsToCore.Pmc.Solver.Types
  • Ord CompressionIFaceDefined in ghc-10.0.0.20260917 · GHC.Iface.Binary
  • Ord BindTypeDefined in ghc-10.0.0.20260917 · GHC.Iface.Ext.Types
  • Ord ContextInfoDefined in ghc-10.0.0.20260917 · GHC.Iface.Ext.Types
  • Ord DeclTypeDefined in ghc-10.0.0.20260917 · GHC.Iface.Ext.Types
  • Ord EntityInfoDefined in ghc-10.0.0.20260917 · GHC.Iface.Ext.Types
  • Ord EvBindDepsDefined in ghc-10.0.0.20260917 · GHC.Iface.Ext.Types
  • Ord EvVarSourceDefined in ghc-10.0.0.20260917 · GHC.Iface.Ext.Types
  • Ord HieNameDefined in ghc-10.0.0.20260917 · GHC.Iface.Ext.Types
  • Ord IETypeDefined in ghc-10.0.0.20260917 · GHC.Iface.Ext.Types
  • Ord NodeAnnotationDefined in ghc-10.0.0.20260917 · GHC.Iface.Ext.Types
  • Ord NodeOriginDefined in ghc-10.0.0.20260917 · GHC.Iface.Ext.Types
  • Ord RecFieldContextDefined in ghc-10.0.0.20260917 · GHC.Iface.Ext.Types
  • Ord ScopeDefined in ghc-10.0.0.20260917 · GHC.Iface.Ext.Types
  • Ord TyVarScopeDefined in ghc-10.0.0.20260917 · GHC.Iface.Ext.Types
  • Ord UnfoldingExposureDefined in ghc-10.0.0.20260917 · GHC.Iface.Tidy
  • Ord IfLclNameDefined in ghc-10.0.0.20260917 · GHC.Iface.Type
  • Ord IfaceAppArgsDefined in ghc-10.0.0.20260917 · GHC.Iface.Type
  • Ord IfaceAxiomRuleDefined in ghc-10.0.0.20260917 · GHC.Iface.Type
  • Ord IfaceBndrDefined in ghc-10.0.0.20260917 · GHC.Iface.Type
  • Ord IfaceCoercionDefined in ghc-10.0.0.20260917 · GHC.Iface.Type
  • Ord IfaceMCoercionDefined in ghc-10.0.0.20260917 · GHC.Iface.Type
  • Ord IfaceTyConDefined in ghc-10.0.0.20260917 · GHC.Iface.Type
  • Ord IfaceTyConInfoDefined in ghc-10.0.0.20260917 · GHC.Iface.Type
  • Ord IfaceTyConSortDefined in ghc-10.0.0.20260917 · GHC.Iface.Type
  • Ord IfaceTyLitDefined in ghc-10.0.0.20260917 · GHC.Iface.Type
  • Ord IfaceTypeDefined in ghc-10.0.0.20260917 · GHC.Iface.Type
  • Ord AOpDefined in ghc-10.0.0.20260917 · GHC.JS.JStg.Syntax
  • Ord OpDefined in ghc-10.0.0.20260917 · GHC.JS.JStg.Syntax
  • Ord UOpDefined in ghc-10.0.0.20260917 · GHC.JS.JStg.Syntax
  • Ord MultiplicityDefined in ghc-10.0.0.20260917 · GHC.JS.Opt.Simple
  • Ord VarDeclDefined in ghc-10.0.0.20260917 · GHC.JS.Opt.Simple
  • Ord AOpDefined in ghc-10.0.0.20260917 · GHC.JS.Syntax
  • Ord OpDefined in ghc-10.0.0.20260917 · GHC.JS.Syntax
  • Ord UOpDefined in ghc-10.0.0.20260917 · GHC.JS.Syntax
  • Ord MetaIdDefined in ghc-10.0.0.20260917 · GHC.Llvm.MetaData
  • Ord BindTagDefined in ghc-10.0.0.20260917 · GHC.Parser.Annotation
  • Ord DeclTagDefined in ghc-10.0.0.20260917 · GHC.Parser.Annotation
  • Ord HasEDefined in ghc-10.0.0.20260917 · GHC.Parser.Annotation
  • Ord IsUnicodeSyntaxDefined in ghc-10.0.0.20260917 · GHC.Parser.Annotation
  • Ord NoEpAnnsDefined in ghc-10.0.0.20260917 · GHC.Parser.Annotation
  • Ord LexErrDefined in ghc-10.0.0.20260917 · GHC.Parser.Errors.Types
  • Ord LexErrKindDefined in ghc-10.0.0.20260917 · GHC.Parser.Errors.Types
  • Ord NumUnderscoreReasonDefined in ghc-10.0.0.20260917 · GHC.Parser.Errors.Types
  • Ord BmiVersionDefined in ghc-10.0.0.20260917 · GHC.Platform
  • Ord PlatformDefined in ghc-10.0.0.20260917 · GHC.Platform
  • Ord PlatformWordSizeDefined in ghc-10.0.0.20260917 · GHC.Platform
  • Ord SseAvxVersionDefined in ghc-10.0.0.20260917 · GHC.Platform
  • Ord PlatformConstantsDefined in ghc-10.0.0.20260917 · GHC.Platform.Constants
  • Ord ProfileDefined in ghc-10.0.0.20260917 · GHC.Platform.Profile
  • Ord RealRegDefined in ghc-10.0.0.20260917 · GHC.Platform.Reg
  • Ord RegDefined in ghc-10.0.0.20260917 · GHC.Platform.Reg
  • Ord VirtualRegDefined in ghc-10.0.0.20260917 · GHC.Platform.Reg
  • Ord RegArchDefined in ghc-10.0.0.20260917 · GHC.Platform.Reg.Class
  • Ord RegClassDefined in ghc-10.0.0.20260917 · GHC.Platform.Reg.Class
  • Ord WayDefined in ghc-10.0.0.20260917 · GHC.Platform.Ways
  • Ord ArgDescrDefined in ghc-10.0.0.20260917 · GHC.Runtime.Heap.Layout
  • Ord ClosureTypeInfoDefined in ghc-10.0.0.20260917 · GHC.Runtime.Heap.Layout
  • Ord SMRepDefined in ghc-10.0.0.20260917 · GHC.Runtime.Heap.Layout
  • Ord StgLiftConfigDefined in ghc-10.0.0.20260917 · GHC.Stg.Lift.Config
  • Ord StgToDoDefined in ghc-10.0.0.20260917 · GHC.Stg.Pipeline
  • Ord CounterTypeDefined in ghc-10.0.0.20260917 · GHC.Stg.Stats
  • Ord NoExtFieldSilentDefined in ghc-10.0.0.20260917 · GHC.Stg.Syntax
  • Ord DiscrDefined in ghc-10.0.0.20260917 · GHC.StgToByteCode
  • Ord ArgRepDefined in ghc-10.0.0.20260917 · GHC.StgToCmm.ArgRep
  • Ord ApplyConvDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Apply
  • Ord ApplySpecDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Apply
  • Ord BlockRefDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Object
  • Ord ExportedFunDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Object
  • Ord JSOptionsDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Object
  • Ord ObjectKindDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Object
  • Ord StgRegDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Regs
  • Ord StgRetDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Regs
  • Ord CILayoutDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Ord CIRegsDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Ord CITypeDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Ord ClosureTypeDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Ord ExpFunDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Ord IdKeyDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Ord IdTypeDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Ord JSFFITypeDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Ord JSRepDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Ord OtherSymbDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Ord StackSlotDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Ord StaticUnboxedDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Ord ThreadStatusDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Ord SlotCountDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Utils
  • Ord HoleFitSortingAlgDefined in ghc-10.0.0.20260917 · GHC.Tc.Errors.Hole
  • Ord HoleFitCandidateDefined in ghc-10.0.0.20260917 · GHC.Tc.Errors.Hole.FitTypes
  • Ord TcHoleFitDefined in ghc-10.0.0.20260917 · GHC.Tc.Errors.Hole.FitTypes

    Compare HoleFits by their Name. Use stableNameCmp to avoid non-determinism.

    When comparing, we want HoleFits with a lower refinement level to come first.

  • Ord DocLocDefined in ghc-10.0.0.20260917 · GHC.Tc.Types
  • Ord SubGoalDepthDefined in ghc-10.0.0.20260917 · GHC.Tc.Types.CtLoc
  • Ord SimpleUnifyResultDefined in ghc-10.0.0.20260917 · GHC.Tc.Utils.Unify
  • Ord DetOrdAvailsDefined in ghc-10.0.0.20260917 · GHC.Types.Avail
  • Ord AlignmentDefined in ghc-10.0.0.20260917 · GHC.Types.Basic
  • Ord FunctionOrDataDefined in ghc-10.0.0.20260917 · GHC.Types.Basic
  • Ord ImportLevelDefined in ghc-10.0.0.20260917 · GHC.Types.Basic
  • Ord IntWithInfDefined in ghc-10.0.0.20260917 · GHC.Types.Basic
  • Ord LeftOrRightDefined in ghc-10.0.0.20260917 · GHC.Types.Basic
  • Ord LevityDefined in ghc-10.0.0.20260917 · GHC.Types.Basic
  • Ord PprPrecDefined in ghc-10.0.0.20260917 · GHC.Types.Basic
  • Ord TupleSortDefined in ghc-10.0.0.20260917 · GHC.Types.Basic
  • Ord TypeOrConstraintDefined in ghc-10.0.0.20260917 · GHC.Types.Basic
  • Ord CCFlavourDefined in ghc-10.0.0.20260917 · GHC.Types.CostCentre
  • Ord CostCentreDefined in ghc-10.0.0.20260917 · GHC.Types.CostCentre
  • Ord CostCentreStackDefined in ghc-10.0.0.20260917 · GHC.Types.CostCentre
  • Ord IndexedCCFlavourDefined in ghc-10.0.0.20260917 · GHC.Types.CostCentre
  • Ord CostCentreIndexDefined in ghc-10.0.0.20260917 · GHC.Types.CostCentre.State
  • Ord DiagnosticCodeDefined in ghc-10.0.0.20260917 · GHC.Types.Error
  • Ord SeverityDefined in ghc-10.0.0.20260917 · GHC.Types.Error
  • Ord AssumedDerivingStrategyDefined in ghc-10.0.0.20260917 · GHC.Types.Hint
  • Ord CafInfoDefined in ghc-10.0.0.20260917 · GHC.Types.Id.Info
  • Ord LitNumTypeDefined in ghc-10.0.0.20260917 · GHC.Types.Literal
  • Ord LiteralDefined in ghc-10.0.0.20260917 · GHC.Types.Literal

    Needed for the Ord instance of AltCon, which in turn is needed in GHC.Data.TrieMap.CoreMap.

  • Ord LitFloatingDefined in ghc-10.0.0.20260917 · GHC.Types.Literal.Floating

    The ordering represented by this instance is pretty arbitrary and may change without notice. Do not rely on its behavior!

  • Ord LitFloatingTypeDefined in ghc-10.0.0.20260917 · GHC.Types.Literal.Floating
  • Ord NameDefined in ghc-10.0.0.20260917 · GHC.Types.Name

    Caution: This instance is implemented via nonDetCmpUnique, which means that the ordering is not stable across deserialization or rebuilds.

    See nonDetCmpUnique for further information, and #15240 for a bug caused by improper use of this instance.

  • Ord NameSpaceDefined in ghc-10.0.0.20260917 · GHC.Types.Name.Occurrence
  • Ord OccNameDefined in ghc-10.0.0.20260917 · GHC.Types.Name.Occurrence
  • Ord RdrNameDefined in ghc-10.0.0.20260917 · GHC.Types.Name.Reader
  • Ord PkgQualDefined in ghc-10.0.0.20260917 · GHC.Types.PkgQual
  • Ord SlotTyDefined in ghc-10.0.0.20260917 · GHC.Types.RepType
  • Ord SaneDoubleDefined in ghc-10.0.0.20260917 · GHC.Types.SaneDouble
  • Ord HsBootOrSigDefined in ghc-10.0.0.20260917 · GHC.Types.SourceFile
  • Ord HscSourceDefined in ghc-10.0.0.20260917 · GHC.Types.SourceFile
  • Ord FractionalExponentBaseDefined in ghc-10.0.0.20260917 · GHC.Types.SourceText
  • Ord FractionalLitDefined in ghc-10.0.0.20260917 · GHC.Types.SourceText

    Be wary of using this instance to compare for equal *values* when exponents are large. The same value expressed in different syntactic form won't compare as equal when any of the exponents is >= 100.

  • Ord IntegralLitDefined in ghc-10.0.0.20260917 · GHC.Types.SourceText
  • Ord BufPosDefined in ghc-10.0.0.20260917 · GHC.Types.SrcLoc
  • Ord BufSpanDefined in ghc-10.0.0.20260917 · GHC.Types.SrcLoc
  • Ord DeltaPosDefined in ghc-10.0.0.20260917 · GHC.Types.SrcLoc
  • Ord NoCommentsDefined in ghc-10.0.0.20260917 · GHC.Types.SrcLoc
  • Ord PsLocDefined in ghc-10.0.0.20260917 · GHC.Types.SrcLoc
  • Ord PsSpanDefined in ghc-10.0.0.20260917 · GHC.Types.SrcLoc
  • Ord RealSrcLocDefined in ghc-10.0.0.20260917 · GHC.Types.SrcLoc
  • Ord RealSrcSpanDefined in ghc-10.0.0.20260917 · GHC.Types.SrcLoc
  • Ord ThLevelIndexDefined in ghc-10.0.0.20260917 · GHC.Types.ThLevelIndex
  • Ord BreakpointIdDefined in ghc-10.0.0.20260917 · GHC.Types.Tickish
  • Ord UniqueSetDefined in ghc-10.0.0.20260917 · GHC.Types.Unique.Set
  • Ord FunTyFlagDefined in ghc-10.0.0.20260917 · GHC.Types.Var
  • Ord VarDefined in ghc-10.0.0.20260917 · GHC.Types.Var
  • Ord IfaceImportLevelDefined in ghc-10.0.0.20260917 · GHC.Unit.Module.Deps
  • Ord NDModuleDefined in ghc-10.0.0.20260917 · GHC.Unit.Module.Env
  • Ord ModuleGraphInvariantErrorDefined in ghc-10.0.0.20260917 · GHC.Unit.Module.Graph
  • Ord ModuleGraphNodeDefined in ghc-10.0.0.20260917 · GHC.Unit.Module.Graph
  • Ord NodeKeyDefined in ghc-10.0.0.20260917 · GHC.Unit.Module.Graph
  • Ord ZeroScopeKeyDefined in ghc-10.0.0.20260917 · GHC.Unit.Module.Graph
  • Ord ModNodeKeyWithUidDefined in ghc-10.0.0.20260917 · GHC.Unit.Module.ModNodeKey
  • Ord ModuleStageDefined in ghc-10.0.0.20260917 · GHC.Unit.Module.Stage
  • Ord IsTrustedDefined in ghc-10.0.0.20260917 · GHC.Unit.State
  • Ord UnitDefined in ghc-10.0.0.20260917 · GHC.Unit.Types
  • Ord UnitIdDefined in ghc-10.0.0.20260917 · GHC.Unit.Types
  • Ord FullBinDataDefined in ghc-10.0.0.20260917 · GHC.Utils.Binary
  • Ord RoleDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Basic
  • Ord DataConCantHappenDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Extension
  • Ord NoExtFieldDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Extension
  • Ord IsBootInterfaceDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.ImpExp.IsBoot
  • Ord OverLitValDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Lit
  • Ord QualLitValDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Lit
  • Ord ModuleNameDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Module.Name
  • Ord RecFieldsDotDotDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Pat
  • Ord ForAllTyFlagDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Specificity
  • Ord SpecificityDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Specificity
  • Ord PromotionFlagDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Type
  • Ord ShortTextDefined in ghc-boot-10.0.0.20260917 · GHC.Data.ShortText
  • Ord VoidDefined in ghc-internal-10.0.0 · GHC.Internal.Base
  • Ord BigNatDefined in ghc-internal-10.0.0 · GHC.Internal.Bignum.BigNat
  • Ord IntegerDefined in ghc-internal-10.0.0 · GHC.Internal.Bignum.Integer
  • Ord NaturalDefined in ghc-internal-10.0.0 · GHC.Internal.Bignum.Natural
  • Ord ByteOrderDefined in ghc-internal-10.0.0 · GHC.Internal.ByteOrder
  • Ord ClosureTypeDefined in ghc-internal-10.0.0 · GHC.Internal.ClosureTypes
  • Ord BlockReasonDefined in ghc-internal-10.0.0 · GHC.Internal.Conc.Sync
  • Ord ThreadIdDefined in ghc-internal-10.0.0 · GHC.Internal.Conc.Sync
  • Ord ThreadStatusDefined in ghc-internal-10.0.0 · GHC.Internal.Conc.Sync
  • Ord AllDefined in ghc-internal-10.0.0 · GHC.Internal.Data.Semigroup.Internal
  • Ord AnyDefined in ghc-internal-10.0.0 · GHC.Internal.Data.Semigroup.Internal
  • Ord SomeTypeRepDefined in ghc-internal-10.0.0 · GHC.Internal.Data.Typeable.Internal
  • Ord UniqueDefined in ghc-internal-10.0.0 · GHC.Internal.Data.Unique
  • Ord VersionDefined in ghc-internal-10.0.0 · GHC.Internal.Data.Version
  • Ord TimeoutKeyDefined in ghc-internal-10.0.0 · GHC.Internal.Event.TimeOut
  • Ord UniqueDefined in ghc-internal-10.0.0 · GHC.Internal.Event.Unique
  • Ord ErrorCallDefined in ghc-internal-10.0.0 · GHC.Internal.Exception
  • Ord ArithExceptionDefined in ghc-internal-10.0.0 · GHC.Internal.Exception.Type
  • Ord FingerprintDefined in ghc-internal-10.0.0 · GHC.Internal.Fingerprint.Type
  • Ord CBoolDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Ord CCharDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Ord CClockDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Ord CDoubleDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Ord CFloatDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Ord CIntDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Ord CIntMaxDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Ord CIntPtrDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Ord CLLongDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Ord CLongDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Ord CPtrdiffDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Ord CSCharDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Ord CSUSecondsDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Ord CShortDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Ord CSigAtomicDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Ord CSizeDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Ord CTimeDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Ord CUCharDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Ord CUIntDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Ord CUIntMaxDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Ord CUIntPtrDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Ord CULLongDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Ord CULongDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Ord CUSecondsDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Ord CUShortDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Ord CWcharDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Ord IntPtrDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.Ptr
  • Ord WordPtrDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.Ptr
  • Ord AssociativityDefined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Ord DecidedStrictnessDefined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Ord FixityDefined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Ord SourceStrictnessDefined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Ord SourceUnpackednessDefined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Ord PrimTypeDefined in ghc-internal-10.0.0 · GHC.Internal.Heap.Closures
  • Ord TsoFlagsDefined in ghc-internal-10.0.0 · GHC.Internal.Heap.Closures
  • Ord WhatNextDefined in ghc-internal-10.0.0 · GHC.Internal.Heap.Closures
  • Ord WhyBlockedDefined in ghc-internal-10.0.0 · GHC.Internal.Heap.Closures
  • Ord HalfWordDefined in ghc-internal-10.0.0 · GHC.Internal.Heap.InfoTable.Types
  • Ord CostCentreDefined in ghc-internal-10.0.0 · GHC.Internal.Heap.ProfInfo.Types
  • Ord CostCentreStackDefined in ghc-internal-10.0.0 · GHC.Internal.Heap.ProfInfo.Types
  • Ord IndexTableDefined in ghc-internal-10.0.0 · GHC.Internal.Heap.ProfInfo.Types
  • Ord StgTSOProfInfoDefined in ghc-internal-10.0.0 · GHC.Internal.Heap.ProfInfo.Types
  • Ord SeekModeDefined in ghc-internal-10.0.0 · GHC.Internal.IO.Device
  • Ord ArrayExceptionDefined in ghc-internal-10.0.0 · GHC.Internal.IO.Exception
  • Ord AsyncExceptionDefined in ghc-internal-10.0.0 · GHC.Internal.IO.Exception
  • Ord ExitCodeDefined in ghc-internal-10.0.0 · GHC.Internal.IO.Exception
  • Ord BufferModeDefined in ghc-internal-10.0.0 · GHC.Internal.IO.Handle.Types
  • Ord NewlineDefined in ghc-internal-10.0.0 · GHC.Internal.IO.Handle.Types
  • Ord NewlineModeDefined in ghc-internal-10.0.0 · GHC.Internal.IO.Handle.Types
  • Ord IOModeDefined in ghc-internal-10.0.0 · GHC.Internal.IO.IOMode
  • Ord Int16Defined in ghc-internal-10.0.0 · GHC.Internal.Int
  • Ord Int32Defined in ghc-internal-10.0.0 · GHC.Internal.Int
  • Ord Int64Defined in ghc-internal-10.0.0 · GHC.Internal.Int
  • Ord Int8Defined in ghc-internal-10.0.0 · GHC.Internal.Int
  • Ord ExtensionDefined in ghc-internal-10.0.0 · GHC.Internal.LanguageExtensions
  • Ord ByteOffsetDefined in ghc-internal-10.0.0 · GHC.Internal.Stack.Constants
  • Ord WordOffsetDefined in ghc-internal-10.0.0 · GHC.Internal.Stack.Constants
  • Ord ByteOffsetDefined in ghc-internal-10.0.0 · GHC.Internal.Stack.ConstantsProf
  • Ord WordOffsetDefined in ghc-internal-10.0.0 · GHC.Internal.Stack.ConstantsProf
  • Ord CBlkCntDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Ord CBlkSizeDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Ord CCcDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Ord CClockIdDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Ord CDevDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Ord CFsBlkCntDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Ord CFsFilCntDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Ord CGidDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Ord CIdDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Ord CInoDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Ord CKeyDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Ord CModeDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Ord CNfdsDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Ord CNlinkDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Ord COffDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Ord CPidDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Ord CRLimDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Ord CSocklenDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Ord CSpeedDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Ord CSsizeDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Ord CTcflagDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Ord CTimerDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Ord CUidDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Ord FdDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Ord AnnLookupDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Ord AnnTargetDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Ord BangDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Ord BndrVisDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Ord BodyDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Ord BytesDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Ord CallconvDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Ord ClauseDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Ord ConDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Ord DecDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Ord DecidedStrictnessDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Ord DerivClauseDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Ord DerivStrategyDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Ord DocLocDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Ord ExpDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Ord FamilyResultSigDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Ord FixityDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Ord FixityDirectionDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Ord ForeignDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Ord FunDepDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Ord GuardDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Ord InfoDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Ord InjectivityAnnDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Ord InlineDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Ord LitDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Ord LocDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Ord MatchDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Ord ModNameDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Ord ModuleDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Ord ModuleInfoDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Ord NameDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Ord NameFlavourDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Ord NameSpaceDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Ord NamespaceSpecifierDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Ord OccNameDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Ord OverlapDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Ord PatDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Ord PatSynArgsDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Ord PatSynDirDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Ord PhasesDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Ord PkgNameDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Ord PragmaDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Ord RangeDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Ord RoleDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Ord RuleBndrDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Ord RuleMatchDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Ord SafetyDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Ord SourceStrictnessDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Ord SourceUnpackednessDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Ord SpecificityDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Ord StmtDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Ord TyLitDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Ord TySynEqnDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Ord TypeDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Ord TypeFamilyHeadDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Ord SomeCharDefined in ghc-internal-10.0.0 · GHC.Internal.TypeLits
  • Ord SomeSymbolDefined in ghc-internal-10.0.0 · GHC.Internal.TypeLits
  • Ord SomeNatDefined in ghc-internal-10.0.0 · GHC.Internal.TypeNats
  • Ord BoolDefined in ghc-internal-10.0.0 · GHC.Internal.Classes
  • Ord CharDefined in ghc-internal-10.0.0 · GHC.Internal.Classes
  • Ord DoubleDefined in ghc-internal-10.0.0 · GHC.Internal.Classes

    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.

  • Ord FloatDefined in ghc-internal-10.0.0 · GHC.Internal.Classes

    See instance Ord Double for discussion of deviations from IEEE 754 standard.

  • Ord IntDefined in ghc-internal-10.0.0 · GHC.Internal.Classes
  • Ord OrderingDefined in ghc-internal-10.0.0 · GHC.Internal.Classes
  • Ord TyConDefined in ghc-internal-10.0.0 · GHC.Internal.Classes
  • Ord WordDefined in ghc-internal-10.0.0 · GHC.Internal.Classes
  • Ord GeneralCategoryDefined in ghc-internal-10.0.0 · GHC.Internal.Unicode
  • Ord Word16Defined in ghc-internal-10.0.0 · GHC.Internal.Word
  • Ord Word32Defined in ghc-internal-10.0.0 · GHC.Internal.Word
  • Ord Word64Defined in ghc-internal-10.0.0 · GHC.Internal.Word
  • Ord Word8Defined in ghc-internal-10.0.0 · GHC.Internal.Word
  • Ord ArchDefined in ghc-platform-0.1.0.0 · GHC.Platform.ArchOS
  • Ord ArchOSDefined in ghc-platform-0.1.0.0 · GHC.Platform.ArchOS
  • Ord ArmABIDefined in ghc-platform-0.1.0.0 · GHC.Platform.ArchOS
  • Ord ArmISADefined in ghc-platform-0.1.0.0 · GHC.Platform.ArchOS
  • Ord ArmISAExtDefined in ghc-platform-0.1.0.0 · GHC.Platform.ArchOS
  • Ord OSDefined in ghc-platform-0.1.0.0 · GHC.Platform.ArchOS
  • Ord PPC_64ABIDefined in ghc-platform-0.1.0.0 · GHC.Platform.ArchOS
  • Ord LibraryDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Library
  • Ord ProgramDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Program
  • Ord TargetDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Target
  • Ord WordSizeDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Target
  • Ord ArDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Tools.Ar
  • Ord CcDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Tools.Cc
  • Ord CmmCppDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Tools.Cpp
  • Ord CppDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Tools.Cpp
  • Ord HsCppDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Tools.Cpp
  • Ord JsCppDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Tools.Cpp
  • Ord CxxDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Tools.Cxx
  • Ord CcLinkDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Tools.Link
  • Ord MergeObjsDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Tools.MergeObjs
  • Ord NmDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Tools.Nm
  • Ord RanlibDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Tools.Ranlib
  • Ord BoxLabelDefined in hpc-0.7.0.2 · Trace.Hpc.Mix
  • Ord CondBoxDefined in hpc-0.7.0.2 · Trace.Hpc.Mix
  • Ord HpcPosDefined in hpc-0.7.0.2 · Trace.Hpc.Util
  • Ord OsCharDefined in os-string-2.0.11 · System.OsString.Internal.Types

    Byte ordering of the internal representation.

  • Ord OsStringDefined in os-string-2.0.11 · System.OsString.Internal.Types

    Byte ordering of the internal representation.

  • Ord PosixCharDefined in os-string-2.0.11 · System.OsString.Internal.Types
  • Ord PosixStringDefined in os-string-2.0.11 · System.OsString.Internal.Types
  • Ord WindowsCharDefined in os-string-2.0.11 · System.OsString.Internal.Types
  • Ord WindowsStringDefined in os-string-2.0.11 · System.OsString.Internal.Types
  • Ord PrettyLevelDefined in pretty-1.1.3.6 · Text.PrettyPrint.Annotated.HughesPJClass
  • Ord PrettyLevelDefined in pretty-1.1.3.6 · Text.PrettyPrint.HughesPJClass
  • Ord CommunicationHandleDefined in process-1.6.30.0 · System.Process.CommunicationHandle.Internal
  • Ord SemaphoreProtocolVersionDefined in semaphore-compat-2.0.1 · System.Semaphore.Internal.Version
  • Ord I8Defined in text-2.1.4 · Data.Text.Foreign
  • Ord TextDefined in text-2.1.4 · Data.Text · orphan
  • Ord BuilderDefined in text-2.1.4 · Data.Text.Internal.Builder
  • Ord TextDefined in text-2.1.4 · Data.Text.Lazy · orphan
  • Ord DayDefined in time-1.16.0.1 · Data.Time.Calendar.Days
  • Ord MonthDefined in time-1.16.0.1 · Data.Time.Calendar.Month
  • Ord QuarterDefined in time-1.16.0.1 · Data.Time.Calendar.Quarter
  • Ord QuarterOfYearDefined in time-1.16.0.1 · Data.Time.Calendar.Quarter
  • Ord DayOfWeekDefined in time-1.16.0.1 · Data.Time.Calendar.Week
  • Ord AbsoluteTimeDefined in time-1.16.0.1 · Data.Time.Clock.Internal.AbsoluteTime
  • Ord DiffTimeDefined in time-1.16.0.1 · Data.Time.Clock.Internal.DiffTime
  • Ord NominalDiffTimeDefined in time-1.16.0.1 · Data.Time.Clock.Internal.NominalDiffTime
  • Ord SystemTimeDefined in time-1.16.0.1 · Data.Time.Clock.Internal.SystemTime
  • Ord UTCTimeDefined in time-1.16.0.1 · Data.Time.Clock.Internal.UTCTime
  • Ord UniversalTimeDefined in time-1.16.0.1 · Data.Time.Clock.Internal.UniversalTime
  • Ord TimeLocaleDefined in time-1.16.0.1 · Data.Time.Format.Locale
  • Ord LocalTimeDefined in time-1.16.0.1 · Data.Time.LocalTime.Internal.LocalTime
  • Ord TimeOfDayDefined in time-1.16.0.1 · Data.Time.LocalTime.Internal.TimeOfDay
  • Ord TimeZoneDefined in time-1.16.0.1 · Data.Time.LocalTime.Internal.TimeZone
  • Ord DirTypeDefined in unix-2.8.8.0 · System.Posix.Directory.Common
  • Ord CAttributesDefined in unix-2.8.8.0 · System.Posix.Files.Common
  • Ord StatxFlagsDefined in unix-2.8.8.0 · System.Posix.Files.Common
  • Ord StatxMaskDefined in unix-2.8.8.0 · System.Posix.Files.Common
  • Ord OpenFileFlagsDefined in unix-2.8.8.0 · System.Posix.IO.Common
  • Ord OpenModeDefined in unix-2.8.8.0 · System.Posix.IO.Common
  • Ord ProcessStatusDefined in unix-2.8.8.0 · System.Posix.Process.Internals
  • Ord BaudRateDefined in unix-2.8.8.0 · System.Posix.Terminal.Common
  • Ord ()Defined in ghc-internal-10.0.0 · GHC.Internal.Classes
  • Ord (IgnoreFormat Loc)Defined in ghc-10.0.0.20260917 · GHC.CmmToAsm.Reg.Linear.Base
  • Ord (GenTickish 'TickishPassCmm)Defined in ghc-10.0.0.20260917 · GHC.Types.Tickish
  • Ord (GenTickish 'TickishPassCore)Defined in ghc-10.0.0.20260917 · GHC.Types.Tickish
  • Ord (GenInstantiatedUnit unit)Defined in ghc-10.0.0.20260917 · GHC.Unit.Types
  • Ord (XXOverLit p) => Ord (HsOverLit p)Defined in ghc-10.0.0.20260917 · GHC.Hs.Lit · orphan
  • Ord (XXQualLit p) => Ord (HsQualLit p)Defined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Lit
  • Ord (ConstPtr a)Defined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.ConstPtr
  • Ord (ForeignPtr a)Defined in ghc-internal-10.0.0 · GHC.Internal.ForeignPtr
  • Ord (FunPtr a)Defined in ghc-internal-10.0.0 · GHC.Internal.Ptr
  • Ord (Ptr a)Defined in ghc-internal-10.0.0 · GHC.Internal.Ptr
  • Ord (SChar c)Defined in ghc-internal-10.0.0 · GHC.Internal.TypeLits
  • Ord (SSymbol s)Defined in ghc-internal-10.0.0 · GHC.Internal.TypeLits
  • Ord (SNat n)Defined in ghc-internal-10.0.0 · GHC.Internal.TypeNats
  • Ord a => Ord (First a)Defined in base-4.23.0.0 · Data.Semigroup
  • Ord a => Ord (Last a)Defined in base-4.23.0.0 · Data.Semigroup
  • Ord a => Ord (Max a)Defined in base-4.23.0.0 · Data.Semigroup
  • Ord a => Ord (Min a)Defined in base-4.23.0.0 · Data.Semigroup
  • Ord a => Ord (IntMap a)Defined in containers-0.8 · Data.IntMap.Internal
  • Ord a => Ord (Seq a)Defined in containers-0.8 · Data.Sequence.Internal
  • Ord a => Ord (ViewL a)Defined in containers-0.8 · Data.Sequence.Internal
  • Ord a => Ord (ViewR a)Defined in containers-0.8 · Data.Sequence.Internal
  • Ord a => Ord (Intersection a)Defined in containers-0.8 · Data.Set.Internal
  • Ord a => Ord (Set a)Defined in containers-0.8 · Data.Set.Internal
  • Ord a => Ord (PostOrder a)Defined in containers-0.8 · Data.Tree
  • Ord a => Ord (Tree a)Defined in containers-0.8 · Data.Tree
  • Ord a => Ord (LPath a)Defined in ghc-10.0.0.20260917 · GHC.Data.Graph.Inductive.Graph
  • Ord a => Ord (Maybe a)Defined in ghc-10.0.0.20260917 · GHC.Data.Strict
  • Ord a => Ord (Word64Map a)Defined in ghc-10.0.0.20260917 · GHC.Data.Word64Map.Internal
  • Ord a => Ord (EvidenceInfo a)Defined in ghc-10.0.0.20260917 · GHC.Iface.Ext.Utils
  • Ord a => Ord (FixedLengthEncoding a)Defined in ghc-10.0.0.20260917 · GHC.Utils.Binary
  • Ord a => Ord (NonEmpty a)Defined in ghc-internal-10.0.0 · GHC.Internal.Base
  • Ord a => Ord (Identity a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Functor.Identity
  • Ord a => Ord (First a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Monoid
  • Ord a => Ord (Last a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Monoid
  • Ord a => Ord (Down a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Ord
  • Ord a => Ord (Dual a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Semigroup.Internal
  • Ord a => Ord (Product a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Semigroup.Internal
  • Ord a => Ord (Sum a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Semigroup.Internal
  • Ord a => Ord (ZipList a)Defined in ghc-internal-10.0.0 · GHC.Internal.Functor.ZipList
  • Ord a => Ord (Maybe a)Defined in ghc-internal-10.0.0 · GHC.Internal.Maybe
  • Ord a => Ord (Stream a)Defined in text-2.1.4 · Data.Text.Internal.Fusion.Types
  • Ord a => Ord (a)Defined in ghc-internal-10.0.0 · GHC.Internal.Classes
  • Ord a => Ord [a]Defined in ghc-internal-10.0.0 · GHC.Internal.Classes
  • Ord flag => Ord (TyVarBndr flag)Defined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Ord m => Ord (WrappedMonoid m)Defined in base-4.23.0.0 · Data.Semigroup
  • Ord mod => Ord (GenWithIsBoot mod)Defined in ghc-10.0.0.20260917 · GHC.Unit.Types
  • Ord p => Ord (Par1 p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Ord unit => Ord (Definite unit)Defined in ghc-10.0.0.20260917 · GHC.Unit.Types
  • Ord unit => Ord (GenModule unit)Defined in ghc-10.0.0.20260917 · GHC.Unit.Types
  • Ord v => Ord (LabelMap v)Defined in ghc-10.0.0.20260917 · GHC.Cmm.Dataflow.Label
  • Integral a => Ord (Ratio a)Defined in ghc-internal-10.0.0 · GHC.Internal.Real
  • Ord (Fixed a)Defined in base-4.23.0.0 · Data.Fixed
  • Ord (Bin a)Defined in ghc-10.0.0.20260917 · GHC.Utils.Binary
  • Ord (RelBin a)Defined in ghc-10.0.0.20260917 · GHC.Utils.Binary
  • Ord (RelBinPtr a)Defined in ghc-10.0.0.20260917 · GHC.Utils.Binary
  • Ord (Proxy s)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Proxy
  • Ord (TypeRep a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Typeable.Internal
  • Ord (U1 p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Ord (V1 p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Ord a => Ord (Arg a b)Defined in base-4.23.0.0 · Data.Semigroup

    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.

  • (Ord1 f, Ord a) => Ord (Lift f a)Defined in transformers-0.6.3.0 · Control.Applicative.Lift
  • (Ord1 m, Ord a) => Ord (MaybeT m a)Defined in transformers-0.6.3.0 · Control.Monad.Trans.Maybe
  • (Ord a, Ord b) => Ord (Pair a b)Defined in ghc-10.0.0.20260917 · GHC.Data.Strict
  • (Ord a, Ord b) => Ord (Either a b)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Either
  • (Ord a, Ord b) => Ord (a, b)Defined in ghc-internal-10.0.0 · GHC.Internal.Classes
  • (Ord b, Ord r) => Ord (IfaceBindingX r b)Defined in ghc-10.0.0.20260917 · GHC.Iface.Syntax
  • (Ord k, Ord v) => Ord (Map k v)Defined in containers-0.8 · Data.Map.Internal
  • (Ord l, Ord e) => Ord (GenLocated l e)Defined in ghc-10.0.0.20260917 · GHC.Types.SrcLoc
  • (Ord var, Ord argf) => Ord (VarBndr var argf)Defined in ghc-10.0.0.20260917 · GHC.Types.Var
  • (Ix i, Ord e) => Ord (Array i e)Defined in ghc-internal-10.0.0 · GHC.Internal.Arr
  • (Ix ix, Ord e, IArray UArray e) => Ord (UArray ix e)Defined in array-0.5.8.0 · Data.Array.Base
  • Ord (Coercion a b)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Type.Coercion
  • Ord (URec Char p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Ord (URec Double p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Ord (URec Float p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Ord (URec Int p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Ord (URec Word p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Ord (URec (Ptr ()) p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Ord (a :~: b)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Type.Equality
  • Ord (f a) => Ord (Ap f a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Monoid
  • Ord (f a) => Ord (Alt f a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Semigroup.Internal
  • Ord (f p) => Ord (Rec1 f p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Ord a => Ord (Const a b)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Functor.Const
  • Ord a => Ord (Constant a b)Defined in transformers-0.6.3.0 · Data.Functor.Constant
  • (Ord1 f, Ord a) => Ord (Backwards f a)Defined in transformers-0.6.3.0 · Control.Applicative.Backwards
  • (Ord1 f, Ord a) => Ord (IdentityT f a)Defined in transformers-0.6.3.0 · Control.Monad.Trans.Identity
  • (Ord1 f, Ord a) => Ord (Reverse f a)Defined in transformers-0.6.3.0 · Data.Functor.Reverse
  • (Ord a, Ord b, Ord c) => Ord (a, b, c)Defined in ghc-internal-10.0.0 · GHC.Internal.Classes
  • (Ord e, Ord1 m, Ord a) => Ord (ExceptT e m a)Defined in transformers-0.6.3.0 · Control.Monad.Trans.Except
  • (Ord w, Ord1 m, Ord a) => Ord (WriterT w m a)Defined in transformers-0.6.3.0 · Control.Monad.Trans.Writer.Lazy
  • (Ord w, Ord1 m, Ord a) => Ord (WriterT w m a)Defined in transformers-0.6.3.0 · Control.Monad.Trans.Writer.Strict
  • (Generic1 f, Ord (Rep1 f a)) => Ord (Generically1 f a)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Ord (a :~~: b)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Type.Equality
  • Ord c => Ord (K1 i c p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • (Ord (f a), Ord (g a)) => Ord (Product f g a)Defined in base-4.23.0.0 · Data.Functor.Product
  • (Ord (f a), Ord (g a)) => Ord (Sum f g a)Defined in base-4.23.0.0 · Data.Functor.Sum
  • (Ord (f p), Ord (g p)) => Ord ((:*:) f g p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • (Ord (f p), Ord (g p)) => Ord ((:+:) f g p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • (Ord a, Ord b, Ord c, Ord d) => Ord (a, b, c, d)Defined in ghc-internal-10.0.0 · GHC.Internal.Classes
  • Ord (f (g a)) => Ord (Compose f g a)Defined in base-4.23.0.0 · Data.Functor.Compose
  • Ord (f (g p)) => Ord ((:.:) f g p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Ord (f p) => Ord (M1 i c f p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • (Graph gr, Ord a, Ord b) => Ord (OrdGr gr a b)Defined in ghc-10.0.0.20260917 · GHC.Data.Graph.Inductive.Graph
  • (Ord a, Ord b, Ord c, Ord d, Ord e) => Ord (a, b, c, d, e)Defined in ghc-internal-10.0.0 · GHC.Internal.Classes
  • (Ord a, Ord b, Ord c, Ord d, Ord e, Ord f) => Ord (a, b, c, d, e, f)Defined in ghc-internal-10.0.0 · GHC.Internal.Classes
  • (Ord a, Ord b, Ord c, Ord d, Ord e, Ord f, Ord g) => Ord (a, b, c, d, e, f, g)Defined in ghc-internal-10.0.0 · GHC.Internal.Classes
  • (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)Defined in ghc-internal-10.0.0 · GHC.Internal.Classes
  • (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)Defined in ghc-internal-10.0.0 · GHC.Internal.Classes
  • (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)Defined in ghc-internal-10.0.0 · GHC.Internal.Classes
  • (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)Defined in ghc-internal-10.0.0 · GHC.Internal.Classes
  • (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)Defined in ghc-internal-10.0.0 · GHC.Internal.Classes
  • (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)Defined in ghc-internal-10.0.0 · GHC.Internal.Classes
  • (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)Defined in ghc-internal-10.0.0 · GHC.Internal.Classes
  • (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)Defined in ghc-internal-10.0.0 · GHC.Internal.Classes
classclass Monad m => MonadFail (m :: Type -> Type) where
#

When a value is bound in do-notation, the pattern on the left hand side of <- might not match. In this case, this class provides a function to recover.

A Monad without a MonadFail instance may only be used in conjunction with pattern that always match, such as newtypes, tuples, data types with only a single data constructor, and irrefutable patterns (~pat).

Instances of MonadFail should satisfy the following law: fail s should be a left zero for >>=,

fail s >>= f  =  fail s

If your Monad is also MonadPlus, a popular definition is

fail _ = mzero

fail s should be an action that runs in the monad itself, not an exception (except in instances of MonadIO). In particular, fail should not be implemented in terms of error.

Methods

Instances36MonadFail, …
datadata Either a b
#

The Either type represents values with two possibilities: a value of type Either a b is either Left a or Right b.

The Either type is sometimes used to represent a value which is either correct or an error; by convention, the Left constructor is used to hold an error value and the Right constructor is used to hold a correct value (mnemonic: "right" also means "correct").

Examples

The type Either String Int is the type of values which can be either a String or an Int. The Left constructor can be used only on Strings, and the Right constructor can be used only on Ints:

Example6 expressions
let s = Left "foo" :: Either String IntsLeft "foo"let n = Right 3 :: Either String IntnRight 3:type ss :: Either String Int:type nn :: Either String Int

The fmap from our Functor instance will ignore Left values, but will apply the supplied function to values contained in a Right:

Example4 expressions
let s = Left "foo" :: Either String Intlet n = Right 3 :: Either String Intfmap (*2) sLeft "foo"fmap (*2) nRight 6

The Monad instance for Either allows us to chain together multiple actions which may fail, and fail overall if any of the individual steps failed. First we'll write a function that can either parse an Int from a Char, or fail.

Example3 expressions
import Data.Char ( digitToInt, isDigit ):{    let parseEither :: Char -> Either String Int        parseEither c          | isDigit c = Right (digitToInt c)          | otherwise = Left "parse error":}

The following should work, since both '1' and '2' can be parsed as Ints.

Example2 expressions
:{    let parseMultiple :: Either String Int        parseMultiple = do          x <- parseEither '1'          y <- parseEither '2'          return (x + y):}
Example1 expression
parseMultipleRight 3

But the following should fail overall, since the first operation where we attempt to parse 'm' as an Int will fail:

Example2 expressions
:{    let parseMultiple :: Either String Int        parseMultiple = do          x <- parseEither 'm'          y <- parseEither '2'          return (x + y):}
Example1 expression
parseMultipleLeft "parse error"

Constructors

Instances42Bifoldable, Bifoldable1, Bifunctor, Bitraversable, Eq2, Ord2, …
classclass Foldable (t :: Type -> Type) where
#

The Foldable class represents data structures that can be reduced to a summary value one element at a time. Strict left-associative folds are a good fit for space-efficient reduction, while lazy right-associative folds are a good fit for corecursive iteration, or for folds that short-circuit after processing an initial subsequence of the structure's elements.

Instances can be derived automatically by enabling the DeriveFoldable extension. For example, a derived instance for a binary tree might be:

{-# LANGUAGE DeriveFoldable #-}
data Tree a = Empty
            | Leaf a
            | Node (Tree a) a (Tree a)
    deriving Foldable

A more detailed description can be found in the Overview section of Data.Foldable#overview.

For the class laws see the Laws section of Data.Foldable#laws.

Methods

  • foldMap :: Monoid m => (a -> m) -> t a -> m

    Map each element of the structure into a monoid, and combine the results with (<>). This fold is right-associative and lazy in the accumulator. For strict left-associative folds consider foldMap' instead.

    Examples

    Basic usage:

    Example1 expression
    foldMap Sum [1, 3, 5]Sum {getSum = 9}
    Example1 expression
    foldMap Product [1, 3, 5]Product {getProduct = 15}
    Example1 expression
    foldMap (replicate 3) [1, 2, 3][1,1,1,2,2,2,3,3,3]

    When a Monoid's (<>) is lazy in its second argument, foldMap can return a result even from an unbounded structure. For example, lazy accumulation enables Data.ByteString.Builder to efficiently serialise large data structures and produce the output incrementally:

    Example5 expressions
    import qualified Data.ByteString.Lazy as Limport qualified Data.ByteString.Builder as Blet bld :: Int -> B.Builder; bld i = B.intDec i <> B.word8 0x20let lbs = B.toLazyByteString $ foldMap bld [0..]L.take 64 lbs"0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24"
  • foldr :: (a -> b -> b) -> b -> t a -> b

    Right-associative fold of a structure, lazy in the accumulator.

    In the case of lists, foldr, when applied to a binary operator, a starting value (typically the right-identity of the operator), and a list, reduces the list using the binary operator, from right to left:

    foldr f z [x1, x2, ..., xn] == x1 `f` (x2 `f` ... (xn `f` z)...)

    Note that since the head of the resulting expression is produced by an application of the operator to the first element of the list, given an operator lazy in its right argument, foldr can produce a terminating expression from an unbounded list.

    For a general Foldable structure this should be semantically identical to,

    foldr f z = foldr f z . toList
    Examples

    Basic usage:

    Example1 expression
    foldr (||) False [False, True, False]True
    Example1 expression
    foldr (||) False []False
    Example1 expression
    foldr (\c acc -> acc ++ [c]) "foo" ['a', 'b', 'c', 'd']"foodcba"
    Infinite structures

    ⚠️ Applying foldr to infinite structures usually doesn't terminate.

    It may still terminate under one of the following conditions:

    • the folding function is short-circuiting

    • the folding function is lazy on its second argument

    Short-circuiting

    (||) short-circuits on True values, so the following terminates because there is a True value finitely far from the left side:

    Example1 expression
    foldr (||) False (True : repeat False)True

    But the following doesn't terminate:

    Example1 expression
    foldr (||) False (repeat False ++ [True])* Hangs forever *
    Laziness in the second argument

    Applying foldr to infinite structures terminates when the operator is lazy in its second argument (the initial accumulator is never used in this case, and so could be left undefined, but [] is more clear):

    Example1 expression
    take 5 $ foldr (\i acc -> i : fmap (+3) acc) [] (repeat 1)[1,4,7,10,13]
  • foldl :: (b -> a -> b) -> b -> t a -> b

    Left-associative fold of a structure, lazy in the accumulator. This is rarely what you want, but can work well for structures with efficient right-to-left sequencing and an operator that is lazy in its left argument.

    In the case of lists, foldl, when applied to a binary operator, a starting value (typically the left-identity of the operator), and a list, reduces the list using the binary operator, from left to right:

    foldl f z [x1, x2, ..., xn] == (...((z `f` x1) `f` x2) `f`...) `f` xn

    Note that to produce the outermost application of the operator the entire input list must be traversed. Like all left-associative folds, foldl will diverge if given an infinite list.

    If you want an efficient strict left-fold, you probably want to use foldl' instead of foldl. The reason for this is that the latter does not force the inner results (e.g. z `f` x1 in the above example) before applying them to the operator (e.g. to (`f` x2)). This results in a thunk chain O(n) elements long, which then must be evaluated from the outside-in.

    For a general Foldable structure this should be semantically identical to:

    foldl f z = foldl f z . toList
    Examples

    The first example is a strict fold, which in practice is best performed with foldl'.

    Example1 expression
    foldl (+) 42 [1,2,3,4]52

    Though the result below is lazy, the input is reversed before prepending it to the initial accumulator, so corecursion begins only after traversing the entire input string.

    Example1 expression
    foldl (\acc c -> c : acc) "abcd" "efgh""hgfeabcd"

    A left fold of a structure that is infinite on the right cannot terminate, even when for any finite input the fold just returns the initial accumulator:

    Example1 expression
    foldl (\a _ -> a) 0 $ repeat 1* Hangs forever *

    WARNING: When it comes to lists, you always want to use either foldl' or foldr instead.

  • foldl' :: (b -> a -> b) -> b -> t a -> b

    Left-associative fold of a structure but with strict application of the operator.

    This ensures that each step of the fold is forced to Weak Head Normal Form before being applied, avoiding the collection of thunks that would otherwise occur. This is often what you want to strictly reduce a finite structure to a single strict result (e.g. sum).

    For a general Foldable structure this should be semantically identical to,

    foldl' f z = foldl' f z . toList
  • null :: t a -> Bool

    Test whether the structure is empty. The default implementation is Left-associative and lazy in both the initial element and the accumulator. Thus optimised for structures where the first element can be accessed in constant time. Structures where this is not the case should have a non-default implementation.

    Examples

    Basic usage:

    Example1 expression
    null []True
    Example1 expression
    null [1]False

    null is expected to terminate even for infinite structures. The default implementation terminates provided the structure is bounded on the left (there is a leftmost element).

    Example1 expression
    null [1..]False
  • length :: t a -> Int

    Returns the size/length of a finite structure as an Int. The default implementation just counts elements starting with the leftmost. Instances for structures that can compute the element count faster than via element-by-element counting, should provide a specialised implementation.

    Examples

    Basic usage:

    Example1 expression
    length []0
    Example2 expressions
    length ['a', 'b', 'c']3length [1..]* Hangs forever *
  • elem :: Eq a => a -> t a -> Boolinfix 4

    Does the element occur in the structure?

    Note: elem is often used in infix form.

    Examples

    Basic usage:

    Example1 expression
    3 `elem` []False
    Example1 expression
    3 `elem` [1,2]False
    Example1 expression
    3 `elem` [1,2,3,4,5]True

    For infinite structures, the default implementation of elem terminates if the sought-after value exists at a finite distance from the left side of the structure:

    Example1 expression
    3 `elem` [1..]True
    Example1 expression
    3 `elem` ([4..] ++ [3])* Hangs forever *
  • sum :: Num a => t a -> a

    The sum function computes the sum of the numbers of a structure.

    Examples

    Basic usage:

    Example1 expression
    sum []0
    Example1 expression
    sum [42]42
    Example1 expression
    sum [1..10]55
    Example1 expression
    sum [4.1, 2.0, 1.7]7.8
    Example1 expression
    sum [1..]* Hangs forever *
  • product :: Num a => t a -> a

    The product function computes the product of the numbers of a structure.

    Examples

    Basic usage:

    Example1 expression
    product []1
    Example1 expression
    product [42]42
    Example1 expression
    product [1..10]3628800
    Example1 expression
    product [4.1, 2.0, 1.7]13.939999999999998
    Example1 expression
    product [1..]* Hangs forever *
Instances110Foldable, …
classclass (Functor t, Foldable t) => Traversable (t :: Type -> Type) where
#

Functors representing data structures that can be transformed to structures of the same shape by performing an Applicative (or, therefore, Monad) action on each element from left to right.

A more detailed description of what same shape means, the various methods, how traversals are constructed, and example advanced use-cases can be found in the Overview section of Data.Traversable#overview.

For the class laws see the Laws section of Data.Traversable#laws.

Methods

  • traverse :: Applicative f => (a -> f b) -> t a -> f (t b)

    Map each element of a structure to an action, evaluate these actions from left to right, and collect the results. For a version that ignores the results see traverse_.

    Examples

    Basic usage:

    In the first two examples we show each evaluated action mapping to the output structure.

    Example1 expression
    traverse Just [1,2,3,4]Just [1,2,3,4]
    Example1 expression
    traverse id [Right 1, Right 2, Right 3, Right 4]Right [1,2,3,4]

    In the next examples, we show that Nothing and Left values short circuit the created structure.

    Example1 expression
    traverse (const Nothing) [1,2,3,4]Nothing
    Example1 expression
    traverse (\x -> if odd x then Just x else Nothing)  [1,2,3,4]Nothing
    Example1 expression
    traverse id [Right 1, Right 2, Right 3, Right 4, Left 0]Left 0
  • sequenceA :: Applicative f => t (f a) -> f (t a)

    Evaluate each action in the structure from left to right, and collect the results. For a version that ignores the results see sequenceA_.

    Examples

    Basic usage:

    For the first two examples we show sequenceA fully evaluating a a structure and collecting the results.

    Example1 expression
    sequenceA [Just 1, Just 2, Just 3]Just [1,2,3]
    Example1 expression
    sequenceA [Right 1, Right 2, Right 3]Right [1,2,3]

    The next two example show Nothing and Just will short circuit the resulting structure if present in the input. For more context, check the Traversable instances for Either and Maybe.

    Example1 expression
    sequenceA [Just 1, Just 2, Just 3, Nothing]Nothing
    Example1 expression
    sequenceA [Right 1, Right 2, Right 3, Left 4]Left 4
  • mapM :: Monad m => (a -> m b) -> t a -> m (t b)

    Map each element of a structure to a monadic action, evaluate these actions from left to right, and collect the results. For a version that ignores the results see Data.Foldable.mapM_.

    Examples

    mapM is literally a traverse with a type signature restricted to Monad. Its implementation may be more efficient due to additional power of Monad.

  • sequence :: Monad m => t (m a) -> m (t a)

    Evaluate each monadic action in the structure from left to right, and collect the results. For a version that ignores the results see Data.Foldable.sequence_.

    Examples

    Basic usage:

    The first two examples are instances where the input and and output of sequence are isomorphic.

    Example1 expression
    sequence $ Right [1,2,3,4][Right 1,Right 2,Right 3,Right 4]
    Example1 expression
    sequence $ [Right 1,Right 2,Right 3,Right 4]Right [1,2,3,4]

    The following examples demonstrate short circuit behavior for sequence.

    Example1 expression
    sequence $ Left [1,2,3,4]Left [1,2,3,4]
    Example1 expression
    sequence $ [Left 0, Right 1,Right 2,Right 3,Right 4]Left 0
Instances105Traversable, …
classclass Bounded a where
#

The Bounded class is used to name the upper and lower limits of a type. Ord is not a superclass of Bounded since types that are not totally ordered may also have upper and lower bounds.

The Bounded class may be derived for any enumeration type; minBound is the first constructor listed in the data declaration and maxBound is the last. Bounded may also be derived for single-constructor datatypes whose constituent types are in Bounded.

Methods

Instances127Bounded, …
classclass Enum a where
#

Class Enum defines operations on sequentially ordered types.

The enumFrom... methods are used in Haskell's translation of arithmetic sequences.

Instances of Enum may be derived for any enumeration type (types whose constructors have no fields). The nullary constructors are assumed to be numbered left-to-right by fromEnum from 0 through n-1. See Chapter 10 of the Haskell Report for more details.

For any type that is an instance of class Bounded as well as Enum, the following should hold:

   enumFrom     x   = enumFromTo     x maxBound
   enumFromThen x y = enumFromThenTo x y bound
     where
       bound | fromEnum y >= fromEnum x = maxBound
             | otherwise                = minBound

Methods

  • succ :: a -> a

    Successor of a value. For numeric types, succ adds 1.

  • pred :: a -> a

    Predecessor of a value. For numeric types, pred subtracts 1.

  • toEnum :: Int -> a

    Convert from an Int.

  • fromEnum :: a -> Int

    Convert to an Int. It is implementation-dependent what fromEnum returns when applied to a value that is too large to fit in an Int.

  • enumFrom :: a -> [a]

    Used in Haskell's translation of [n..] with [n..] = enumFrom n, a possible implementation being enumFrom n = n : enumFrom (succ n).

    Examples
    • enumFrom 4 :: [Integer] = [4,5,6,7,...]
    • enumFrom 6 :: [Int] = [6,7,8,9,...,maxBound :: Int]
  • enumFromThen :: a -> a -> [a]

    Used in Haskell's translation of [n,n'..] with [n,n'..] = enumFromThen n n', a possible implementation being enumFromThen n n' = n : n' : worker (f x) (f x n'), worker s v = v : worker s (s v), x = fromEnum n' - fromEnum n and

      f n y
        | n > 0 = f (n - 1) (succ y)
        | n < 0 = f (n + 1) (pred y)
        | otherwise = y
      
    Examples
    • enumFromThen 4 6 :: [Integer] = [4,6,8,10...]
    • enumFromThen 6 2 :: [Int] = [6,2,-2,-6,...,minBound :: Int]
  • enumFromTo :: a -> a -> [a]

    Used in Haskell's translation of [n..m] with [n..m] = enumFromTo n m, a possible implementation being

      enumFromTo n m
         | n <= m = n : enumFromTo (succ n) m
         | otherwise = []
      
    Examples
    • enumFromTo 6 10 :: [Int] = [6,7,8,9,10]
    • enumFromTo 42 1 :: [Integer] = []
  • enumFromThenTo :: a -> a -> a -> [a]

    Used in Haskell's translation of [n,n'..m] with [n,n'..m] = enumFromThenTo n n' m, a possible implementation being enumFromThenTo n n' m = worker (f x) (c x) n m, x = fromEnum n' - fromEnum n, c x = bool (>=) ((x 0)

      f n y
         | n > 0 = f (n - 1) (succ y)
         | n < 0 = f (n + 1) (pred y)
         | otherwise = y
      

    and

      worker s c v m
         | c v m = v : worker s c (s v) m
         | otherwise = []
      
    Examples
    • enumFromThenTo 4 2 -6 :: [Integer] = [4,2,0,-2,-4,-6]
    • enumFromThenTo 6 8 2 :: [Int] = []
Instances178Enum, …
  • Enum IoManagerFlagDefined in base-4.23.0.0 · GHC.RTS.Flags
  • Enum FileTypeDefined in directory-1.3.11.0 · System.Directory.Internal.Common
  • Enum XdgDirectoryDefined in directory-1.3.11.0 · System.Directory.Internal.Common
  • Enum XdgDirectoryListDefined in directory-1.3.11.0 · System.Directory.Internal.Common
  • Enum ByteOffDefined in ghc-10.0.0.20260917 · GHC.ByteCode.Types
  • Enum HalfWordDefined in ghc-10.0.0.20260917 · GHC.ByteCode.Types
  • Enum RegBitmapDefined in ghc-10.0.0.20260917 · GHC.ByteCode.Types
  • Enum WordOffDefined in ghc-10.0.0.20260917 · GHC.ByteCode.Types
  • Enum EdgeWeightDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.CFG
  • Enum DwarfAbbrevDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.Dwarf.Types
  • Enum RegClassDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.Reg.Graph.Base
  • Enum RegSubDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.Reg.Graph.Base
  • Enum TypeOrderingDefined in ghc-10.0.0.20260917 · GHC.Core.TyCo.Compare
  • Enum PrimElemRepDefined in ghc-10.0.0.20260917 · GHC.Core.TyCon
  • Enum OverridingBoolDefined in ghc-10.0.0.20260917 · GHC.Data.Bool
  • Enum DumpFlagDefined in ghc-10.0.0.20260917 · GHC.Driver.Flags
  • Enum GeneralFlagDefined in ghc-10.0.0.20260917 · GHC.Driver.Flags
  • Enum LanguageDefined in ghc-10.0.0.20260917 · GHC.Driver.Flags
  • Enum WarningFlagDefined in ghc-10.0.0.20260917 · GHC.Driver.Flags
  • Enum WarningGroupDefined in ghc-10.0.0.20260917 · GHC.Driver.Flags
  • Enum CompressionIFaceDefined in ghc-10.0.0.20260917 · GHC.Iface.Binary
  • Enum BindTypeDefined in ghc-10.0.0.20260917 · GHC.Iface.Ext.Types
  • Enum DeclTypeDefined in ghc-10.0.0.20260917 · GHC.Iface.Ext.Types
  • Enum EntityInfoDefined in ghc-10.0.0.20260917 · GHC.Iface.Ext.Types
  • Enum IETypeDefined in ghc-10.0.0.20260917 · GHC.Iface.Ext.Types
  • Enum NodeOriginDefined in ghc-10.0.0.20260917 · GHC.Iface.Ext.Types
  • Enum RecFieldContextDefined in ghc-10.0.0.20260917 · GHC.Iface.Ext.Types
  • Enum AOpDefined in ghc-10.0.0.20260917 · GHC.JS.JStg.Syntax
  • Enum OpDefined in ghc-10.0.0.20260917 · GHC.JS.JStg.Syntax
  • Enum UOpDefined in ghc-10.0.0.20260917 · GHC.JS.JStg.Syntax
  • Enum AOpDefined in ghc-10.0.0.20260917 · GHC.JS.Syntax
  • Enum OpDefined in ghc-10.0.0.20260917 · GHC.JS.Syntax
  • Enum UOpDefined in ghc-10.0.0.20260917 · GHC.JS.Syntax
  • Enum MetaIdDefined in ghc-10.0.0.20260917 · GHC.Llvm.MetaData
  • Enum ExtBitsDefined in ghc-10.0.0.20260917 · GHC.Parser.Lexer
  • Enum StgRetDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Regs
  • Enum ClosureTypeDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Enum IdTypeDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Enum JSFFITypeDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Enum JSRepDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Enum ThreadStatusDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Enum ImportLevelDefined in ghc-10.0.0.20260917 · GHC.Types.Basic
  • Enum IndexedCCFlavourDefined in ghc-10.0.0.20260917 · GHC.Types.CostCentre
  • Enum LitNumTypeDefined in ghc-10.0.0.20260917 · GHC.Types.Literal
  • Enum ProfAutoDefined in ghc-10.0.0.20260917 · GHC.Types.ProfAuto
  • Enum UniqueTagDefined in ghc-10.0.0.20260917 · GHC.Types.Unique
  • Enum ModuleStageDefined in ghc-10.0.0.20260917 · GHC.Unit.Module.Stage
  • Enum CCallConvDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Decls.Foreign
  • Enum ForeignKindDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Decls.Foreign
  • Enum SafetyDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Decls.Foreign
  • Enum IntegerDefined in ghc-internal-10.0.0 · GHC.Internal.Enum
  • Enum NaturalDefined in ghc-internal-10.0.0 · GHC.Internal.Enum
  • Enum ByteOrderDefined in ghc-internal-10.0.0 · GHC.Internal.ByteOrder
  • Enum ClosureTypeDefined in ghc-internal-10.0.0 · GHC.Internal.ClosureTypes
  • Enum CBoolDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Enum CCharDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Enum CClockDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Enum CDoubleDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Enum CFloatDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Enum CIntDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Enum CIntMaxDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Enum CIntPtrDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Enum CLLongDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Enum CLongDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Enum CPtrdiffDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Enum CSCharDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Enum CSUSecondsDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Enum CShortDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Enum CSigAtomicDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Enum CSizeDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Enum CTimeDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Enum CUCharDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Enum CUIntDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Enum CUIntMaxDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Enum CUIntPtrDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Enum CULLongDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Enum CULongDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Enum CUSecondsDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Enum CUShortDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Enum CWcharDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Enum IntPtrDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.Ptr
  • Enum WordPtrDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.Ptr
  • Enum AssociativityDefined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Enum DecidedStrictnessDefined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Enum SourceStrictnessDefined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Enum SourceUnpackednessDefined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Enum HalfWordDefined in ghc-internal-10.0.0 · GHC.Internal.Heap.InfoTable.Types
  • Enum SeekModeDefined in ghc-internal-10.0.0 · GHC.Internal.IO.Device
  • Enum IOModeDefined in ghc-internal-10.0.0 · GHC.Internal.IO.IOMode
  • Enum IoSubSystemDefined in ghc-internal-10.0.0 · GHC.Internal.IO.SubSystem
  • Enum Int16Defined in ghc-internal-10.0.0 · GHC.Internal.Int
  • Enum Int32Defined in ghc-internal-10.0.0 · GHC.Internal.Int
  • Enum Int64Defined in ghc-internal-10.0.0 · GHC.Internal.Int
  • Enum Int8Defined in ghc-internal-10.0.0 · GHC.Internal.Int
  • Enum ExtensionDefined in ghc-internal-10.0.0 · GHC.Internal.LanguageExtensions
  • Enum DoCostCentresDefined in ghc-internal-10.0.0 · GHC.Internal.RTS.Flags
  • Enum DoHeapProfileDefined in ghc-internal-10.0.0 · GHC.Internal.RTS.Flags
  • Enum DoTraceDefined in ghc-internal-10.0.0 · GHC.Internal.RTS.Flags
  • Enum GiveGCStatsDefined in ghc-internal-10.0.0 · GHC.Internal.RTS.Flags
  • Enum IoManagerFlagDefined in ghc-internal-10.0.0 · GHC.Internal.RTS.Flags
  • Enum ByteOffsetDefined in ghc-internal-10.0.0 · GHC.Internal.Stack.Constants
  • Enum WordOffsetDefined in ghc-internal-10.0.0 · GHC.Internal.Stack.Constants
  • Enum ByteOffsetDefined in ghc-internal-10.0.0 · GHC.Internal.Stack.ConstantsProf
  • Enum WordOffsetDefined in ghc-internal-10.0.0 · GHC.Internal.Stack.ConstantsProf
  • Enum CBlkCntDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Enum CBlkSizeDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Enum CCcDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Enum CClockIdDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Enum CDevDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Enum CFsBlkCntDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Enum CFsFilCntDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Enum CGidDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Enum CIdDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Enum CInoDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Enum CKeyDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Enum CModeDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Enum CNfdsDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Enum CNlinkDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Enum COffDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Enum CPidDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Enum CRLimDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Enum CSocklenDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Enum CSpeedDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Enum CSsizeDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Enum CTcflagDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Enum CUidDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Enum FdDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Enum BoolDefined in ghc-internal-10.0.0 · GHC.Internal.Enum
  • Enum CharDefined in ghc-internal-10.0.0 · GHC.Internal.Enum
  • Enum DoubleDefined in ghc-internal-10.0.0 · GHC.Internal.Float · orphan

    fromEnum just truncates its argument, beware of all sorts of overflows.

    List generators have extremely peculiar behavior, mandated by Haskell Report 2010:

    Example1 expression
    [0..1.5][0.0,1.0,2.0]
  • Enum FloatDefined in ghc-internal-10.0.0 · GHC.Internal.Float · orphan

    fromEnum just truncates its argument, beware of all sorts of overflows.

    List generators have extremely peculiar behavior, mandated by Haskell Report 2010:

    Example1 expression
    [0..1.5 :: Float][0.0,1.0,2.0]
  • Enum IntDefined in ghc-internal-10.0.0 · GHC.Internal.Enum
  • Enum LevityDefined in ghc-internal-10.0.0 · GHC.Internal.Enum
  • Enum OrderingDefined in ghc-internal-10.0.0 · GHC.Internal.Enum
  • Enum VecCountDefined in ghc-internal-10.0.0 · GHC.Internal.Enum
  • Enum VecElemDefined in ghc-internal-10.0.0 · GHC.Internal.Enum
  • Enum WordDefined in ghc-internal-10.0.0 · GHC.Internal.Enum
  • Enum GeneralCategoryDefined in ghc-internal-10.0.0 · GHC.Internal.Unicode
  • Enum Word16Defined in ghc-internal-10.0.0 · GHC.Internal.Word
  • Enum Word32Defined in ghc-internal-10.0.0 · GHC.Internal.Word
  • Enum Word64Defined in ghc-internal-10.0.0 · GHC.Internal.Word
  • Enum Word8Defined in ghc-internal-10.0.0 · GHC.Internal.Word
  • Enum THResultTypeDefined in ghci-10.0.0.20260917 · GHCi.Message
  • Enum I8Defined in text-2.1.4 · Data.Text.Foreign
  • Enum FPFormatDefined in text-2.1.4 · Data.Text.Lazy.Builder.RealFloat
  • Enum DayDefined in time-1.16.0.1 · Data.Time.Calendar.Days
  • Enum MonthDefined in time-1.16.0.1 · Data.Time.Calendar.Month
  • Enum QuarterDefined in time-1.16.0.1 · Data.Time.Calendar.Quarter
  • Enum QuarterOfYearDefined in time-1.16.0.1 · Data.Time.Calendar.Quarter

    maps Q1..Q4 to 1..4

  • Enum DayOfWeekDefined in time-1.16.0.1 · Data.Time.Calendar.Week

    "Circular", so for example [Tuesday ..] gives an endless sequence. Also: fromEnum gives [1 .. 7] for [Monday .. Sunday], and toEnum performs mod 7 to give a cycle of days.

  • Enum DiffTimeDefined in time-1.16.0.1 · Data.Time.Clock.Internal.DiffTime
  • Enum NominalDiffTimeDefined in time-1.16.0.1 · Data.Time.Clock.Internal.NominalDiffTime
  • Enum StatxFlagsDefined in unix-2.8.8.0 · System.Posix.Files.Common
  • Enum StatxMaskDefined in unix-2.8.8.0 · System.Posix.Files.Common
  • Enum BaudRateDefined in unix-2.8.8.0 · System.Posix.Terminal.Common
  • Enum ()Defined in ghc-internal-10.0.0 · GHC.Internal.Enum
  • Enum a => Enum (First a)Defined in base-4.23.0.0 · Data.Semigroup
  • Enum a => Enum (Last a)Defined in base-4.23.0.0 · Data.Semigroup
  • Enum a => Enum (Max a)Defined in base-4.23.0.0 · Data.Semigroup
  • Enum a => Enum (Min a)Defined in base-4.23.0.0 · Data.Semigroup
  • Enum a => Enum (WrappedMonoid a)Defined in base-4.23.0.0 · Data.Semigroup
  • Enum a => Enum (And a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Bits
  • Enum a => Enum (Iff a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Bits
  • Enum a => Enum (Ior a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Bits
  • Enum a => Enum (Xor a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Bits
  • Enum a => Enum (Identity a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Functor.Identity
  • Enum a => Enum (a)Defined in ghc-internal-10.0.0 · GHC.Internal.Enum
  • Integral a => Enum (Ratio a)Defined in ghc-internal-10.0.0 · GHC.Internal.Real
  • (Enum a, Bounded a, Eq a) => Enum (Down a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Ord

    Swaps succ and pred of the underlying type.

  • Enum (Fixed a)Defined in base-4.23.0.0 · Data.Fixed

    Recall that, for numeric types, succ and pred typically add and subtract 1, respectively. This is not true in the case of Fixed, whose successor and predecessor functions intuitively return the "next" and "previous" values in the enumeration. The results of these functions thus depend on the resolution of the Fixed value. For example, when enumerating values of resolution 10^-3 of type Milli = Fixed E3,

    Example1 expression
    succ (0.000 :: Milli)0.001

    and likewise

    Example1 expression
    pred (0.000 :: Milli)-0.001

    In other words, succ and pred increment and decrement a fixed-precision value by the least amount such that the value's resolution is unchanged. For example, 10^-12 is the smallest (positive) amount that can be added to a value of type Pico = Fixed E12 without changing its resolution, and so

    Example1 expression
    succ (0.000000000000 :: Pico)0.000000000001

    and similarly

    Example1 expression
    pred (0.000000000000 :: Pico)-0.000000000001

    This is worth bearing in mind when defining Fixed arithmetic sequences. In particular, you may be forgiven for thinking the sequence

      [1..10] :: [Pico]
    

    evaluates to [1, 2, 3, 4, 5, 6, 7, 8, 9, 10] :: [Pico].

    However, this is not true. On the contrary, similarly to the above implementations of succ and pred, enumFromTo :: Pico -> Pico -> [Pico] has a "step size" of 10^-12. Hence, the list [1..10] :: [Pico] has the form

      [1.000000000000, 1.00000000001, 1.00000000002, ..., 10.000000000000]
    

    and contains 9 * 10^12 + 1 values.

  • Enum (Proxy s)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Proxy
  • Enum (f a) => Enum (Ap f a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Monoid
  • Enum (f a) => Enum (Alt f a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Semigroup.Internal
  • Enum a => Enum (Const a b)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Functor.Const
  • Coercible a b => Enum (Coercion a b)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Type.Coercion
  • a ~ b => Enum (a :~: b)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Type.Equality
  • a ~~ b => Enum (a :~~: b)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Type.Equality
  • Enum (f (g a)) => Enum (Compose f g a)Defined in base-4.23.0.0 · Data.Functor.Compose
classclass Fractional a => Floating a where
#

Trigonometric and hyperbolic functions and related functions.

The Haskell Report defines no laws for Floating. However, (+), (*) and exp are customarily expected to define an exponential field and have the following properties:

  • exp (a + b) = exp a * exp b

  • exp (fromInteger 0) = fromInteger 1

Methods

Instances10Floating, …
classclass (RealFrac a, Floating a) => RealFloat a where
#

Efficient, machine-independent access to the components of a floating-point number.

Methods

  • floatRadix :: a -> Integer

    a constant function, returning the radix of the representation (often 2)

  • floatDigits :: a -> Int

    a constant function, returning the number of digits of floatRadix in the significand

  • floatRange :: a -> (Int, Int)

    A constant function, returning the lowest and highest values that exponent x may assume for a normal x. The relation to IEEE emin and emax is floatRange x = (emin + 1, emax + 1).

  • decodeFloat :: a -> (Integer, Int)

    The function decodeFloat applied to a real floating-point number returns the significand expressed as an Integer and an appropriately scaled exponent (an Int). If decodeFloat x yields (m,n), then x is equal in value to m*b^^n, where b is the floating-point radix, and furthermore, either m and n are both zero or else b^(d-1) <= abs m < b^d, where d is the value of floatDigits x. In particular, decodeFloat 0 = (0,0). If the type contains a negative zero, also decodeFloat (-0.0) = (0,0). The result of decodeFloat x is unspecified if either of isNaN x or isInfinite x is True.

  • encodeFloat :: Integer -> Int -> a

    encodeFloat performs the inverse of decodeFloat in the sense that for finite x with the exception of -0.0, Prelude.uncurry encodeFloat (decodeFloat x) = x. encodeFloat m n is one of the two closest representable floating-point numbers to m*b^^n (or ±Infinity if overflow occurs); usually the closer, but if m contains too many bits, the result may be rounded in the wrong direction.

  • exponent :: a -> Int

    exponent corresponds to the second component of decodeFloat. exponent 0 = 0 and for finite nonzero x, exponent x = snd (decodeFloat x) + floatDigits x. If x is a finite floating-point number, it is equal in value to significand x * b ^^ exponent x, where b is the floating-point radix. The behaviour is unspecified on infinite or NaN values.

  • significand :: a -> a

    The first component of decodeFloat, scaled to lie in the open interval (-1,1), either 0.0 or of absolute value >= 1/b, where b is the floating-point radix. The behaviour is unspecified on infinite or NaN values.

  • scaleFloat :: Int -> a -> a

    multiplies a floating-point number by an integer power of the radix

  • isNaN :: a -> Bool

    True if the argument is an IEEE "not-a-number" (NaN) value

  • isInfinite :: a -> Bool

    True if the argument is an IEEE infinity or negative infinity

  • isDenormalized :: a -> Bool

    True if the argument is too small to be represented in normalized format

  • isNegativeZero :: a -> Bool

    True if the argument is an IEEE negative zero

  • isIEEE :: a -> Bool

    True if the argument is an IEEE floating point number

  • atan2 :: a -> a -> a

    a version of arctangent taking two real floating-point arguments. For real floating x and y, atan2 y x computes the angle (from the positive x-axis) of the vector from the origin to the point (x,y). atan2 y x returns a value in the range [-pi, pi]. It follows the Common Lisp semantics for the origin when signed zeroes are supported. atan2 y 1, with y in a type that is RealFloat, should return the same value as atan y. A default definition of atan2 is provided, but implementors can provide a more accurate implementation.

Instances8RealFloat, …
typetype FilePath = String
#

File and directory names are values of type String, whose precise meaning is operating system dependent. Files can be opened, yielding a handle which can then be used to operate on the contents of that file.

typetype IOError = IOException
#

The Haskell 2010 type for exceptions in the IO monad. Any I/O operation may raise an IOError instead of returning a result. For a more general type of exception, including also those that arise in pure code, see Exception.

In Haskell 2010, this is an opaque type.

classclass Num a where
#

Basic numeric class.

The Haskell Report defines no laws for Num. However, (+) and (*) are customarily expected to define a ring and have the following properties:

Associativity of (+)

(x + y) + z

=

x + (y + z)

Commutativity of (+)

x + y

=

y + x

fromInteger 0 is the additive identity

x + fromInteger 0

=

x

negate gives the additive inverse

x + negate x

=

fromInteger 0

Associativity of (*)

(x * y) * z

=

x * (y * z)

fromInteger 1 is the multiplicative identity

x * fromInteger 1

=

x

and

fromInteger 1 * x

=

x

Distributivity of (*) with respect to (+)

a * (b + c)

=

(a * b) + (a * c)

and

(b + c) * a

=

(b * a) + (c * a)

Coherence with toInteger

if the type also implements

GHC.Real.Integral

, then

fromInteger

is a left inverse for

toInteger

, i.e.

fromInteger (toInteger i) == i

Note that it isn't customarily expected that a type instance of both Num and Ord implement an ordered ring. Indeed, in base only Integer and Data.Ratio.Rational do.

Methods

  • (+) :: a -> a -> ainfixl 6
  • (-) :: a -> a -> ainfixl 6
  • (*) :: a -> a -> ainfixl 7
  • negate :: a -> a

    Unary negation.

  • abs :: a -> a

    Absolute value.

  • signum :: a -> a

    Sign of a number. The functions abs and signum should satisfy the law:

    abs x * signum x == x

    For real numbers, the signum is either -1 (negative), 0 (zero) or 1 (positive).

  • fromInteger :: Integer -> a

    Conversion from an Integer. An integer literal represents the application of the function fromInteger to the appropriate value of type Integer, so such literals have type (Num a) => a.

Instances105Num, …
  • Num ByteOffDefined in ghc-10.0.0.20260917 · GHC.ByteCode.Types
  • Num HalfWordDefined in ghc-10.0.0.20260917 · GHC.ByteCode.Types
  • Num RegBitmapDefined in ghc-10.0.0.20260917 · GHC.ByteCode.Types
  • Num WordOffDefined in ghc-10.0.0.20260917 · GHC.ByteCode.Types
  • Num EdgeWeightDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.CFG
  • Num TimeDefined in ghc-10.0.0.20260917 · GHC.Data.Graph.Directed
  • Num JStgExprDefined in ghc-10.0.0.20260917 · GHC.JS.Make · orphan
  • Num IntWithInfDefined in ghc-10.0.0.20260917 · GHC.Types.Basic
  • Num SaneDoubleDefined in ghc-10.0.0.20260917 · GHC.Types.SaneDouble
  • Num IntegerDefined in ghc-internal-10.0.0 · GHC.Internal.Num
  • Num NaturalDefined in ghc-internal-10.0.0 · GHC.Internal.Num

    Note that Natural's Num instance isn't a ring: no element but 0 has an additive inverse. It is a semiring though.

  • Num EventTypeDefined in ghc-internal-10.0.0 · GHC.Internal.Event.EPoll
  • Num EventDefined in ghc-internal-10.0.0 · GHC.Internal.Event.Poll
  • Num UniqueDefined in ghc-internal-10.0.0 · GHC.Internal.Event.Unique
  • Num CBoolDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Num CCharDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Num CClockDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Num CDoubleDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Num CFloatDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Num CIntDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Num CIntMaxDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Num CIntPtrDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Num CLLongDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Num CLongDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Num CPtrdiffDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Num CSCharDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Num CSUSecondsDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Num CShortDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Num CSigAtomicDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Num CSizeDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Num CTimeDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Num CUCharDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Num CUIntDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Num CUIntMaxDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Num CUIntPtrDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Num CULLongDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Num CULongDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Num CUSecondsDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Num CUShortDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Num CWcharDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Num IntPtrDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.Ptr
  • Num WordPtrDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.Ptr
  • Num HalfWordDefined in ghc-internal-10.0.0 · GHC.Internal.Heap.InfoTable.Types
  • Num Int16Defined in ghc-internal-10.0.0 · GHC.Internal.Int
  • Num Int32Defined in ghc-internal-10.0.0 · GHC.Internal.Int
  • Num Int64Defined in ghc-internal-10.0.0 · GHC.Internal.Int
  • Num Int8Defined in ghc-internal-10.0.0 · GHC.Internal.Int
  • Num ByteOffsetDefined in ghc-internal-10.0.0 · GHC.Internal.Stack.Constants
  • Num WordOffsetDefined in ghc-internal-10.0.0 · GHC.Internal.Stack.Constants
  • Num ByteOffsetDefined in ghc-internal-10.0.0 · GHC.Internal.Stack.ConstantsProf
  • Num WordOffsetDefined in ghc-internal-10.0.0 · GHC.Internal.Stack.ConstantsProf
  • Num CBlkCntDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Num CBlkSizeDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Num CCcDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Num CClockIdDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Num CDevDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Num CFsBlkCntDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Num CFsFilCntDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Num CGidDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Num CIdDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Num CInoDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Num CKeyDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Num CModeDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Num CNfdsDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Num CNlinkDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Num COffDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Num CPidDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Num CRLimDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Num CSocklenDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Num CSpeedDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Num CSsizeDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Num CTcflagDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Num CUidDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Num FdDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Num DoubleDefined in ghc-internal-10.0.0 · GHC.Internal.Float · orphan

    This instance implements IEEE 754 standard with all its usual pitfalls about NaN, infinities and negative zero. Neither addition nor multiplication are associative or distributive:

    Example3 expressions
    (0.1 + 0.1) + 0.4 == 0.1 + (0.1 + 0.4)False(0.1 + 0.2) * 0.3 == 0.1 * 0.3 + 0.2 * 0.3False(0.1 * 0.1) * 0.3 == 0.1 * (0.1 * 0.3)False
  • Num FloatDefined in ghc-internal-10.0.0 · GHC.Internal.Float · orphan

    This instance implements IEEE 754 standard with all its usual pitfalls about NaN, infinities and negative zero. Neither addition nor multiplication are associative or distributive:

    Example3 expressions
    (0.1 + 0.1 :: Float) + 0.5 == 0.1 + (0.1 + 0.5)False(0.1 + 0.2 :: Float) * 0.9 == 0.1 * 0.9 + 0.2 * 0.9False(0.1 * 0.1 :: Float) * 0.9 == 0.1 * (0.1 * 0.9)False
  • Num IntDefined in ghc-internal-10.0.0 · GHC.Internal.Num
  • Num WordDefined in ghc-internal-10.0.0 · GHC.Internal.Num
  • Num Word16Defined in ghc-internal-10.0.0 · GHC.Internal.Word
  • Num Word32Defined in ghc-internal-10.0.0 · GHC.Internal.Word
  • Num Word64Defined in ghc-internal-10.0.0 · GHC.Internal.Word
  • Num Word8Defined in ghc-internal-10.0.0 · GHC.Internal.Word
  • Num HashDefined in hpc-0.7.0.2 · Trace.Hpc.Util
  • Num I8Defined in text-2.1.4 · Data.Text.Foreign
  • Num SizeDefined in text-2.1.4 · Data.Text.Internal.Fusion.Size
  • Num DiffTimeDefined in time-1.16.0.1 · Data.Time.Clock.Internal.DiffTime
  • Num NominalDiffTimeDefined in time-1.16.0.1 · Data.Time.Clock.Internal.NominalDiffTime
  • Num CAttributesDefined in unix-2.8.8.0 · System.Posix.Files.Common
  • Num StatxFlagsDefined in unix-2.8.8.0 · System.Posix.Files.Common
  • Num StatxMaskDefined in unix-2.8.8.0 · System.Posix.Files.Common
  • Num BaudRateDefined in unix-2.8.8.0 · System.Posix.Terminal.Common
  • RealFloat a => Num (Complex a)Defined in base-4.23.0.0 · Data.Complex
  • Num a => Num (Max a)Defined in base-4.23.0.0 · Data.Semigroup
  • Num a => Num (Min a)Defined in base-4.23.0.0 · Data.Semigroup
  • Num a => Num (Identity a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Functor.Identity
  • Num a => Num (Down a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Ord
  • Num a => Num (Product a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Semigroup.Internal
  • Num a => Num (Sum a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Semigroup.Internal
  • Integral a => Num (Ratio a)Defined in ghc-internal-10.0.0 · GHC.Internal.Real
  • HasResolution a => Num (Fixed a)Defined in base-4.23.0.0 · Data.Fixed

    Multiplication is not associative or distributive:

    Example1 expression
    (0.2 * 0.6 :: Deci) * 0.9 == 0.2 * (0.6 * 0.9)False
    Example1 expression
    (0.1 + 0.1 :: Deci) * 0.5 == 0.1 * 0.5 + 0.1 * 0.5False
  • Num a => Num (Op a b)Defined in base-4.23.0.0 · Data.Functor.Contravariant
  • Num (f a) => Num (Alt f a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Semigroup.Internal
  • Num a => Num (Const a b)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Functor.Const
  • (Applicative f, Num a) => Num (Ap f a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Monoid

    Note that even if the underlying Num and Applicative instances are lawful, for most Applicatives, this instance will not be lawful. If you use this instance with the list Applicative, the following customary laws will not hold:

    Commutativity:

    Example2 expressions
    Ap [10,20] + Ap [1,2]Ap {getAp = [11,12,21,22]}Ap [1,2] + Ap [10,20]Ap {getAp = [11,21,12,22]}

    Additive inverse:

    Example2 expressions
    Ap [] + negate (Ap [])Ap {getAp = []}fromInteger 0 :: Ap [] IntAp {getAp = [0]}

    Distributivity:

    Example2 expressions
    Ap [1,2] * (3 + 4)Ap {getAp = [7,14]}(Ap [1,2] * 3) + (Ap [1,2] * 4)Ap {getAp = [7,11,10,14]}
  • Num (f (g a)) => Num (Compose f g a)Defined in base-4.23.0.0 · Data.Functor.Compose
classclass Read a where
#

Parsing of Strings, producing values.

Derived instances of Read make the following assumptions, which derived instances of Text.Show.Show obey:

  • If the constructor is defined to be an infix operator, then the derived Read instance will parse only infix applications of the constructor (not the prefix form).

  • Associativity is not used to reduce the occurrence of parentheses, although precedence may be.

  • If the constructor is defined using record syntax, the derived Read will parse only the record-syntax form, and furthermore, the fields must be given in the same order as the original declaration.

  • The derived Read instance allows arbitrary Haskell whitespace between tokens of the input string. Extra parentheses are also allowed.

For example, given the declarations

infixr 5 :^:
data Tree a =  Leaf a  |  Tree a :^: Tree a

the derived instance of Read in Haskell 2010 is equivalent to

instance (Read a) => Read (Tree a) where

        readsPrec d r =  readParen (d > app_prec)
                         (\r -> [(Leaf m,t) |
                                 ("Leaf",s) <- lex r,
                                 (m,t) <- readsPrec (app_prec+1) s]) r

                      ++ readParen (d > up_prec)
                         (\r -> [(u:^:v,w) |
                                 (u,s) <- readsPrec (up_prec+1) r,
                                 (":^:",t) <- lex s,
                                 (v,w) <- readsPrec (up_prec+1) t]) r

          where app_prec = 10
                up_prec = 5

Note that right-associativity of :^: is unused.

The derived instance in GHC is equivalent to

instance (Read a) => Read (Tree a) where

        readPrec = parens $ (prec app_prec $ do
                                 Ident "Leaf" <- lexP
                                 m <- step readPrec
                                 return (Leaf m))

                     +++ (prec up_prec $ do
                                 u <- step readPrec
                                 Symbol ":^:" <- lexP
                                 v <- step readPrec
                                 return (u :^: v))

          where app_prec = 10
                up_prec = 5

        readListPrec = readListPrecDefault

Why do both readsPrec and readPrec exist, and why does GHC opt to implement readPrec in derived Read instances instead of readsPrec? The reason is that readsPrec is based on the ReadS type, and although ReadS is mentioned in the Haskell 2010 Report, it is not a very efficient parser data structure.

readPrec, on the other hand, is based on a much more efficient ReadPrec datatype (a.k.a "new-style parsers"), but its definition relies on the use of the RankNTypes language extension. Therefore, readPrec (and its cousin, readListPrec) are marked as GHC-only. Nevertheless, it is recommended to use readPrec instead of readsPrec whenever possible for the efficiency improvements it brings.

As mentioned above, derived Read instances in GHC will implement readPrec instead of readsPrec. The default implementations of readsPrec (and its cousin, readList) will simply use readPrec under the hood. If you are writing a Read instance by hand, it is recommended to write it like so:

instance Read T where
  readPrec     = ...
  readListPrec = readListPrecDefault

Methods

  • readsPrec :: Int -> ReadS a

    attempts to parse a value from the front of the string, returning a list of (parsed value, remaining string) pairs. If there is no successful parse, the returned list is empty.

    Derived instances of Read and Text.Show.Show satisfy the following:

    That is, readsPrec parses the string produced by showsPrec, and delivers the value that showsPrec started with.

  • readList :: ReadS [a]

    The method readList is provided to allow the programmer to give a specialised way of parsing lists of values. For example, this is used by the predefined Read instance of the Char type, where values of type String are expected to use double quotes, rather than square brackets.

Instances253Read, …
  • Read GCDetailsDefined in base-4.23.0.0 · GHC.Stats
  • Read RTSStatsDefined in base-4.23.0.0 · GHC.Stats
  • Read ByteStringDefined in bytestring-0.12.2.0 · Data.ByteString.Internal.Type
  • Read ByteStringDefined in bytestring-0.12.2.0 · Data.ByteString.Lazy.Internal
  • Read ShortByteStringDefined in bytestring-0.12.2.0 · Data.ByteString.Short.Internal
  • Read IntSetDefined in containers-0.8 · Data.IntSet.Internal
  • Read FileTypeDefined in directory-1.3.11.0 · System.Directory.Internal.Common
  • Read PermissionsDefined in directory-1.3.11.0 · System.Directory.Internal.Common
  • Read XdgDirectoryDefined in directory-1.3.11.0 · System.Directory.Internal.Common
  • Read XdgDirectoryListDefined in directory-1.3.11.0 · System.Directory.Internal.Common
  • Read OverridingBoolDefined in ghc-10.0.0.20260917 · GHC.Data.Bool
  • Read Word64SetDefined in ghc-10.0.0.20260917 · GHC.Data.Word64Set.Internal
  • Read PlatformDefined in ghc-10.0.0.20260917 · GHC.Platform
  • Read PlatformWordSizeDefined in ghc-10.0.0.20260917 · GHC.Platform
  • Read PlatformConstantsDefined in ghc-10.0.0.20260917 · GHC.Platform.Constants
  • Read ProfileDefined in ghc-10.0.0.20260917 · GHC.Platform.Profile
  • Read WayDefined in ghc-10.0.0.20260917 · GHC.Platform.Ways
  • Read StgLiftConfigDefined in ghc-10.0.0.20260917 · GHC.Stg.Lift.Config
  • Read StgToDoDefined in ghc-10.0.0.20260917 · GHC.Stg.Pipeline
  • Read VoidDefined in ghc-internal-10.0.0 · GHC.Internal.Read

    Reading a Void value is always a parse error, considering Void as a data type with no constructors.

  • Read IntegerDefined in ghc-internal-10.0.0 · GHC.Internal.Read
  • Read NaturalDefined in ghc-internal-10.0.0 · GHC.Internal.Read
  • Read ByteOrderDefined in ghc-internal-10.0.0 · GHC.Internal.Read
  • Read AllDefined in ghc-internal-10.0.0 · GHC.Internal.Data.Semigroup.Internal
  • Read AnyDefined in ghc-internal-10.0.0 · GHC.Internal.Data.Semigroup.Internal
  • Read VersionDefined in ghc-internal-10.0.0 · GHC.Internal.Data.Version
  • Read CBoolDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Read CCharDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Read CClockDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Read CDoubleDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Read CFloatDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Read CIntDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Read CIntMaxDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Read CIntPtrDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Read CLLongDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Read CLongDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Read CPtrdiffDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Read CSCharDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Read CSUSecondsDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Read CShortDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Read CSigAtomicDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Read CSizeDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Read CTimeDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Read CUCharDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Read CUIntDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Read CUIntMaxDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Read CUIntPtrDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Read CULLongDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Read CULongDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Read CUSecondsDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Read CUShortDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Read CWcharDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Read IntPtrDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.Ptr
  • Read WordPtrDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.Ptr
  • Read AssociativityDefined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Read DecidedStrictnessDefined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Read FixityDefined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Read SourceStrictnessDefined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Read SourceUnpackednessDefined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Read SeekModeDefined in ghc-internal-10.0.0 · GHC.Internal.IO.Device
  • Read ExitCodeDefined in ghc-internal-10.0.0 · GHC.Internal.IO.Exception
  • Read BufferModeDefined in ghc-internal-10.0.0 · GHC.Internal.IO.Handle.Types
  • Read NewlineDefined in ghc-internal-10.0.0 · GHC.Internal.IO.Handle.Types
  • Read NewlineModeDefined in ghc-internal-10.0.0 · GHC.Internal.IO.Handle.Types
  • Read IOModeDefined in ghc-internal-10.0.0 · GHC.Internal.IO.IOMode
  • Read Int16Defined in ghc-internal-10.0.0 · GHC.Internal.Int
  • Read Int32Defined in ghc-internal-10.0.0 · GHC.Internal.Int
  • Read Int64Defined in ghc-internal-10.0.0 · GHC.Internal.Int
  • Read Int8Defined in ghc-internal-10.0.0 · GHC.Internal.Int
  • Read GCDetailsDefined in ghc-internal-10.0.0 · GHC.Internal.Stats
  • Read RTSStatsDefined in ghc-internal-10.0.0 · GHC.Internal.Stats
  • Read CBlkCntDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Read CBlkSizeDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Read CCcDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Read CClockIdDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Read CDevDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Read CFsBlkCntDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Read CFsFilCntDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Read CGidDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Read CIdDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Read CInoDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Read CKeyDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Read CModeDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Read CNfdsDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Read CNlinkDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Read COffDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Read CPidDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Read CRLimDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Read CSocklenDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Read CSpeedDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Read CSsizeDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Read CTcflagDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Read CUidDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Read FdDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Read LexemeDefined in ghc-internal-10.0.0 · GHC.Internal.Read
  • Read SomeCharDefined in ghc-internal-10.0.0 · GHC.Internal.TypeLits
  • Read SomeSymbolDefined in ghc-internal-10.0.0 · GHC.Internal.TypeLits
  • Read SomeNatDefined in ghc-internal-10.0.0 · GHC.Internal.TypeNats
  • Read BoolDefined in ghc-internal-10.0.0 · GHC.Internal.Read
  • Read CharDefined in ghc-internal-10.0.0 · GHC.Internal.Read
  • Read DoubleDefined in ghc-internal-10.0.0 · GHC.Internal.Read
  • Read FloatDefined in ghc-internal-10.0.0 · GHC.Internal.Read
  • Read IntDefined in ghc-internal-10.0.0 · GHC.Internal.Read
  • Read OrderingDefined in ghc-internal-10.0.0 · GHC.Internal.Read
  • Read WordDefined in ghc-internal-10.0.0 · GHC.Internal.Read
  • Read GeneralCategoryDefined in ghc-internal-10.0.0 · GHC.Internal.Read
  • Read Word16Defined in ghc-internal-10.0.0 · GHC.Internal.Read
  • Read Word32Defined in ghc-internal-10.0.0 · GHC.Internal.Read
  • Read Word64Defined in ghc-internal-10.0.0 · GHC.Internal.Read
  • Read Word8Defined in ghc-internal-10.0.0 · GHC.Internal.Read
  • Read ArchDefined in ghc-platform-0.1.0.0 · GHC.Platform.ArchOS
  • Read ArchOSDefined in ghc-platform-0.1.0.0 · GHC.Platform.ArchOS
  • Read ArmABIDefined in ghc-platform-0.1.0.0 · GHC.Platform.ArchOS
  • Read ArmISADefined in ghc-platform-0.1.0.0 · GHC.Platform.ArchOS
  • Read ArmISAExtDefined in ghc-platform-0.1.0.0 · GHC.Platform.ArchOS
  • Read OSDefined in ghc-platform-0.1.0.0 · GHC.Platform.ArchOS
  • Read PPC_64ABIDefined in ghc-platform-0.1.0.0 · GHC.Platform.ArchOS
  • Read LibraryDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Library
  • Read ProgramDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Program
  • Read TargetDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Target
  • Read WordSizeDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Target
  • Read ArDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Tools.Ar
  • Read CcDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Tools.Cc
  • Read CmmCppDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Tools.Cpp
  • Read CppDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Tools.Cpp
  • Read HsCppDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Tools.Cpp
  • Read JsCppDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Tools.Cpp
  • Read CxxDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Tools.Cxx
  • Read CcLinkDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Tools.Link
  • Read MergeObjsDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Tools.MergeObjs
  • Read NmDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Tools.Nm
  • Read RanlibDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Tools.Ranlib
  • Read ReadelfDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Tools.Readelf
  • Read BoxLabelDefined in hpc-0.7.0.2 · Trace.Hpc.Mix
  • Read CondBoxDefined in hpc-0.7.0.2 · Trace.Hpc.Mix
  • Read MixDefined in hpc-0.7.0.2 · Trace.Hpc.Mix
  • Read TixDefined in hpc-0.7.0.2 · Trace.Hpc.Tix
  • Read TixModuleDefined in hpc-0.7.0.2 · Trace.Hpc.Tix
  • Read HashDefined in hpc-0.7.0.2 · Trace.Hpc.Util
  • Read HpcPosDefined in hpc-0.7.0.2 · Trace.Hpc.Util
  • Read CommunicationHandleDefined in process-1.6.30.0 · System.Process.CommunicationHandle.Internal
  • Read I8Defined in text-2.1.4 · Data.Text.Foreign
  • Read TextDefined in text-2.1.4 · Data.Text · orphan
  • Read TextDefined in text-2.1.4 · Data.Text.Lazy · orphan
  • Read FPFormatDefined in text-2.1.4 · Data.Text.Lazy.Builder.RealFloat
  • Read CalendarDiffDaysDefined in time-1.16.0.1 · Data.Time.Format.ISO8601 · orphan
  • Read DayDefined in time-1.16.0.1 · Data.Time.Format.Parse · orphan
  • Read MonthDefined in time-1.16.0.1 · Data.Time.Calendar.Month

    Read as yyyy-mm.

  • Read QuarterDefined in time-1.16.0.1 · Data.Time.Calendar.Quarter

    Read as yyyy-Qn.

  • Read QuarterOfYearDefined in time-1.16.0.1 · Data.Time.Calendar.Quarter
  • Read DayOfWeekDefined in time-1.16.0.1 · Data.Time.Calendar.Week
  • Read DiffTimeDefined in time-1.16.0.1 · Data.Time.Clock.Internal.DiffTime
  • Read NominalDiffTimeDefined in time-1.16.0.1 · Data.Time.Clock.Internal.NominalDiffTime
  • Read UTCTimeDefined in time-1.16.0.1 · Data.Time.Format.Parse · orphan
  • Read UniversalTimeDefined in time-1.16.0.1 · Data.Time.Format.Parse · orphan
  • Read CalendarDiffTimeDefined in time-1.16.0.1 · Data.Time.Format.ISO8601 · orphan
  • Read LocalTimeDefined in time-1.16.0.1 · Data.Time.Format.Parse · orphan
  • Read TimeOfDayDefined in time-1.16.0.1 · Data.Time.Format.Parse · orphan
  • Read TimeZoneDefined in time-1.16.0.1 · Data.Time.Format.Parse · orphan

    This only works for ±HHMM format, single-letter military time-zones, and these time-zones: "UTC", "UT", "GMT", "EST", "EDT", "CST", "CDT", "MST", "MDT", "PST", "PDT", per RFC 822 section 5.

  • Read ZonedTimeDefined in time-1.16.0.1 · Data.Time.Format.Parse · orphan

    This only works for a zonedTimeZone in ±HHMM format, single-letter military time-zones, and these time-zones: "UTC", "UT", "GMT", "EST", "EDT", "CST", "CDT", "MST", "MDT", "PST", "PDT", per RFC 822 section 5.

  • Read RTLDFlagsDefined in unix-2.8.8.0 · System.Posix.DynamicLinker.Prim
  • Read CAttributesDefined in unix-2.8.8.0 · System.Posix.Files.Common
  • Read StatxFlagsDefined in unix-2.8.8.0 · System.Posix.Files.Common
  • Read StatxMaskDefined in unix-2.8.8.0 · System.Posix.Files.Common
  • Read OpenFileFlagsDefined in unix-2.8.8.0 · System.Posix.IO.Common
  • Read OpenModeDefined in unix-2.8.8.0 · System.Posix.IO.Common
  • Read GroupEntryDefined in unix-2.8.8.0 · System.Posix.User.Common
  • Read UserEntryDefined in unix-2.8.8.0 · System.Posix.User.Common
  • Read ()Defined in ghc-internal-10.0.0 · GHC.Internal.Read
  • Read a => Read (Complex a)Defined in base-4.23.0.0 · Data.Complex
  • Read a => Read (First a)Defined in base-4.23.0.0 · Data.Semigroup
  • Read a => Read (Last a)Defined in base-4.23.0.0 · Data.Semigroup
  • Read a => Read (Max a)Defined in base-4.23.0.0 · Data.Semigroup
  • Read a => Read (Min a)Defined in base-4.23.0.0 · Data.Semigroup
  • Read a => Read (Seq a)Defined in containers-0.8 · Data.Sequence.Internal
  • Read a => Read (ViewL a)Defined in containers-0.8 · Data.Sequence.Internal
  • Read a => Read (ViewR a)Defined in containers-0.8 · Data.Sequence.Internal
  • Read a => Read (PostOrder a)Defined in containers-0.8 · Data.Tree
  • Read a => Read (Tree a)Defined in containers-0.8 · Data.Tree
  • Read a => Read (FromListCounting a)Defined in ghc-10.0.0.20260917 · GHC.Data.Graph.Inductive.PatriciaTree
  • Read a => Read (NonEmpty a)Defined in ghc-internal-10.0.0 · GHC.Internal.Read
  • Read a => Read (And a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Bits
  • Read a => Read (Iff a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Bits
  • Read a => Read (Ior a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Bits
  • Read a => Read (Xor a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Bits
  • Read a => Read (Identity a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Functor.Identity

    This instance would be equivalent to the derived instances of the Identity newtype if the runIdentity field were removed

  • Read a => Read (First a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Monoid
  • Read a => Read (Last a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Monoid
  • Read a => Read (Down a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Ord

    This instance would be equivalent to the derived instances of the Down newtype if the getDown field were removed

  • Read a => Read (Dual a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Semigroup.Internal
  • Read a => Read (Product a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Semigroup.Internal
  • Read a => Read (Sum a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Semigroup.Internal
  • Read a => Read (ZipList a)Defined in ghc-internal-10.0.0 · GHC.Internal.Functor.ZipList
  • Read a => Read (Maybe a)Defined in ghc-internal-10.0.0 · GHC.Internal.Read
  • Read a => Read (a)Defined in ghc-internal-10.0.0 · GHC.Internal.Read
  • Read a => Read [a]Defined in ghc-internal-10.0.0 · GHC.Internal.Read
  • Read b => Read (GroupEdges b)Defined in ghc-10.0.0.20260917 · GHC.Data.Graph.Inductive.Graph
  • Read e => Read (IntMap e)Defined in containers-0.8 · Data.IntMap.Internal
  • Read e => Read (Word64Map e)Defined in ghc-10.0.0.20260917 · GHC.Data.Word64Map.Internal
  • Read m => Read (WrappedMonoid m)Defined in base-4.23.0.0 · Data.Semigroup
  • Read p => Read (Par1 p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Read vertex => Read (SCC vertex)Defined in containers-0.8 · Data.Graph
  • (Read a, Ord a) => Read (Set a)Defined in containers-0.8 · Data.Set.Internal
  • (Integral a, Read a) => Read (Ratio a)Defined in ghc-internal-10.0.0 · GHC.Internal.Read
  • HasResolution a => Read (Fixed a)Defined in base-4.23.0.0 · Data.Fixed
  • Read (Proxy t)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Proxy
  • Read (U1 p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Read (V1 p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • (Read1 f, Read a) => Read (Lift f a)Defined in transformers-0.6.3.0 · Control.Applicative.Lift
  • (Read1 m, Read a) => Read (MaybeT m a)Defined in transformers-0.6.3.0 · Control.Monad.Trans.Maybe
  • (Ord k, Read k, Read e) => Read (Map k e)Defined in containers-0.8 · Data.Map.Internal
  • (Ix a, Read a, Read b) => Read (Array a b)Defined in ghc-internal-10.0.0 · GHC.Internal.Read
  • (Ix ix, Read ix, Read e, IArray UArray e) => Read (UArray ix e)Defined in array-0.5.8.0 · Data.Array.Base
  • (Read a, Read b) => Read (Arg a b)Defined in base-4.23.0.0 · Data.Semigroup
  • (Read a, Read b) => Read (Gr a b)Defined in ghc-10.0.0.20260917 · GHC.Data.Graph.Inductive.PatriciaTree
  • (Read a, Read b) => Read (Either a b)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Either
  • (Read a, Read b) => Read (a, b)Defined in ghc-internal-10.0.0 · GHC.Internal.Read
  • Read (f a) => Read (Ap f a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Monoid
  • Read (f a) => Read (Alt f a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Semigroup.Internal
  • Read (f p) => Read (Rec1 f p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Read a => Read (Const a b)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Functor.Const

    This instance would be equivalent to the derived instances of the Const newtype if the getConst field were removed

  • Read a => Read (Constant a b)Defined in transformers-0.6.3.0 · Data.Functor.Constant
  • Coercible a b => Read (Coercion a b)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Type.Coercion
  • (Read1 f, Read a) => Read (Backwards f a)Defined in transformers-0.6.3.0 · Control.Applicative.Backwards
  • (Read1 f, Read a) => Read (IdentityT f a)Defined in transformers-0.6.3.0 · Control.Monad.Trans.Identity
  • (Read1 f, Read a) => Read (Reverse f a)Defined in transformers-0.6.3.0 · Data.Functor.Reverse
  • (Read a, Read b, Read c) => Read (a, b, c)Defined in ghc-internal-10.0.0 · GHC.Internal.Read
  • (Read e, Read1 m, Read a) => Read (ExceptT e m a)Defined in transformers-0.6.3.0 · Control.Monad.Trans.Except
  • (Read w, Read1 m, Read a) => Read (WriterT w m a)Defined in transformers-0.6.3.0 · Control.Monad.Trans.Writer.Lazy
  • (Read w, Read1 m, Read a) => Read (WriterT w m a)Defined in transformers-0.6.3.0 · Control.Monad.Trans.Writer.Strict
  • a ~ b => Read (a :~: b)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Type.Equality
  • Read c => Read (K1 i c p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • (Read (f a), Read (g a)) => Read (Product f g a)Defined in base-4.23.0.0 · Data.Functor.Product
  • (Read (f a), Read (g a)) => Read (Sum f g a)Defined in base-4.23.0.0 · Data.Functor.Sum
  • (Read (f p), Read (g p)) => Read ((:*:) f g p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • (Read (f p), Read (g p)) => Read ((:+:) f g p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • (Read a, Read b, Read c, Read d) => Read (a, b, c, d)Defined in ghc-internal-10.0.0 · GHC.Internal.Read
  • a ~~ b => Read (a :~~: b)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Type.Equality
  • Read (f (g a)) => Read (Compose f g a)Defined in base-4.23.0.0 · Data.Functor.Compose
  • Read (f (g p)) => Read ((:.:) f g p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Read (f p) => Read (M1 i c f p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Read (gr a b) => Read (OrdGr gr a b)Defined in ghc-10.0.0.20260917 · GHC.Data.Graph.Inductive.Graph
  • (Read a, Read b, Read c, Read d, Read e) => Read (a, b, c, d, e)Defined in ghc-internal-10.0.0 · GHC.Internal.Read
  • (Read a, Read b, Read c, Read d, Read e, Read f) => Read (a, b, c, d, e, f)Defined in ghc-internal-10.0.0 · GHC.Internal.Read
  • (Read a, Read b, Read c, Read d, Read e, Read f, Read g) => Read (a, b, c, d, e, f, g)Defined in ghc-internal-10.0.0 · GHC.Internal.Read
  • (Read a, Read b, Read c, Read d, Read e, Read f, Read g, Read h) => Read (a, b, c, d, e, f, g, h)Defined in ghc-internal-10.0.0 · GHC.Internal.Read
  • (Read a, Read b, Read c, Read d, Read e, Read f, Read g, Read h, Read i) => Read (a, b, c, d, e, f, g, h, i)Defined in ghc-internal-10.0.0 · GHC.Internal.Read
  • (Read a, Read b, Read c, Read d, Read e, Read f, Read g, Read h, Read i, Read j) => Read (a, b, c, d, e, f, g, h, i, j)Defined in ghc-internal-10.0.0 · GHC.Internal.Read
  • (Read a, Read b, Read c, Read d, Read e, Read f, Read g, Read h, Read i, Read j, Read k) => Read (a, b, c, d, e, f, g, h, i, j, k)Defined in ghc-internal-10.0.0 · GHC.Internal.Read
  • (Read a, Read b, Read c, Read d, Read e, Read f, Read g, Read h, Read i, Read j, Read k, Read l) => Read (a, b, c, d, e, f, g, h, i, j, k, l)Defined in ghc-internal-10.0.0 · GHC.Internal.Read
  • (Read a, Read b, Read c, Read d, Read e, Read f, Read g, Read h, Read i, Read j, Read k, Read l, Read m) => Read (a, b, c, d, e, f, g, h, i, j, k, l, m)Defined in ghc-internal-10.0.0 · GHC.Internal.Read
  • (Read a, Read b, Read c, Read d, Read e, Read f, Read g, Read h, Read i, Read j, Read k, Read l, Read m, Read n) => Read (a, b, c, d, e, f, g, h, i, j, k, l, m, n)Defined in ghc-internal-10.0.0 · GHC.Internal.Read
  • (Read a, Read b, Read c, Read d, Read e, Read f, Read g, Read h, Read i, Read j, Read k, Read l, Read m, Read n, Read o) => Read (a, b, c, d, e, f, g, h, i, j, k, l, m, n, o)Defined in ghc-internal-10.0.0 · GHC.Internal.Read
classclass Num a => Fractional a where
#

Fractional numbers, supporting real division.

The Haskell Report defines no laws for Fractional. However, (+) and (*) are customarily expected to define a division ring and have the following properties:

recip gives the multiplicative inverse

x * recip x

=

recip x * x

=

fromInteger 1

Totality of toRational

toRational

is total

Coherence with toRational

if the type also implements

Real

, then

fromRational

is a left inverse for

toRational

, i.e.

fromRational (toRational i) = i

Note that it isn't customarily expected that a type instance of Fractional implement a field. However, all instances in base do.

Methods

Instances17Fractional, …
  • Fractional EdgeWeightDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.CFG
  • Fractional JStgExprDefined in ghc-10.0.0.20260917 · GHC.JS.Make · orphan
  • Fractional SaneDoubleDefined in ghc-10.0.0.20260917 · GHC.Types.SaneDouble
  • Fractional CDoubleDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Fractional CFloatDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Fractional DoubleDefined in ghc-internal-10.0.0 · GHC.Internal.Float · orphan

    This instance implements IEEE 754 standard with all its usual pitfalls about NaN, infinities and negative zero.

    Example4 expressions
    0 == (-0 :: Double)Truerecip 0 == recip (-0 :: Double)Falsemap (/ 0) [-1, 0, 1][-Infinity,NaN,Infinity]map (* 0) $ map (/ 0) [-1, 0, 1][NaN,NaN,NaN]
  • Fractional FloatDefined in ghc-internal-10.0.0 · GHC.Internal.Float · orphan

    This instance implements IEEE 754 standard with all its usual pitfalls about NaN, infinities and negative zero.

    Example4 expressions
    0 == (-0 :: Float)Truerecip 0 == recip (-0 :: Float)Falsemap (/ 0) [-1, 0, 1 :: Float][-Infinity,NaN,Infinity]map (* 0) $ map (/ 0) [-1, 0, 1 :: Float][NaN,NaN,NaN]
  • Fractional DiffTimeDefined in time-1.16.0.1 · Data.Time.Clock.Internal.DiffTime
  • Fractional NominalDiffTimeDefined in time-1.16.0.1 · Data.Time.Clock.Internal.NominalDiffTime
  • RealFloat a => Fractional (Complex a)Defined in base-4.23.0.0 · Data.Complex
  • Fractional a => Fractional (Identity a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Functor.Identity
  • Fractional a => Fractional (Down a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Ord
  • Integral a => Fractional (Ratio a)Defined in ghc-internal-10.0.0 · GHC.Internal.Real
  • HasResolution a => Fractional (Fixed a)Defined in base-4.23.0.0 · Data.Fixed
  • Fractional a => Fractional (Op a b)Defined in base-4.23.0.0 · Data.Functor.Contravariant
  • Fractional a => Fractional (Const a b)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Functor.Const
  • Fractional (f (g a)) => Fractional (Compose f g a)Defined in base-4.23.0.0 · Data.Functor.Compose
classclass (Real a, Enum a) => Integral a where
#

Integral numbers, supporting integer division.

The Haskell Report defines no laws for Integral. However, Integral instances are customarily expected to define a Euclidean domain and have the following properties for the div/mod and quot/rem pairs, given suitable Euclidean functions f and g:

  • x = y * quot x y + rem x y with rem x y = fromInteger 0 or g (rem x y) < g y

  • x = y * div x y + mod x y with mod x y = fromInteger 0 or f (mod x y) < f y

An example of a suitable Euclidean function, for Integer's instance, is abs.

In addition, toInteger should be total, and fromInteger should be a left inverse for it, i.e. fromInteger (toInteger i) = i.

Methods

  • quot :: a -> a -> ainfixl 7

    Integer division truncated toward zero.

    WARNING: This function is partial (because it throws when 0 is passed as the divisor) for all the integer types in base.

  • rem :: a -> a -> ainfixl 7

    Integer remainder, satisfying

    (x `quot` y)*y + (x `rem` y) == x

    WARNING: This function is partial (because it throws when 0 is passed as the divisor) for all the integer types in base.

  • div :: a -> a -> ainfixl 7

    Integer division truncated toward negative infinity.

    WARNING: This function is partial (because it throws when 0 is passed as the divisor) for all the integer types in base.

  • mod :: a -> a -> ainfixl 7

    Integer modulus, satisfying

    (x `div` y)*y + (x `mod` y) == x

    WARNING: This function is partial (because it throws when 0 is passed as the divisor) for all the integer types in base.

  • quotRem :: a -> a -> (a, a)

    Simultaneous quot and rem.

    WARNING: This function is partial (because it throws when 0 is passed as the divisor) for all the integer types in base.

  • divMod :: a -> a -> (a, a)

    simultaneous div and mod.

    WARNING: This function is partial (because it throws when 0 is passed as the divisor) for all the integer types in base.

  • toInteger :: a -> Integer

    Conversion to Integer.

Instances70Integral, …
  • Integral ByteOffDefined in ghc-10.0.0.20260917 · GHC.ByteCode.Types
  • Integral HalfWordDefined in ghc-10.0.0.20260917 · GHC.ByteCode.Types
  • Integral RegBitmapDefined in ghc-10.0.0.20260917 · GHC.ByteCode.Types
  • Integral WordOffDefined in ghc-10.0.0.20260917 · GHC.ByteCode.Types
  • Integral IntegerDefined in ghc-internal-10.0.0 · GHC.Internal.Real
  • Integral NaturalDefined in ghc-internal-10.0.0 · GHC.Internal.Real
  • Integral CBoolDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Integral CCharDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Integral CIntDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Integral CIntMaxDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Integral CIntPtrDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Integral CLLongDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Integral CLongDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Integral CPtrdiffDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Integral CSCharDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Integral CShortDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Integral CSigAtomicDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Integral CSizeDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Integral CUCharDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Integral CUIntDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Integral CUIntMaxDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Integral CUIntPtrDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Integral CULLongDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Integral CULongDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Integral CUShortDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Integral CWcharDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Integral IntPtrDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.Ptr
  • Integral WordPtrDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.Ptr
  • Integral HalfWordDefined in ghc-internal-10.0.0 · GHC.Internal.Heap.InfoTable.Types
  • Integral Int16Defined in ghc-internal-10.0.0 · GHC.Internal.Int
  • Integral Int32Defined in ghc-internal-10.0.0 · GHC.Internal.Int
  • Integral Int64Defined in ghc-internal-10.0.0 · GHC.Internal.Int
  • Integral Int8Defined in ghc-internal-10.0.0 · GHC.Internal.Int
  • Integral ByteOffsetDefined in ghc-internal-10.0.0 · GHC.Internal.Stack.Constants
  • Integral WordOffsetDefined in ghc-internal-10.0.0 · GHC.Internal.Stack.Constants
  • Integral ByteOffsetDefined in ghc-internal-10.0.0 · GHC.Internal.Stack.ConstantsProf
  • Integral WordOffsetDefined in ghc-internal-10.0.0 · GHC.Internal.Stack.ConstantsProf
  • Integral CBlkCntDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Integral CBlkSizeDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Integral CClockIdDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Integral CDevDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Integral CFsBlkCntDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Integral CFsFilCntDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Integral CGidDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Integral CIdDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Integral CInoDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Integral CKeyDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Integral CModeDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Integral CNfdsDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Integral CNlinkDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Integral COffDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Integral CPidDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Integral CRLimDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Integral CSocklenDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Integral CSsizeDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Integral CTcflagDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Integral CUidDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Integral FdDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Integral IntDefined in ghc-internal-10.0.0 · GHC.Internal.Real
  • Integral WordDefined in ghc-internal-10.0.0 · GHC.Internal.Real
  • Integral Word16Defined in ghc-internal-10.0.0 · GHC.Internal.Word
  • Integral Word32Defined in ghc-internal-10.0.0 · GHC.Internal.Word
  • Integral Word64Defined in ghc-internal-10.0.0 · GHC.Internal.Word
  • Integral Word8Defined in ghc-internal-10.0.0 · GHC.Internal.Word
  • Integral I8Defined in text-2.1.4 · Data.Text.Foreign
  • Integral StatxFlagsDefined in unix-2.8.8.0 · System.Posix.Files.Common
  • Integral StatxMaskDefined in unix-2.8.8.0 · System.Posix.Files.Common
  • Integral a => Integral (Identity a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Functor.Identity
  • Integral a => Integral (Const a b)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Functor.Const
  • Integral (f (g a)) => Integral (Compose f g a)Defined in base-4.23.0.0 · Data.Functor.Compose
typetype Rational = Ratio Integer
#

Arbitrary-precision rational numbers, represented as a ratio of two Integer values. A rational number may be constructed using the % operator.

classclass (Num a, Ord a) => Real a where
#

Real numbers.

The Haskell report defines no laws for Real, however Real instances are customarily expected to adhere to the following law:

Coherence with fromRational

if the type also implements

Fractional

, then

fromRational

is a left inverse for

toRational

, i.e.

fromRational (toRational i) = i

The law does not hold for Float, Double, CFloat, CDouble, etc., because these types contain non-finite values, which cannot be roundtripped through Rational.

Methods

Instances87Real, …
  • Real ByteOffDefined in ghc-10.0.0.20260917 · GHC.ByteCode.Types
  • Real HalfWordDefined in ghc-10.0.0.20260917 · GHC.ByteCode.Types
  • Real RegBitmapDefined in ghc-10.0.0.20260917 · GHC.ByteCode.Types
  • Real WordOffDefined in ghc-10.0.0.20260917 · GHC.ByteCode.Types
  • Real EdgeWeightDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.CFG
  • Real IntegerDefined in ghc-internal-10.0.0 · GHC.Internal.Real
  • Real NaturalDefined in ghc-internal-10.0.0 · GHC.Internal.Real
  • Real CBoolDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Real CCharDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Real CClockDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Real CDoubleDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Real CFloatDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Real CIntDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Real CIntMaxDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Real CIntPtrDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Real CLLongDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Real CLongDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Real CPtrdiffDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Real CSCharDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Real CSUSecondsDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Real CShortDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Real CSigAtomicDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Real CSizeDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Real CTimeDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Real CUCharDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Real CUIntDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Real CUIntMaxDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Real CUIntPtrDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Real CULLongDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Real CULongDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Real CUSecondsDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Real CUShortDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Real CWcharDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Real IntPtrDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.Ptr
  • Real WordPtrDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.Ptr
  • Real HalfWordDefined in ghc-internal-10.0.0 · GHC.Internal.Heap.InfoTable.Types
  • Real Int16Defined in ghc-internal-10.0.0 · GHC.Internal.Int
  • Real Int32Defined in ghc-internal-10.0.0 · GHC.Internal.Int
  • Real Int64Defined in ghc-internal-10.0.0 · GHC.Internal.Int
  • Real Int8Defined in ghc-internal-10.0.0 · GHC.Internal.Int
  • Real ByteOffsetDefined in ghc-internal-10.0.0 · GHC.Internal.Stack.Constants
  • Real WordOffsetDefined in ghc-internal-10.0.0 · GHC.Internal.Stack.Constants
  • Real ByteOffsetDefined in ghc-internal-10.0.0 · GHC.Internal.Stack.ConstantsProf
  • Real WordOffsetDefined in ghc-internal-10.0.0 · GHC.Internal.Stack.ConstantsProf
  • Real CBlkCntDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Real CBlkSizeDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Real CCcDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Real CClockIdDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Real CDevDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Real CFsBlkCntDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Real CFsFilCntDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Real CGidDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Real CIdDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Real CInoDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Real CKeyDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Real CModeDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Real CNfdsDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Real CNlinkDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Real COffDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Real CPidDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Real CRLimDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Real CSocklenDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Real CSpeedDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Real CSsizeDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Real CTcflagDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Real CUidDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Real FdDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Real DoubleDefined in ghc-internal-10.0.0 · GHC.Internal.Float · orphan
  • Real FloatDefined in ghc-internal-10.0.0 · GHC.Internal.Float · orphan
  • Real IntDefined in ghc-internal-10.0.0 · GHC.Internal.Real
  • Real WordDefined in ghc-internal-10.0.0 · GHC.Internal.Real
  • Real Word16Defined in ghc-internal-10.0.0 · GHC.Internal.Word
  • Real Word32Defined in ghc-internal-10.0.0 · GHC.Internal.Word
  • Real Word64Defined in ghc-internal-10.0.0 · GHC.Internal.Word
  • Real Word8Defined in ghc-internal-10.0.0 · GHC.Internal.Word
  • Real I8Defined in text-2.1.4 · Data.Text.Foreign
  • Real DiffTimeDefined in time-1.16.0.1 · Data.Time.Clock.Internal.DiffTime
  • Real NominalDiffTimeDefined in time-1.16.0.1 · Data.Time.Clock.Internal.NominalDiffTime
  • Real StatxFlagsDefined in unix-2.8.8.0 · System.Posix.Files.Common
  • Real StatxMaskDefined in unix-2.8.8.0 · System.Posix.Files.Common
  • Real BaudRateDefined in unix-2.8.8.0 · System.Posix.Terminal.Common
  • Integral a => Real (Ratio a)Defined in ghc-internal-10.0.0 · GHC.Internal.Real
  • Real a => Real (Identity a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Functor.Identity
  • Real a => Real (Down a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Ord
  • HasResolution a => Real (Fixed a)Defined in base-4.23.0.0 · Data.Fixed
  • Real a => Real (Const a b)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Functor.Const
  • Real (f (g a)) => Real (Compose f g a)Defined in base-4.23.0.0 · Data.Functor.Compose
classclass (Real a, Fractional a) => RealFrac a where
#

Extracting components of fractions.

Methods

Instances12RealFrac, …
  • RealFrac CDoubleDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • RealFrac CFloatDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • RealFrac DoubleDefined in ghc-internal-10.0.0 · GHC.Internal.Float · orphan

    Beware that results for non-finite arguments are garbage:

    Example2 expressions
    [ f x | f <- [round, floor, ceiling], x <- [-1/0, 0/0, 1/0] ] :: [Int][0,0,0,0,0,0,0,0,0]map properFraction [-1/0, 0/0, 1/0] :: [(Int, Double)][(0,0.0),(0,0.0),(0,0.0)]

    and get even more non-sensical if you ask for Integer instead of Int.

  • RealFrac FloatDefined in ghc-internal-10.0.0 · GHC.Internal.Float · orphan

    Beware that results for non-finite arguments are garbage:

    Example2 expressions
    [ f x | f <- [round, floor, ceiling], x <- [-1/0, 0/0, 1/0 :: Float] ] :: [Int][0,0,0,0,0,0,0,0,0]map properFraction [-1/0, 0/0, 1/0] :: [(Int, Float)][(0,0.0),(0,0.0),(0,0.0)]

    and get even more non-sensical if you ask for Integer instead of Int.

  • RealFrac DiffTimeDefined in time-1.16.0.1 · Data.Time.Clock.Internal.DiffTime
  • RealFrac NominalDiffTimeDefined in time-1.16.0.1 · Data.Time.Clock.Internal.NominalDiffTime
  • Integral a => RealFrac (Ratio a)Defined in ghc-internal-10.0.0 · GHC.Internal.Real
  • RealFrac a => RealFrac (Identity a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Functor.Identity
  • RealFrac a => RealFrac (Down a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Ord
  • HasResolution a => RealFrac (Fixed a)Defined in base-4.23.0.0 · Data.Fixed
  • RealFrac a => RealFrac (Const a b)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Functor.Const
  • RealFrac (f (g a)) => RealFrac (Compose f g a)Defined in base-4.23.0.0 · Data.Functor.Compose
classclass Show a where
#

Conversion of values to readable Strings.

Derived instances of Show have the following properties, which are compatible with derived instances of Text.Read.Read:

  • The result of show is a syntactically correct Haskell expression containing only constants, given the fixity declarations in force at the point where the type is declared. It contains only the constructor names defined in the data type, parentheses, and spaces. When labelled constructor fields are used, braces, commas, field names, and equal signs are also used.

  • If the constructor is defined to be an infix operator, then showsPrec will produce infix applications of the constructor.

  • the representation will be enclosed in parentheses if the precedence of the top-level constructor in x is less than d (associativity is ignored). Thus, if d is 0 then the result is never surrounded in parentheses; if d is 11 it is always surrounded in parentheses, unless it is an atomic expression.

  • If the constructor is defined using record syntax, then show will produce the record-syntax form, with the fields given in the same order as the original declaration.

For example, given the declarations

infixr 5 :^:
data Tree a =  Leaf a  |  Tree a :^: Tree a

the derived instance of Show is equivalent to

instance (Show a) => Show (Tree a) where

       showsPrec d (Leaf m) = showParen (d > app_prec) $
            showString "Leaf " . showsPrec (app_prec+1) m
         where app_prec = 10

       showsPrec d (u :^: v) = showParen (d > up_prec) $
            showsPrec (up_prec+1) u .
            showString " :^: "      .
            showsPrec (up_prec+1) v
         where up_prec = 5

Note that right-associativity of :^: is ignored. For example,

  • show (Leaf 1 :^: Leaf 2 :^: Leaf 3) produces the string "Leaf 1 :^: (Leaf 2 :^: Leaf 3)".

Methods

  • showsPrec :: Int -> a -> ShowS

    Convert a value to a readable String.

    showsPrec should satisfy the law

    showsPrec d x r ++ s  ==  showsPrec d x (r ++ s)

    Derived instances of Text.Read.Read and Show satisfy the following:

    That is, readsPrec parses the string produced by showsPrec, and delivers the value that showsPrec started with.

  • show :: a -> String

    A specialised variant of showsPrec, using precedence context zero, and returning an ordinary String.

  • showList :: [a] -> ShowS

    The method showList is provided to allow the programmer to give a specialised way of showing lists of values. For example, this is used by the predefined Show instance of the Char type, where values of type String should be shown in double quotes, rather than between square brackets.

Instances805Show, …
  • Show ByteArrayDefined in base-4.23.0.0 · Data.Array.Byte
  • Show CCFlagsDefined in base-4.23.0.0 · GHC.RTS.Flags
  • Show ConcFlagsDefined in base-4.23.0.0 · GHC.RTS.Flags
  • Show DebugFlagsDefined in base-4.23.0.0 · GHC.RTS.Flags
  • Show DoCostCentresDefined in base-4.23.0.0 · GHC.RTS.Flags
  • Show DoHeapProfileDefined in base-4.23.0.0 · GHC.RTS.Flags
  • Show DoTraceDefined in base-4.23.0.0 · GHC.RTS.Flags
  • Show GCFlagsDefined in base-4.23.0.0 · GHC.RTS.Flags
  • Show GiveGCStatsDefined in base-4.23.0.0 · GHC.RTS.Flags
  • Show HpcFlagsDefined in base-4.23.0.0 · GHC.RTS.Flags
  • Show IoManagerFlagDefined in base-4.23.0.0 · GHC.RTS.Flags
  • Show MiscFlagsDefined in base-4.23.0.0 · GHC.RTS.Flags
  • Show ParFlagsDefined in base-4.23.0.0 · GHC.RTS.Flags
  • Show ProfFlagsDefined in base-4.23.0.0 · GHC.RTS.Flags
  • Show RTSFlagsDefined in base-4.23.0.0 · GHC.RTS.Flags
  • Show TickyFlagsDefined in base-4.23.0.0 · GHC.RTS.Flags
  • Show TraceFlagsDefined in base-4.23.0.0 · GHC.RTS.Flags
  • Show GCDetailsDefined in base-4.23.0.0 · GHC.Stats
  • Show RTSStatsDefined in base-4.23.0.0 · GHC.Stats
  • Show TimeoutDefined in base-4.23.0.0 · System.Timeout
  • Show BuilderDefined in bytestring-0.12.2.0 · Data.ByteString.Builder · orphan
  • Show FormatModeDefined in bytestring-0.12.2.0 · Data.ByteString.Builder.RealFloat
  • Show FloatingDecimalDefined in bytestring-0.12.2.0 · Data.ByteString.Builder.RealFloat.D2S
  • Show FloatingDecimalDefined in bytestring-0.12.2.0 · Data.ByteString.Builder.RealFloat.F2S
  • Show ByteStringDefined in bytestring-0.12.2.0 · Data.ByteString.Internal.Type
  • Show SizeOverflowExceptionDefined in bytestring-0.12.2.0 · Data.ByteString.Internal.Type
  • Show ByteStringDefined in bytestring-0.12.2.0 · Data.ByteString.Lazy.Internal
  • Show ShortByteStringDefined in bytestring-0.12.2.0 · Data.ByteString.Short.Internal
  • Show IntSetDefined in containers-0.8 · Data.IntSet.Internal
  • Show IntersectionDefined in containers-0.8 · Data.IntSet.Internal
  • Show BitQueueDefined in containers-0.8 · Utils.Containers.Internal.BitQueue
  • Show BitQueueBDefined in containers-0.8 · Utils.Containers.Internal.BitQueue
  • Show FileTypeDefined in directory-1.3.11.0 · System.Directory.Internal.Common
  • Show PermissionsDefined in directory-1.3.11.0 · System.Directory.Internal.Common
  • Show WhetherFollowDefined in directory-1.3.11.0 · System.Directory.Internal.Common
  • Show XdgDirectoryDefined in directory-1.3.11.0 · System.Directory.Internal.Common
  • Show XdgDirectoryListDefined in directory-1.3.11.0 · System.Directory.Internal.Common
  • Show GhcApiErrorDefined in ghc-10.0.0.20260917 · GHC
  • Show BCOIxDefined in ghc-10.0.0.20260917 · GHC.ByteCode.Linker
  • Show ByteOffDefined in ghc-10.0.0.20260917 · GHC.ByteCode.Types
  • Show FFIInfoDefined in ghc-10.0.0.20260917 · GHC.ByteCode.Types
  • Show HalfWordDefined in ghc-10.0.0.20260917 · GHC.ByteCode.Types
  • Show ItblPtrDefined in ghc-10.0.0.20260917 · GHC.ByteCode.Types
  • Show RegBitmapDefined in ghc-10.0.0.20260917 · GHC.ByteCode.Types
  • Show WordOffDefined in ghc-10.0.0.20260917 · GHC.ByteCode.Types
  • Show SectionTypeDefined in ghc-10.0.0.20260917 · GHC.Cmm
  • Show CLabelDefined in ghc-10.0.0.20260917 · GHC.Cmm.CLabel
  • Show TickyIdInfoDefined in ghc-10.0.0.20260917 · GHC.Cmm.CLabel
  • Show LabelDefined in ghc-10.0.0.20260917 · GHC.Cmm.Dataflow.Label
  • Show LabelSetDefined in ghc-10.0.0.20260917 · GHC.Cmm.Dataflow.Label
  • Show RPNumDefined in ghc-10.0.0.20260917 · GHC.Cmm.Dominators
  • Show AlignmentSpecDefined in ghc-10.0.0.20260917 · GHC.Cmm.Expr
  • Show AreaDefined in ghc-10.0.0.20260917 · GHC.Cmm.Expr
  • Show CmmExprDefined in ghc-10.0.0.20260917 · GHC.Cmm.Expr
  • Show CmmLitDefined in ghc-10.0.0.20260917 · GHC.Cmm.Expr
  • Show CmmTokenDefined in ghc-10.0.0.20260917 · GHC.Cmm.Lexer
  • Show AtomicMachOpDefined in ghc-10.0.0.20260917 · GHC.Cmm.MachOp
  • Show CallishMachOpDefined in ghc-10.0.0.20260917 · GHC.Cmm.MachOp
  • Show FMASignDefined in ghc-10.0.0.20260917 · GHC.Cmm.MachOp
  • Show MachOpDefined in ghc-10.0.0.20260917 · GHC.Cmm.MachOp
  • Show MemoryOrderingDefined in ghc-10.0.0.20260917 · GHC.Cmm.MachOp
  • Show ReducibilityDefined in ghc-10.0.0.20260917 · GHC.Cmm.Reducibility
  • Show CmmRegDefined in ghc-10.0.0.20260917 · GHC.Cmm.Reg
  • Show GlobalArgRegsDefined in ghc-10.0.0.20260917 · GHC.Cmm.Reg
  • Show GlobalRegDefined in ghc-10.0.0.20260917 · GHC.Cmm.Reg
  • Show GlobalRegUseDefined in ghc-10.0.0.20260917 · GHC.Cmm.Reg
  • Show LocalRegDefined in ghc-10.0.0.20260917 · GHC.Cmm.Reg
  • Show SwitchPlanDefined in ghc-10.0.0.20260917 · GHC.Cmm.Switch
  • Show SwitchTargetsDefined in ghc-10.0.0.20260917 · GHC.Cmm.Switch
  • Show CmmCatDefined in ghc-10.0.0.20260917 · GHC.Cmm.Type
  • Show CmmTypeDefined in ghc-10.0.0.20260917 · GHC.Cmm.Type
  • Show WidthDefined in ghc-10.0.0.20260917 · GHC.Cmm.Type
  • Show DMBISHFlagsDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.AArch64.Instr
  • Show ExtModeDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.AArch64.Instr
  • Show OperandDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.AArch64.Instr
  • Show ShiftModeDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.AArch64.Instr
  • Show AddrModeDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.AArch64.Regs
  • Show ImmDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.AArch64.Regs
  • Show FormatDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.Format
  • Show RegWithFormatDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.Format
  • Show ScalarFormatDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.Format
  • Show RegUsageDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.Instr
  • Show CondDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.LA64.Cond
  • Show BarrierTypeDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.LA64.Instr
  • Show OperandDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.LA64.Instr
  • Show AddrModeDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.LA64.Regs
  • Show ImmDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.LA64.Regs
  • Show CondDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.RV64.Cond
  • Show OperandDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.RV64.Instr
  • Show AddrModeDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.RV64.Regs
  • Show ImmDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.RV64.Regs
  • Show RegDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.Reg.Graph.Base
  • Show RegClassDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.Reg.Graph.Base
  • Show RegSubDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.Reg.Graph.Base
  • Show FreeRegsDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.Reg.Linear.AArch64
  • Show RealRegUsageDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.Reg.Linear.Base
  • Show VLocDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.Reg.Linear.Base
  • Show FreeRegsDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.Reg.Linear.LA64
  • Show FreeRegsDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.Reg.Linear.PPC
  • Show FreeRegsDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.Reg.Linear.RV64
  • Show FreeRegsDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.Reg.Linear.X86
  • Show FreeRegsDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.Reg.Linear.X86_64
  • Show BrTableIntervalDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.Wasm.Types
  • Show SymNameDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.Wasm.Types
  • Show PaddingDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.X86.CodeGen
  • Show RawStackArgDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.X86.CodeGen
  • Show StackArgDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.X86.CodeGen
  • Show StackRefDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.X86.CodeGen
  • Show MinMaxTypeDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.X86.Instr
  • Show MinOrMaxDefined in ghc-10.0.0.20260917 · GHC.CmmToAsm.X86.Instr
  • Show FixityDefined in ghc-10.0.0.20260917 · GHC.CmmToC
  • Show SignageDefined in ghc-10.0.0.20260917 · GHC.CmmToLlvm.CodeGen
  • Show IsSubmultDefined in ghc-10.0.0.20260917 · GHC.Core.Multiplicity
  • Show ComparisonDefined in ghc-10.0.0.20260917 · GHC.Core.Opt.Range
  • Show RangeDefined in ghc-10.0.0.20260917 · GHC.Core.Opt.Range
  • Show IsRecDataConResultDefined in ghc-10.0.0.20260917 · GHC.Core.Opt.WorkWrap.Utils
  • Show InvisibleBitDefined in ghc-10.0.0.20260917 · GHC.Core.TyCo.Compare
  • Show PrimElemRepDefined in ghc-10.0.0.20260917 · GHC.Core.TyCon
  • Show PrimOrVoidRepDefined in ghc-10.0.0.20260917 · GHC.Core.TyCon
  • Show PrimRepDefined in ghc-10.0.0.20260917 · GHC.Core.TyCon
  • Show OverridingBoolDefined in ghc-10.0.0.20260917 · GHC.Data.Bool
  • Show FastStringDefined in ghc-10.0.0.20260917 · GHC.Data.FastString
  • Show LexicalFastStringDefined in ghc-10.0.0.20260917 · GHC.Data.FastString
  • Show NonDetFastStringDefined in ghc-10.0.0.20260917 · GHC.Data.FastString
  • Show IOEnvFailureDefined in ghc-10.0.0.20260917 · GHC.Data.IOEnv
  • Show StringBufferDefined in ghc-10.0.0.20260917 · GHC.Data.StringBuffer
  • Show Word64SetDefined in ghc-10.0.0.20260917 · GHC.Data.Word64Set.Internal
  • Show BackendDefined in ghc-10.0.0.20260917 · GHC.Driver.Backend

    The Show instance is for messages only. If code depends on what's in the string, you deserve what happens to you.

  • Show PrimitiveImplementationDefined in ghc-10.0.0.20260917 · GHC.Driver.Backend
  • Show BackendNameDefined in ghc-10.0.0.20260917 · GHC.Driver.Backend.Internal
  • Show CodeGenEnableDefined in ghc-10.0.0.20260917 · GHC.Driver.Downsweep
  • Show DynamicTooStateDefined in ghc-10.0.0.20260917 · GHC.Driver.DynFlags
  • Show ExecutableLinkModeDefined in ghc-10.0.0.20260917 · GHC.Driver.DynFlags
  • Show GhcLinkDefined in ghc-10.0.0.20260917 · GHC.Driver.DynFlags
  • Show PackageArgDefined in ghc-10.0.0.20260917 · GHC.Driver.DynFlags
  • Show RtsOptsEnabledDefined in ghc-10.0.0.20260917 · GHC.Driver.DynFlags
  • Show DumpFlagDefined in ghc-10.0.0.20260917 · GHC.Driver.Flags
  • Show GeneralFlagDefined in ghc-10.0.0.20260917 · GHC.Driver.Flags
  • Show LanguageDefined in ghc-10.0.0.20260917 · GHC.Driver.Flags
  • Show WarningFlagDefined in ghc-10.0.0.20260917 · GHC.Driver.Flags
  • Show IncludeSpecsDefined in ghc-10.0.0.20260917 · GHC.Driver.IncludeSpecs
  • Show ResultLoopOriginDefined in ghc-10.0.0.20260917 · GHC.Driver.Make
  • Show ResultOriginDefined in ghc-10.0.0.20260917 · GHC.Driver.Make
  • Show PhaseDefined in ghc-10.0.0.20260917 · GHC.Driver.Phases
  • Show PipelineOutputDefined in ghc-10.0.0.20260917 · GHC.Driver.Pipeline.Monad
  • Show HsDocStringDefined in ghc-10.0.0.20260917 · GHC.Hs.DocString
  • Show HsDocStringChunkDefined in ghc-10.0.0.20260917 · GHC.Hs.DocString
  • Show HsDocStringDecoratorDefined in ghc-10.0.0.20260917 · GHC.Hs.DocString
  • Show BlankEpAnnotationsDefined in ghc-10.0.0.20260917 · GHC.Hs.Dump
  • Show BlankSrcSpanDefined in ghc-10.0.0.20260917 · GHC.Hs.Dump
  • Show PatGroupDefined in ghc-10.0.0.20260917 · GHC.HsToCore.Match
  • Show GenerateInhabitingPatternsModeDefined in ghc-10.0.0.20260917 · GHC.HsToCore.Pmc.Solver
  • Show PmEqualityDefined in ghc-10.0.0.20260917 · GHC.HsToCore.Pmc.Solver.Types
  • Show PrecisionDefined in ghc-10.0.0.20260917 · GHC.HsToCore.Pmc.Types
  • Show CompressionIFaceDefined in ghc-10.0.0.20260917 · GHC.Iface.Binary
  • Show EntityInfoDefined in ghc-10.0.0.20260917 · GHC.Iface.Ext.Types
  • Show UnfoldingExposureDefined in ghc-10.0.0.20260917 · GHC.Iface.Tidy
  • Show IfLclNameDefined in ghc-10.0.0.20260917 · GHC.Iface.Type
  • Show IdentDefined in ghc-10.0.0.20260917 · GHC.JS.Ident
  • Show AOpDefined in ghc-10.0.0.20260917 · GHC.JS.JStg.Syntax
  • Show OpDefined in ghc-10.0.0.20260917 · GHC.JS.JStg.Syntax
  • Show UOpDefined in ghc-10.0.0.20260917 · GHC.JS.JStg.Syntax
  • Show MultiplicityDefined in ghc-10.0.0.20260917 · GHC.JS.Opt.Simple
  • Show VarDeclDefined in ghc-10.0.0.20260917 · GHC.JS.Opt.Simple
  • Show AOpDefined in ghc-10.0.0.20260917 · GHC.JS.Syntax
  • Show OpDefined in ghc-10.0.0.20260917 · GHC.JS.Syntax
  • Show UOpDefined in ghc-10.0.0.20260917 · GHC.JS.Syntax
  • Show LinkInfoDefined in ghc-10.0.0.20260917 · GHC.Linker.Executable
  • Show UnitLinkOptsDefined in ghc-10.0.0.20260917 · GHC.Linker.Unit
  • Show LlvmAtomicOpDefined in ghc-10.0.0.20260917 · GHC.Llvm.Syntax
  • Show LlvmSyncOrderingDefined in ghc-10.0.0.20260917 · GHC.Llvm.Syntax
  • Show LlvmCallTypeDefined in ghc-10.0.0.20260917 · GHC.Llvm.Types
  • Show LlvmParameterListTypeDefined in ghc-10.0.0.20260917 · GHC.Llvm.Types
  • Show BindTagDefined in ghc-10.0.0.20260917 · GHC.Parser.Annotation
  • Show DeclTagDefined in ghc-10.0.0.20260917 · GHC.Parser.Annotation
  • Show EpaCommentDefined in ghc-10.0.0.20260917 · GHC.Parser.Annotation
  • Show EpaCommentTokDefined in ghc-10.0.0.20260917 · GHC.Parser.Annotation
  • Show HasEDefined in ghc-10.0.0.20260917 · GHC.Parser.Annotation
  • Show IsUnicodeSyntaxDefined in ghc-10.0.0.20260917 · GHC.Parser.Annotation
  • Show LexErrDefined in ghc-10.0.0.20260917 · GHC.Parser.Errors.Types
  • Show LexErrKindDefined in ghc-10.0.0.20260917 · GHC.Parser.Errors.Types
  • Show NumUnderscoreReasonDefined in ghc-10.0.0.20260917 · GHC.Parser.Errors.Types
  • Show HdkCommentDefined in ghc-10.0.0.20260917 · GHC.Parser.Lexer
  • Show LayoutContextDefined in ghc-10.0.0.20260917 · GHC.Parser.Lexer
  • Show OpWsDefined in ghc-10.0.0.20260917 · GHC.Parser.Lexer
  • Show TokenDefined in ghc-10.0.0.20260917 · GHC.Parser.Lexer
  • Show AlexInputDefined in ghc-10.0.0.20260917 · GHC.Parser.Lexer.Interface
  • Show ColumnBoundDefined in ghc-10.0.0.20260917 · GHC.Parser.PostProcess.Haddock
  • Show LowerLocBoundDefined in ghc-10.0.0.20260917 · GHC.Parser.PostProcess.Haddock
  • Show UpperLocBoundDefined in ghc-10.0.0.20260917 · GHC.Parser.PostProcess.Haddock
  • Show StringLexErrorDefined in ghc-10.0.0.20260917 · GHC.Parser.String
  • Show StringMetaDefined in ghc-10.0.0.20260917 · GHC.Parser.String
  • Show PlatformDefined in ghc-10.0.0.20260917 · GHC.Platform
  • Show PlatformWordSizeDefined in ghc-10.0.0.20260917 · GHC.Platform
  • Show PlatformConstantsDefined in ghc-10.0.0.20260917 · GHC.Platform.Constants
  • Show ProfileDefined in ghc-10.0.0.20260917 · GHC.Platform.Profile
  • Show RealRegDefined in ghc-10.0.0.20260917 · GHC.Platform.Reg
  • Show RegDefined in ghc-10.0.0.20260917 · GHC.Platform.Reg
  • Show VirtualRegDefined in ghc-10.0.0.20260917 · GHC.Platform.Reg
  • Show RegArchDefined in ghc-10.0.0.20260917 · GHC.Platform.Reg.Class
  • Show RegClassDefined in ghc-10.0.0.20260917 · GHC.Platform.Reg.Class
  • Show WayDefined in ghc-10.0.0.20260917 · GHC.Platform.Ways
  • Show StgLiftConfigDefined in ghc-10.0.0.20260917 · GHC.Stg.Lift.Config
  • Show StgToDoDefined in ghc-10.0.0.20260917 · GHC.Stg.Pipeline
  • Show UpdateFlagDefined in ghc-10.0.0.20260917 · GHC.Stg.Syntax
  • Show ApplyConvDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Apply
  • Show ApplySpecDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Apply
  • Show ObjectKindDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Object
  • Show SpecialDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Regs
  • Show StgRetDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Regs
  • Show CILayoutDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Show CIRegsDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Show CIStaticDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Show CITypeDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Show ClosureInfoDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Show ClosureTypeDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Show ExpFunDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Show ForeignJSRefDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Show JSFFITypeDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Show JSRepDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Show StaticAppKindDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Show StaticArgDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Show StaticInfoDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Show StaticLitDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Show StaticUnboxedDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Show StaticValDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Show ThreadStatusDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Types
  • Show SlotCountDefined in ghc-10.0.0.20260917 · GHC.StgToJS.Utils
  • Show ArchiveDefined in ghc-10.0.0.20260917 · GHC.SysTools.Ar
  • Show ArchiveEntryDefined in ghc-10.0.0.20260917 · GHC.SysTools.Ar
  • Show HasKindsDefined in ghc-10.0.0.20260917 · GHC.Tc.Errors.Types
  • Show SuggestPartialTypeSignaturesDefined in ghc-10.0.0.20260917 · GHC.Tc.Errors.Types
  • Show SuggestUndecidableInstancesDefined in ghc-10.0.0.20260917 · GHC.Tc.Errors.Types
  • Show WhatLookingDefined in ghc-10.0.0.20260917 · GHC.Tc.Errors.Types
  • Show SimpleUnifyResultDefined in ghc-10.0.0.20260917 · GHC.Tc.Utils.Unify
  • Show ImportLevelDefined in ghc-10.0.0.20260917 · GHC.Types.Basic
  • Show LevityDefined in ghc-10.0.0.20260917 · GHC.Types.Basic
  • Show PprPrecDefined in ghc-10.0.0.20260917 · GHC.Types.Basic
  • Show CardDefined in ghc-10.0.0.20260917 · GHC.Types.Demand
  • Show DiagnosticCodeDefined in ghc-10.0.0.20260917 · GHC.Types.Error
  • Show DiagnosticReasonDefined in ghc-10.0.0.20260917 · GHC.Types.Error
  • Show SeverityDefined in ghc-10.0.0.20260917 · GHC.Types.Error
  • Show DuplicateRecordFieldsDefined in ghc-10.0.0.20260917 · GHC.Types.FieldLabel
  • Show FieldSelectorsDefined in ghc-10.0.0.20260917 · GHC.Types.FieldLabel
  • Show SemaphoreUpgradeTargetDefined in ghc-10.0.0.20260917 · GHC.Types.Hint
  • Show LitFloatingDefined in ghc-10.0.0.20260917 · GHC.Types.Literal.Floating
  • Show LitFloatingTypeDefined in ghc-10.0.0.20260917 · GHC.Types.Literal.Floating
  • Show FieldsOrSelectorsDefined in ghc-10.0.0.20260917 · GHC.Types.Name.Reader
  • Show ProfAutoDefined in ghc-10.0.0.20260917 · GHC.Types.ProfAuto
  • Show SafeHaskellModeDefined in ghc-10.0.0.20260917 · GHC.Types.SafeHaskell
  • Show SaneDoubleDefined in ghc-10.0.0.20260917 · GHC.Types.SaneDouble
  • Show SourceErrorDefined in ghc-10.0.0.20260917 · GHC.Types.SourceError
  • Show HsBootOrSigDefined in ghc-10.0.0.20260917 · GHC.Types.SourceFile
  • Show HscSourceDefined in ghc-10.0.0.20260917 · GHC.Types.SourceFile
  • Show FractionalExponentBaseDefined in ghc-10.0.0.20260917 · GHC.Types.SourceText
  • Show FractionalLitDefined in ghc-10.0.0.20260917 · GHC.Types.SourceText
  • Show IntegralLitDefined in ghc-10.0.0.20260917 · GHC.Types.SourceText
  • Show SourceTextDefined in ghc-10.0.0.20260917 · GHC.Types.SourceText
  • Show BufPosDefined in ghc-10.0.0.20260917 · GHC.Types.SrcLoc
  • Show BufSpanDefined in ghc-10.0.0.20260917 · GHC.Types.SrcLoc
  • Show DeltaPosDefined in ghc-10.0.0.20260917 · GHC.Types.SrcLoc
  • Show GeneratedSrcSpanDetailsDefined in ghc-10.0.0.20260917 · GHC.Types.SrcLoc
  • Show NoCommentsDefined in ghc-10.0.0.20260917 · GHC.Types.SrcLoc
  • Show PsLocDefined in ghc-10.0.0.20260917 · GHC.Types.SrcLoc
  • Show PsSpanDefined in ghc-10.0.0.20260917 · GHC.Types.SrcLoc
  • Show RealSrcLocDefined in ghc-10.0.0.20260917 · GHC.Types.SrcLoc
  • Show RealSrcSpanDefined in ghc-10.0.0.20260917 · GHC.Types.SrcLoc
  • Show SrcLocDefined in ghc-10.0.0.20260917 · GHC.Types.SrcLoc
  • Show SrcSpanDefined in ghc-10.0.0.20260917 · GHC.Types.SrcLoc
  • Show UnhelpfulSpanReasonDefined in ghc-10.0.0.20260917 · GHC.Types.SrcLoc
  • Show TickishPlacementDefined in ghc-10.0.0.20260917 · GHC.Types.Tickish
  • Show UniqueDefined in ghc-10.0.0.20260917 · GHC.Types.Unique
  • Show UniqueTagDefined in ghc-10.0.0.20260917 · GHC.Types.Unique
  • Show UniqueSetDefined in ghc-10.0.0.20260917 · GHC.Types.Unique.Set
  • Show ModLocationDefined in ghc-10.0.0.20260917 · GHC.Unit.Module.Location
  • Show UnitDefined in ghc-10.0.0.20260917 · GHC.Unit.Types
  • Show PrintTimingsDefined in ghc-10.0.0.20260917 · GHC.Utils.Error
  • Show DumpFormatDefined in ghc-10.0.0.20260917 · GHC.Utils.Logger
  • Show GhcExceptionDefined in ghc-10.0.0.20260917 · GHC.Utils.Panic
  • Show PlainGhcExceptionDefined in ghc-10.0.0.20260917 · GHC.Utils.Panic.Plain
  • Show DocDefined in ghc-10.0.0.20260917 · GHC.Utils.Ppr
  • Show TempFileLifetimeDefined in ghc-10.0.0.20260917 · GHC.Utils.TmpFs
  • Show InlineSpecDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Binds.InlinePragma
  • Show RuleMatchInfoDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Binds.InlinePragma
  • Show SpliceDecorationDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Decls
  • Show WarningCategoryDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Decls
  • Show CCallConvDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Decls.Foreign
  • Show ForeignKindDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Decls.Foreign
  • Show SafetyDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Decls.Foreign
  • Show IsBootInterfaceDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.ImpExp.IsBoot
  • Show ModuleNameDefined in ghc-10.0.0.20260917 · Language.Haskell.Syntax.Module.Name
  • Show ShortTextDefined in ghc-boot-10.0.0.20260917 · GHC.Data.ShortText
  • Show DbInstUnitIdDefined in ghc-boot-10.0.0.20260917 · GHC.Unit.Database
  • Show DbModuleDefined in ghc-boot-10.0.0.20260917 · GHC.Unit.Database
  • Show ForallVisFlagDefined in ghc-boot-th-10.0.0.20260917 · GHC.Boot.TH.Ppr
  • Show DocDefined in ghc-boot-th-10.0.0.20260917 · GHC.Boot.TH.PprLib
  • Show VoidDefined in ghc-internal-10.0.0 · GHC.Internal.Show
  • Show IntegerDefined in ghc-internal-10.0.0 · GHC.Internal.Show
  • Show NaturalDefined in ghc-internal-10.0.0 · GHC.Internal.Show
  • Show ByteOrderDefined in ghc-internal-10.0.0 · GHC.Internal.ByteOrder
  • Show ClosureTypeDefined in ghc-internal-10.0.0 · GHC.Internal.ClosureTypes
  • Show BlockReasonDefined in ghc-internal-10.0.0 · GHC.Internal.Conc.Sync
  • Show ThreadIdDefined in ghc-internal-10.0.0 · GHC.Internal.Conc.Sync
  • Show ThreadStatusDefined in ghc-internal-10.0.0 · GHC.Internal.Conc.Sync
  • Show NestedAtomicallyDefined in ghc-internal-10.0.0 · GHC.Internal.Control.Exception.Base
  • Show NoMatchingContinuationPromptDefined in ghc-internal-10.0.0 · GHC.Internal.Control.Exception.Base
  • Show NoMethodErrorDefined in ghc-internal-10.0.0 · GHC.Internal.Control.Exception.Base
  • Show NonTerminationDefined in ghc-internal-10.0.0 · GHC.Internal.Control.Exception.Base
  • Show PatternMatchFailDefined in ghc-internal-10.0.0 · GHC.Internal.Control.Exception.Base
  • Show RecConErrorDefined in ghc-internal-10.0.0 · GHC.Internal.Control.Exception.Base
  • Show RecSelErrorDefined in ghc-internal-10.0.0 · GHC.Internal.Control.Exception.Base
  • Show RecUpdErrorDefined in ghc-internal-10.0.0 · GHC.Internal.Control.Exception.Base
  • Show TypeErrorDefined in ghc-internal-10.0.0 · GHC.Internal.Control.Exception.Base
  • Show ConstrDefined in ghc-internal-10.0.0 · GHC.Internal.Data.Data
  • Show ConstrRepDefined in ghc-internal-10.0.0 · GHC.Internal.Data.Data
  • Show DataRepDefined in ghc-internal-10.0.0 · GHC.Internal.Data.Data
  • Show DataTypeDefined in ghc-internal-10.0.0 · GHC.Internal.Data.Data
  • Show FixityDefined in ghc-internal-10.0.0 · GHC.Internal.Data.Data
  • Show DynamicDefined in ghc-internal-10.0.0 · GHC.Internal.Data.Dynamic
  • Show AllDefined in ghc-internal-10.0.0 · GHC.Internal.Data.Semigroup.Internal
  • Show AnyDefined in ghc-internal-10.0.0 · GHC.Internal.Data.Semigroup.Internal
  • Show SomeTypeRepDefined in ghc-internal-10.0.0 · GHC.Internal.Data.Typeable.Internal
  • Show VersionDefined in ghc-internal-10.0.0 · GHC.Internal.Data.Version
  • Show ControlMessageDefined in ghc-internal-10.0.0 · GHC.Internal.Event.Control
  • Show EPollFdDefined in ghc-internal-10.0.0 · GHC.Internal.Event.EPoll
  • Show EventDefined in ghc-internal-10.0.0 · GHC.Internal.Event.EPoll
  • Show EventTypeDefined in ghc-internal-10.0.0 · GHC.Internal.Event.EPoll
  • Show EventDefined in ghc-internal-10.0.0 · GHC.Internal.Event.Internal.Types
  • Show EventLifetimeDefined in ghc-internal-10.0.0 · GHC.Internal.Event.Internal.Types
  • Show LifetimeDefined in ghc-internal-10.0.0 · GHC.Internal.Event.Internal.Types
  • Show TimeoutDefined in ghc-internal-10.0.0 · GHC.Internal.Event.Internal.Types
  • Show FdKeyDefined in ghc-internal-10.0.0 · GHC.Internal.Event.Manager
  • Show StateDefined in ghc-internal-10.0.0 · GHC.Internal.Event.Manager
  • Show EventDefined in ghc-internal-10.0.0 · GHC.Internal.Event.Poll
  • Show PollFdDefined in ghc-internal-10.0.0 · GHC.Internal.Event.Poll
  • Show StateDefined in ghc-internal-10.0.0 · GHC.Internal.Event.TimerManager
  • Show UniqueDefined in ghc-internal-10.0.0 · GHC.Internal.Event.Unique
  • Show ErrorCallDefined in ghc-internal-10.0.0 · GHC.Internal.Exception
  • Show ArithExceptionDefined in ghc-internal-10.0.0 · GHC.Internal.Exception.Type
  • Show SomeExceptionDefined in ghc-internal-10.0.0 · GHC.Internal.Exception.Type
  • Show WhileHandlingDefined in ghc-internal-10.0.0 · GHC.Internal.Exception.Type
  • Show FingerprintDefined in ghc-internal-10.0.0 · GHC.Internal.Fingerprint.Type
  • Show CBoolDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Show CCharDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Show CClockDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Show CDoubleDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Show CFloatDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Show CIntDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Show CIntMaxDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Show CIntPtrDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Show CLLongDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Show CLongDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Show CPtrdiffDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Show CSCharDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Show CSUSecondsDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Show CShortDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Show CSigAtomicDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Show CSizeDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Show CTimeDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Show CUCharDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Show CUIntDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Show CUIntMaxDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Show CUIntPtrDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Show CULLongDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Show CULongDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Show CUSecondsDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Show CUShortDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Show CWcharDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Show IntPtrDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.Ptr
  • Show WordPtrDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.Ptr
  • Show ForeignSrcLangDefined in ghc-internal-10.0.0 · GHC.Internal.ForeignSrcLang
  • Show AssociativityDefined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Show DecidedStrictnessDefined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Show FixityDefined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Show SourceStrictnessDefined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Show SourceUnpackednessDefined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Show BoxDefined in ghc-internal-10.0.0 · GHC.Internal.Heap.Closures
  • Show PrimTypeDefined in ghc-internal-10.0.0 · GHC.Internal.Heap.Closures
  • Show TsoFlagsDefined in ghc-internal-10.0.0 · GHC.Internal.Heap.Closures
  • Show WhatNextDefined in ghc-internal-10.0.0 · GHC.Internal.Heap.Closures
  • Show WhyBlockedDefined in ghc-internal-10.0.0 · GHC.Internal.Heap.Closures
  • Show HalfWordDefined in ghc-internal-10.0.0 · GHC.Internal.Heap.InfoTable.Types
  • Show StgInfoTableDefined in ghc-internal-10.0.0 · GHC.Internal.Heap.InfoTable.Types
  • Show CostCentreDefined in ghc-internal-10.0.0 · GHC.Internal.Heap.ProfInfo.Types
  • Show CostCentreStackDefined in ghc-internal-10.0.0 · GHC.Internal.Heap.ProfInfo.Types
  • Show IndexTableDefined in ghc-internal-10.0.0 · GHC.Internal.Heap.ProfInfo.Types
  • Show StgTSOProfInfoDefined in ghc-internal-10.0.0 · GHC.Internal.Heap.ProfInfo.Types
  • Show MaskingStateDefined in ghc-internal-10.0.0 · GHC.Internal.IO
  • Show SeekModeDefined in ghc-internal-10.0.0 · GHC.Internal.IO.Device
  • Show CodingFailureModeDefined in ghc-internal-10.0.0 · GHC.Internal.IO.Encoding.Failure
  • Show CodingProgressDefined in ghc-internal-10.0.0 · GHC.Internal.IO.Encoding.Types
  • Show TextEncodingDefined in ghc-internal-10.0.0 · GHC.Internal.IO.Encoding.Types
  • Show AllocationLimitExceededDefined in ghc-internal-10.0.0 · GHC.Internal.IO.Exception
  • Show ArrayExceptionDefined in ghc-internal-10.0.0 · GHC.Internal.IO.Exception
  • Show AssertionFailedDefined in ghc-internal-10.0.0 · GHC.Internal.IO.Exception
  • Show AsyncExceptionDefined in ghc-internal-10.0.0 · GHC.Internal.IO.Exception
  • Show BlockedIndefinitelyOnMVarDefined in ghc-internal-10.0.0 · GHC.Internal.IO.Exception
  • Show BlockedIndefinitelyOnSTMDefined in ghc-internal-10.0.0 · GHC.Internal.IO.Exception
  • Show CompactionFailedDefined in ghc-internal-10.0.0 · GHC.Internal.IO.Exception
  • Show DeadlockDefined in ghc-internal-10.0.0 · GHC.Internal.IO.Exception
  • Show ExitCodeDefined in ghc-internal-10.0.0 · GHC.Internal.IO.Exception
  • Show FixIOExceptionDefined in ghc-internal-10.0.0 · GHC.Internal.IO.Exception
  • Show IOErrorTypeDefined in ghc-internal-10.0.0 · GHC.Internal.IO.Exception
  • Show IOExceptionDefined in ghc-internal-10.0.0 · GHC.Internal.IO.Exception
  • Show SomeAsyncExceptionDefined in ghc-internal-10.0.0 · GHC.Internal.IO.Exception
  • Show FDDefined in ghc-internal-10.0.0 · GHC.Internal.IO.FD
  • Show HandlePosnDefined in ghc-internal-10.0.0 · GHC.Internal.IO.Handle
  • Show FileLockingNotSupportedDefined in ghc-internal-10.0.0 · GHC.Internal.IO.Handle.Lock.Common
  • Show BufferModeDefined in ghc-internal-10.0.0 · GHC.Internal.IO.Handle.Types
  • Show HandleDefined in ghc-internal-10.0.0 · GHC.Internal.IO.Handle.Types
  • Show HandleTypeDefined in ghc-internal-10.0.0 · GHC.Internal.IO.Handle.Types
  • Show NewlineDefined in ghc-internal-10.0.0 · GHC.Internal.IO.Handle.Types
  • Show NewlineModeDefined in ghc-internal-10.0.0 · GHC.Internal.IO.Handle.Types
  • Show IOModeDefined in ghc-internal-10.0.0 · GHC.Internal.IO.IOMode
  • Show IoSubSystemDefined in ghc-internal-10.0.0 · GHC.Internal.IO.SubSystem
  • Show InfoProvDefined in ghc-internal-10.0.0 · GHC.Internal.InfoProv.Types
  • Show Int16Defined in ghc-internal-10.0.0 · GHC.Internal.Int
  • Show Int32Defined in ghc-internal-10.0.0 · GHC.Internal.Int
  • Show Int64Defined in ghc-internal-10.0.0 · GHC.Internal.Int
  • Show Int8Defined in ghc-internal-10.0.0 · GHC.Internal.Int
  • Show ExtensionDefined in ghc-internal-10.0.0 · GHC.Internal.LanguageExtensions
  • Show CCFlagsDefined in ghc-internal-10.0.0 · GHC.Internal.RTS.Flags
  • Show ConcFlagsDefined in ghc-internal-10.0.0 · GHC.Internal.RTS.Flags
  • Show DebugFlagsDefined in ghc-internal-10.0.0 · GHC.Internal.RTS.Flags
  • Show DoCostCentresDefined in ghc-internal-10.0.0 · GHC.Internal.RTS.Flags
  • Show DoHeapProfileDefined in ghc-internal-10.0.0 · GHC.Internal.RTS.Flags
  • Show DoTraceDefined in ghc-internal-10.0.0 · GHC.Internal.RTS.Flags
  • Show GCFlagsDefined in ghc-internal-10.0.0 · GHC.Internal.RTS.Flags
  • Show GiveGCStatsDefined in ghc-internal-10.0.0 · GHC.Internal.RTS.Flags
  • Show HpcFlagsDefined in ghc-internal-10.0.0 · GHC.Internal.RTS.Flags
  • Show IoManagerFlagDefined in ghc-internal-10.0.0 · GHC.Internal.RTS.Flags
  • Show MiscFlagsDefined in ghc-internal-10.0.0 · GHC.Internal.RTS.Flags
  • Show ParFlagsDefined in ghc-internal-10.0.0 · GHC.Internal.RTS.Flags
  • Show ProfFlagsDefined in ghc-internal-10.0.0 · GHC.Internal.RTS.Flags
  • Show RTSFlagsDefined in ghc-internal-10.0.0 · GHC.Internal.RTS.Flags
  • Show TickyFlagsDefined in ghc-internal-10.0.0 · GHC.Internal.RTS.Flags
  • Show TraceFlagsDefined in ghc-internal-10.0.0 · GHC.Internal.RTS.Flags
  • Show FractionalExponentBaseDefined in ghc-internal-10.0.0 · GHC.Internal.Real
  • Show ByteOffsetDefined in ghc-internal-10.0.0 · GHC.Internal.Stack.Constants
  • Show WordOffsetDefined in ghc-internal-10.0.0 · GHC.Internal.Stack.Constants
  • Show ByteOffsetDefined in ghc-internal-10.0.0 · GHC.Internal.Stack.ConstantsProf
  • Show WordOffsetDefined in ghc-internal-10.0.0 · GHC.Internal.Stack.ConstantsProf
  • Show PointernessDefined in ghc-internal-10.0.0 · GHC.Internal.Stack.Decode
  • Show StackEntryDefined in ghc-internal-10.0.0 · GHC.Internal.Stack.Decode
  • Show CallStackDefined in ghc-internal-10.0.0 · GHC.Internal.Show
  • Show SrcLocDefined in ghc-internal-10.0.0 · GHC.Internal.Show
  • Show StaticPtrInfoDefined in ghc-internal-10.0.0 · GHC.Internal.StaticPtr
  • Show GCDetailsDefined in ghc-internal-10.0.0 · GHC.Internal.Stats
  • Show RTSStatsDefined in ghc-internal-10.0.0 · GHC.Internal.Stats
  • Show CBlkCntDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Show CBlkSizeDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Show CCcDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Show CClockIdDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Show CDevDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Show CFsBlkCntDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Show CFsFilCntDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Show CGidDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Show CIdDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Show CInoDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Show CKeyDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Show CModeDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Show CNfdsDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Show CNlinkDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Show COffDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Show CPidDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Show CRLimDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Show CSocklenDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Show CSpeedDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Show CSsizeDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Show CTcflagDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Show CTimerDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Show CUidDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Show FdDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Show AnnLookupDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Show AnnTargetDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Show BangDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Show BndrVisDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Show BodyDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Show BytesDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Show CallconvDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Show ClauseDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Show ConDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Show DecDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Show DecidedStrictnessDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Show DerivClauseDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Show DerivStrategyDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Show DocLocDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Show ExpDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Show FamilyResultSigDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Show FixityDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Show FixityDirectionDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Show ForeignDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Show FunDepDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Show GuardDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Show InfoDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Show InjectivityAnnDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Show InlineDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Show LitDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Show LocDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Show MatchDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Show ModNameDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Show ModuleDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Show ModuleInfoDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Show NameDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Show NameFlavourDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Show NameSpaceDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Show NamespaceSpecifierDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Show OccNameDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Show OverlapDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Show PatDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Show PatSynArgsDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Show PatSynDirDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Show PhasesDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Show PkgNameDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Show PragmaDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Show RangeDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Show RoleDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Show RuleBndrDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Show RuleMatchDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Show SafetyDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Show SourceStrictnessDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Show SourceUnpackednessDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Show SpecificityDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Show StmtDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Show TyLitDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Show TySynEqnDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Show TypeDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Show TypeFamilyHeadDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Show LexemeDefined in ghc-internal-10.0.0 · GHC.Internal.Text.Read.Lex
  • Show NumberDefined in ghc-internal-10.0.0 · GHC.Internal.Text.Read.Lex
  • Show SomeCharDefined in ghc-internal-10.0.0 · GHC.Internal.TypeLits
  • Show SomeSymbolDefined in ghc-internal-10.0.0 · GHC.Internal.TypeLits
  • Show SomeNatDefined in ghc-internal-10.0.0 · GHC.Internal.TypeNats
  • Show BoolDefined in ghc-internal-10.0.0 · GHC.Internal.Show
  • Show CharDefined in ghc-internal-10.0.0 · GHC.Internal.Show
  • Show DoubleDefined in ghc-internal-10.0.0 · GHC.Internal.Float · orphan
  • Show FloatDefined in ghc-internal-10.0.0 · GHC.Internal.Float · orphan
  • Show IntDefined in ghc-internal-10.0.0 · GHC.Internal.Show
  • Show KindRepDefined in ghc-internal-10.0.0 · GHC.Internal.Show
  • Show LevityDefined in ghc-internal-10.0.0 · GHC.Internal.Show
  • Show ModuleDefined in ghc-internal-10.0.0 · GHC.Internal.Show
  • Show OrderingDefined in ghc-internal-10.0.0 · GHC.Internal.Show
  • Show RuntimeRepDefined in ghc-internal-10.0.0 · GHC.Internal.Show
  • Show TrNameDefined in ghc-internal-10.0.0 · GHC.Internal.Show
  • Show TyConDefined in ghc-internal-10.0.0 · GHC.Internal.Show
  • Show TypeLitSortDefined in ghc-internal-10.0.0 · GHC.Internal.Show
  • Show VecCountDefined in ghc-internal-10.0.0 · GHC.Internal.Show
  • Show VecElemDefined in ghc-internal-10.0.0 · GHC.Internal.Show
  • Show WordDefined in ghc-internal-10.0.0 · GHC.Internal.Show
  • Show GeneralCategoryDefined in ghc-internal-10.0.0 · GHC.Internal.Unicode
  • Show Word16Defined in ghc-internal-10.0.0 · GHC.Internal.Word
  • Show Word32Defined in ghc-internal-10.0.0 · GHC.Internal.Word
  • Show Word64Defined in ghc-internal-10.0.0 · GHC.Internal.Word
  • Show Word8Defined in ghc-internal-10.0.0 · GHC.Internal.Word
  • Show ArchDefined in ghc-platform-0.1.0.0 · GHC.Platform.ArchOS
  • Show ArchOSDefined in ghc-platform-0.1.0.0 · GHC.Platform.ArchOS
  • Show ArmABIDefined in ghc-platform-0.1.0.0 · GHC.Platform.ArchOS
  • Show ArmISADefined in ghc-platform-0.1.0.0 · GHC.Platform.ArchOS
  • Show ArmISAExtDefined in ghc-platform-0.1.0.0 · GHC.Platform.ArchOS
  • Show OSDefined in ghc-platform-0.1.0.0 · GHC.Platform.ArchOS
  • Show PPC_64ABIDefined in ghc-platform-0.1.0.0 · GHC.Platform.ArchOS
  • Show LibraryDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Library
  • Show ErrorDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Monad
  • Show ProgramDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Program
  • Show TargetDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Target

    Handwritten Show instance to have have better diffs against the toolchain targets generated by configure

  • Show WordSizeDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Target
  • Show ArDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Tools.Ar
  • Show CcDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Tools.Cc
  • Show CmmCppDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Tools.Cpp
  • Show CppDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Tools.Cpp
  • Show HsCppDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Tools.Cpp
  • Show JsCppDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Tools.Cpp
  • Show CxxDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Tools.Cxx
  • Show CcLinkDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Tools.Link
  • Show MergeObjsDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Tools.MergeObjs
  • Show NmDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Tools.Nm
  • Show RanlibDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Tools.Ranlib
  • Show ReadelfDefined in ghc-toolchain-0.1.0.0 · GHC.Toolchain.Tools.Readelf
  • Show FFITypeDefined in ghci-10.0.0.20260917 · GHCi.FFI
  • Show ConInfoTableDefined in ghci-10.0.0.20260917 · GHCi.Message
  • Show EvalBreakpointDefined in ghci-10.0.0.20260917 · GHCi.Message
  • Show EvalOptsDefined in ghci-10.0.0.20260917 · GHCi.Message
  • Show QStateDefined in ghci-10.0.0.20260917 · GHCi.Message
  • Show SerializableExceptionDefined in ghci-10.0.0.20260917 · GHCi.Message
  • Show THResultTypeDefined in ghci-10.0.0.20260917 · GHCi.Message
  • Show HValueDefined in ghci-10.0.0.20260917 · GHCi.RemoteTypes
  • Show ResolvedBCODefined in ghci-10.0.0.20260917 · GHCi.ResolvedBCO
  • Show ResolvedBCOPtrDefined in ghci-10.0.0.20260917 · GHCi.ResolvedBCO
  • Show GHCiQExceptionDefined in ghci-10.0.0.20260917 · GHCi.TH
  • Show BoxLabelDefined in hpc-0.7.0.2 · Trace.Hpc.Mix
  • Show CondBoxDefined in hpc-0.7.0.2 · Trace.Hpc.Mix
  • Show MixDefined in hpc-0.7.0.2 · Trace.Hpc.Mix
  • Show TixDefined in hpc-0.7.0.2 · Trace.Hpc.Tix
  • Show TixModuleDefined in hpc-0.7.0.2 · Trace.Hpc.Tix
  • Show HashDefined in hpc-0.7.0.2 · Trace.Hpc.Util
  • Show HpcPosDefined in hpc-0.7.0.2 · Trace.Hpc.Util
  • Show EncodingExceptionDefined in os-string-2.0.11 · System.OsString.Encoding.Internal
  • Show OsCharDefined in os-string-2.0.11 · System.OsString.Internal.Types
  • Show OsStringDefined in os-string-2.0.11 · System.OsString.Internal.Types

    On windows, decodes as UCS-2. On unix prints the raw bytes without decoding.

  • Show PosixCharDefined in os-string-2.0.11 · System.OsString.Internal.Types
  • Show PosixStringDefined in os-string-2.0.11 · System.OsString.Internal.Types

    Prints the raw bytes without decoding.

  • Show WindowsCharDefined in os-string-2.0.11 · System.OsString.Internal.Types
  • Show WindowsStringDefined in os-string-2.0.11 · System.OsString.Internal.Types

    Decodes as UCS-2.

  • Show ModeDefined in pretty-1.1.3.6 · Text.PrettyPrint.Annotated.HughesPJ
  • Show StyleDefined in pretty-1.1.3.6 · Text.PrettyPrint.Annotated.HughesPJ
  • Show TextDetailsDefined in pretty-1.1.3.6 · Text.PrettyPrint.Annotated.HughesPJ
  • Show PrettyLevelDefined in pretty-1.1.3.6 · Text.PrettyPrint.Annotated.HughesPJClass
  • Show DocDefined in pretty-1.1.3.6 · Text.PrettyPrint.HughesPJ
  • Show PrettyLevelDefined in pretty-1.1.3.6 · Text.PrettyPrint.HughesPJClass
  • Show CmdSpecDefined in process-1.6.30.0 · System.Process.Common
  • Show CreateProcessDefined in process-1.6.30.0 · System.Process.Common
  • Show StdStreamDefined in process-1.6.30.0 · System.Process.Common
  • Show CommunicationHandleDefined in process-1.6.30.0 · System.Process.CommunicationHandle.Internal
  • Show SemaphoreErrorDefined in semaphore-compat-2.0.1 · System.Semaphore.Internal.Version
  • Show SemaphoreNameDefined in semaphore-compat-2.0.1 · System.Semaphore.Internal.Version
  • Show SemaphoreProtocolVersionDefined in semaphore-compat-2.0.1 · System.Semaphore.Internal.Version
  • Show DecodingDefined in text-2.1.4 · Data.Text.Encoding
  • Show UnicodeExceptionDefined in text-2.1.4 · Data.Text.Encoding.Error
  • Show I8Defined in text-2.1.4 · Data.Text.Foreign
  • Show TextDefined in text-2.1.4 · Data.Text.Show · orphan
  • Show BuilderDefined in text-2.1.4 · Data.Text.Internal.Builder
  • Show PartialUtf8CodePointDefined in text-2.1.4 · Data.Text.Internal.Encoding
  • Show Utf8StateDefined in text-2.1.4 · Data.Text.Internal.Encoding
  • Show DecoderStateDefined in text-2.1.4 · Data.Text.Internal.Encoding.Utf8
  • Show SizeDefined in text-2.1.4 · Data.Text.Internal.Fusion.Size
  • Show TextDefined in text-2.1.4 · Data.Text.Lazy · orphan
  • Show FPFormatDefined in text-2.1.4 · Data.Text.Lazy.Builder.RealFloat
  • Show IterDefined in text-2.1.4 · Data.Text.Unsafe
  • Show CalendarDiffDaysDefined in time-1.16.0.1 · Data.Time.Format.ISO8601 · orphan
  • Show DayDefined in time-1.16.0.1 · Data.Time.Calendar.Gregorian · orphan
  • Show MonthDefined in time-1.16.0.1 · Data.Time.Calendar.Month

    Show as yyyy-mm.

  • Show QuarterDefined in time-1.16.0.1 · Data.Time.Calendar.Quarter

    Show as yyyy-Qn.

  • Show QuarterOfYearDefined in time-1.16.0.1 · Data.Time.Calendar.Quarter
  • Show DayOfWeekDefined in time-1.16.0.1 · Data.Time.Calendar.Week
  • Show AbsoluteTimeDefined in time-1.16.0.1 · Data.Time.Clock.TAI · orphan
  • Show DiffTimeDefined in time-1.16.0.1 · Data.Time.Clock.Internal.DiffTime
  • Show NominalDiffTimeDefined in time-1.16.0.1 · Data.Time.Clock.Internal.NominalDiffTime
  • Show SystemTimeDefined in time-1.16.0.1 · Data.Time.Clock.Internal.SystemTime
  • Show UTCTimeDefined in time-1.16.0.1 · Data.Time.LocalTime.Internal.ZonedTime · orphan
  • Show UniversalTimeDefined in time-1.16.0.1 · Data.Time.LocalTime.Internal.LocalTime · orphan
  • Show TimeLocaleDefined in time-1.16.0.1 · Data.Time.Format.Locale
  • Show CalendarDiffTimeDefined in time-1.16.0.1 · Data.Time.Format.ISO8601 · orphan
  • Show LocalTimeDefined in time-1.16.0.1 · Data.Time.LocalTime.Internal.LocalTime
  • Show TimeOfDayDefined in time-1.16.0.1 · Data.Time.LocalTime.Internal.TimeOfDay
  • Show TimeZoneDefined in time-1.16.0.1 · Data.Time.LocalTime.Internal.TimeZone

    This only shows the time zone name, or offset if the name is empty.

  • Show ZonedTimeDefined in time-1.16.0.1 · Data.Time.LocalTime.Internal.ZonedTime

    For the time zone, this only shows the name, or offset if the name is empty.

  • Show DirTypeDefined in unix-2.8.8.0 · System.Posix.Directory.Common
  • Show DLDefined in unix-2.8.8.0 · System.Posix.DynamicLinker.Prim
  • Show RTLDFlagsDefined in unix-2.8.8.0 · System.Posix.DynamicLinker.Prim
  • Show CAttributesDefined in unix-2.8.8.0 · System.Posix.Files.Common
  • Show StatxFlagsDefined in unix-2.8.8.0 · System.Posix.Files.Common
  • Show StatxMaskDefined in unix-2.8.8.0 · System.Posix.Files.Common
  • Show OpenFileFlagsDefined in unix-2.8.8.0 · System.Posix.IO.Common
  • Show OpenModeDefined in unix-2.8.8.0 · System.Posix.IO.Common
  • Show ProcessStatusDefined in unix-2.8.8.0 · System.Posix.Process.Internals
  • Show ResourceDefined in unix-2.8.8.0 · System.Posix.Resource
  • Show ResourceLimitDefined in unix-2.8.8.0 · System.Posix.Resource
  • Show ResourceLimitsDefined in unix-2.8.8.0 · System.Posix.Resource
  • Show BaudRateDefined in unix-2.8.8.0 · System.Posix.Terminal.Common
  • Show GroupEntryDefined in unix-2.8.8.0 · System.Posix.User.Common
  • Show UserEntryDefined in unix-2.8.8.0 · System.Posix.User.Common
  • Show ()Defined in ghc-internal-10.0.0 · GHC.Internal.Show
  • Show (WasmTypeTag t)Defined in ghc-10.0.0.20260917 · GHC.CmmToAsm.Wasm.Types
  • Show (Position p)Defined in ghc-10.0.0.20260917 · GHC.Tc.Types.Origin
  • Show (MsgEnvelope DiagnosticMessage)Defined in ghc-10.0.0.20260917 · GHC.Types.Error
  • Show (ConstPtr a)Defined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.ConstPtr
  • Show (ForeignPtr a)Defined in ghc-internal-10.0.0 · GHC.Internal.ForeignPtr
  • Show (FunPtr a)Defined in ghc-internal-10.0.0 · GHC.Internal.Ptr
  • Show (Ptr a)Defined in ghc-internal-10.0.0 · GHC.Internal.Ptr
  • Show (SChar c)Defined in ghc-internal-10.0.0 · GHC.Internal.TypeLits
  • Show (SSymbol s)Defined in ghc-internal-10.0.0 · GHC.Internal.TypeLits
  • Show (SNat n)Defined in ghc-internal-10.0.0 · GHC.Internal.TypeNats
  • Show (Message a)Defined in ghci-10.0.0.20260917 · GHCi.Message
  • Show (THMessage a)Defined in ghci-10.0.0.20260917 · GHCi.Message
  • Show (RemotePtr a)Defined in ghci-10.0.0.20260917 · GHCi.RemoteTypes
  • Show (RemoteRef a)Defined in ghci-10.0.0.20260917 · GHCi.RemoteTypes
  • Show (BCOByteArray Word)Defined in ghci-10.0.0.20260917 · GHCi.ResolvedBCO
  • Show (BCOByteArray Word16)Defined in ghci-10.0.0.20260917 · GHCi.ResolvedBCO
  • Show (Doc a)Defined in pretty-1.1.3.6 · Text.PrettyPrint.Annotated.HughesPJ
  • Show a => Show (Complex a)Defined in base-4.23.0.0 · Data.Complex
  • Show a => Show (First a)Defined in base-4.23.0.0 · Data.Semigroup
  • Show a => Show (Last a)Defined in base-4.23.0.0 · Data.Semigroup
  • Show a => Show (Max a)Defined in base-4.23.0.0 · Data.Semigroup
  • Show a => Show (Min a)Defined in base-4.23.0.0 · Data.Semigroup
  • Show a => Show (Decoder a)Defined in binary-0.8.9.3 · Data.Binary.Get.Internal
  • Show a => Show (IntMap a)Defined in containers-0.8 · Data.IntMap.Internal
  • Show a => Show (Seq a)Defined in containers-0.8 · Data.Sequence.Internal
  • Show a => Show (ViewL a)Defined in containers-0.8 · Data.Sequence.Internal
  • Show a => Show (ViewR a)Defined in containers-0.8 · Data.Sequence.Internal
  • Show a => Show (Intersection a)Defined in containers-0.8 · Data.Set.Internal
  • Show a => Show (Set a)Defined in containers-0.8 · Data.Set.Internal
  • Show a => Show (PostOrder a)Defined in containers-0.8 · Data.Tree
  • Show a => Show (Tree a)Defined in containers-0.8 · Data.Tree
  • Show a => Show (ExitCase a)Defined in exceptions-0.10.12 · Control.Monad.Catch
  • Show a => Show (LPath a)Defined in ghc-10.0.0.20260917 · GHC.Data.Graph.Inductive.Graph
  • Show a => Show (FromListCounting a)Defined in ghc-10.0.0.20260917 · GHC.Data.Graph.Inductive.PatriciaTree
  • Show a => Show (Maybe a)Defined in ghc-10.0.0.20260917 · GHC.Data.Strict
  • Show a => Show (Word64Map a)Defined in ghc-10.0.0.20260917 · GHC.Data.Word64Map.Internal
  • Show a => Show (OnOff a)Defined in ghc-10.0.0.20260917 · GHC.Driver.Flags
  • Show a => Show (NonVoid a)Defined in ghc-10.0.0.20260917 · GHC.StgToCmm.Closure
  • Show a => Show (EpaLocation' a)Defined in ghc-10.0.0.20260917 · GHC.Types.SrcLoc
  • Show a => Show (FixedLengthEncoding a)Defined in ghc-10.0.0.20260917 · GHC.Utils.Binary
  • Show a => Show (SmallArray a)Defined in ghc-boot-10.0.0.20260917 · GHC.Data.SmallArray
  • Show a => Show (NonEmpty a)Defined in ghc-internal-10.0.0 · GHC.Internal.Show
  • Show a => Show (And a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Bits
  • Show a => Show (Iff a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Bits
  • Show a => Show (Ior a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Bits
  • Show a => Show (Xor a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Bits
  • Show a => Show (Identity a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Functor.Identity

    This instance would be equivalent to the derived instances of the Identity newtype if the runIdentity field were removed

  • Show a => Show (First a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Monoid
  • Show a => Show (Last a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Monoid
  • Show a => Show (Down a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Ord

    This instance would be equivalent to the derived instances of the Down newtype if the getDown field were removed

  • Show a => Show (Dual a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Semigroup.Internal
  • Show a => Show (Product a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Semigroup.Internal
  • Show a => Show (Sum a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Semigroup.Internal
  • Show a => Show (ExceptionWithContext a)Defined in ghc-internal-10.0.0 · GHC.Internal.Exception.Type
  • Show a => Show (ZipList a)Defined in ghc-internal-10.0.0 · GHC.Internal.Functor.ZipList
  • Show a => Show (Maybe a)Defined in ghc-internal-10.0.0 · GHC.Internal.Show
  • Show a => Show (Ratio a)Defined in ghc-internal-10.0.0 · GHC.Internal.Real
  • Show a => Show (EvalExpr a)Defined in ghci-10.0.0.20260917 · GHCi.Message
  • Show a => Show (EvalResult a)Defined in ghci-10.0.0.20260917 · GHCi.Message
  • Show a => Show (QResult a)Defined in ghci-10.0.0.20260917 · GHCi.Message
  • Show a => Show (THResult a)Defined in ghci-10.0.0.20260917 · GHCi.Message
  • Show a => Show (AnnotDetails a)Defined in pretty-1.1.3.6 · Text.PrettyPrint.Annotated.HughesPJ
  • Show a => Show (Span a)Defined in pretty-1.1.3.6 · Text.PrettyPrint.Annotated.HughesPJ
  • Show a => Show (a)Defined in ghc-internal-10.0.0 · GHC.Internal.Show
  • Show a => Show [a]Defined in ghc-internal-10.0.0 · GHC.Internal.Show
  • Show b => Show (GroupEdges b)Defined in ghc-10.0.0.20260917 · GHC.Data.Graph.Inductive.Graph
  • Show b => Show (GenClosure b)Defined in ghc-internal-10.0.0 · GHC.Internal.Heap.Closures
  • Show b => Show (GenStackField b)Defined in ghc-internal-10.0.0 · GHC.Internal.Heap.Closures
  • Show b => Show (GenStackFrame b)Defined in ghc-internal-10.0.0 · GHC.Internal.Heap.Closures
  • Show b => Show (GenStgStackClosure b)Defined in ghc-internal-10.0.0 · GHC.Internal.Heap.Closures
  • Show e => Show (NoBacktrace e)Defined in ghc-internal-10.0.0 · GHC.Internal.Exception.Type
  • Show flag => Show (TyVarBndr flag)Defined in ghc-internal-10.0.0 · GHC.Internal.TH.Syntax
  • Show m => Show (WrappedMonoid m)Defined in base-4.23.0.0 · Data.Semigroup
  • Show mod => Show (GenWithIsBoot mod)Defined in ghc-10.0.0.20260917 · GHC.Unit.Types
  • Show p => Show (Par1 p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Show v => Show (LabelMap v)Defined in ghc-10.0.0.20260917 · GHC.Cmm.Dataflow.Label
  • Show vertex => Show (SCC vertex)Defined in containers-0.8 · Data.Graph
  • HasResolution a => Show (Fixed a)Defined in base-4.23.0.0 · Data.Fixed
  • Show (Bin a)Defined in ghc-10.0.0.20260917 · GHC.Utils.Binary
  • Show (RelBin a)Defined in ghc-10.0.0.20260917 · GHC.Utils.Binary
  • Show (RelBinPtr a)Defined in ghc-10.0.0.20260917 · GHC.Utils.Binary
  • Show (Proxy s)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Proxy
  • Show (TypeRep a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Typeable.Internal
  • Show (U1 p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Show (UAddr p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Show (V1 p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Show (ST s a)Defined in ghc-internal-10.0.0 · GHC.Internal.ST
  • Show (a -> b)Defined in base-4.23.0.0 · Text.Show.Functions · orphan
  • Show a => Show (EvalStatus_ a b)Defined in ghci-10.0.0.20260917 · GHCi.Message
  • (Show1 f, Show a) => Show (Lift f a)Defined in transformers-0.6.3.0 · Control.Applicative.Lift
  • (Show1 m, Show a) => Show (MaybeT m a)Defined in transformers-0.6.3.0 · Control.Monad.Trans.Maybe
  • (Ix a, Show a, Show b) => Show (Array a b)Defined in ghc-internal-10.0.0 · GHC.Internal.Arr
  • (Ix ix, Show ix, Show e, IArray UArray e) => Show (UArray ix e)Defined in array-0.5.8.0 · Data.Array.Base
  • (Show a, Show b) => Show (Arg a b)Defined in base-4.23.0.0 · Data.Semigroup
  • (Show a, Show b) => Show (Gr a b)Defined in ghc-10.0.0.20260917 · GHC.Data.Graph.Inductive.PatriciaTree
  • (Show a, Show b) => Show (Pair a b)Defined in ghc-10.0.0.20260917 · GHC.Data.Strict
  • (Show a, Show b) => Show (Either a b)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Either
  • (Show a, Show b) => Show (a, b)Defined in ghc-internal-10.0.0 · GHC.Internal.Show
  • (Show k, Show a) => Show (Map k a)Defined in containers-0.8 · Data.Map.Internal
  • (Show l, Show e) => Show (GenLocated l e)Defined in ghc-10.0.0.20260917 · GHC.Types.SrcLoc
  • Show (Coercion a b)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Type.Coercion
  • Show (OrderingI a b)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Type.Ord
  • Show (URec Char p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Show (URec Double p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Show (URec Float p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Show (URec Int p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Show (URec Word p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Show (a :~: b)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Type.Equality
  • Show (f a) => Show (Ap f a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Monoid
  • Show (f a) => Show (Alt f a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Semigroup.Internal
  • Show (f p) => Show (Rec1 f p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Show a => Show (Const a b)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Functor.Const

    This instance would be equivalent to the derived instances of the Const newtype if the getConst field were removed

  • Show a => Show (Constant a b)Defined in transformers-0.6.3.0 · Data.Functor.Constant
  • (Show1 f, Show a) => Show (Backwards f a)Defined in transformers-0.6.3.0 · Control.Applicative.Backwards
  • (Show1 f, Show a) => Show (IdentityT f a)Defined in transformers-0.6.3.0 · Control.Monad.Trans.Identity
  • (Show1 f, Show a) => Show (Reverse f a)Defined in transformers-0.6.3.0 · Data.Functor.Reverse
  • (Show a, Show b, Show c) => Show (a, b, c)Defined in ghc-internal-10.0.0 · GHC.Internal.Show
  • (Show e, Show1 m, Show a) => Show (ExceptT e m a)Defined in transformers-0.6.3.0 · Control.Monad.Trans.Except
  • (Show w, Show1 m, Show a) => Show (WriterT w m a)Defined in transformers-0.6.3.0 · Control.Monad.Trans.Writer.Lazy
  • (Show w, Show1 m, Show a) => Show (WriterT w m a)Defined in transformers-0.6.3.0 · Control.Monad.Trans.Writer.Strict
  • Show (a :~~: b)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Type.Equality
  • Show c => Show (K1 i c p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • (Show (f a), Show (g a)) => Show (Product f g a)Defined in base-4.23.0.0 · Data.Functor.Product
  • (Show (f a), Show (g a)) => Show (Sum f g a)Defined in base-4.23.0.0 · Data.Functor.Sum
  • (Show (f p), Show (g p)) => Show ((:*:) f g p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • (Show (f p), Show (g p)) => Show ((:+:) f g p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • (Show a, Show b, Show c, Show d) => Show (a, b, c, d)Defined in ghc-internal-10.0.0 · GHC.Internal.Show
  • Show (f (g a)) => Show (Compose f g a)Defined in base-4.23.0.0 · Data.Functor.Compose
  • Show (f (g p)) => Show ((:.:) f g p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Show (f p) => Show (M1 i c f p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Show (gr a b) => Show (OrdGr gr a b)Defined in ghc-10.0.0.20260917 · GHC.Data.Graph.Inductive.Graph
  • (Show a, Show b, Show c, Show d, Show e) => Show (a, b, c, d, e)Defined in ghc-internal-10.0.0 · GHC.Internal.Show
  • (Show uid, Show modulename, Show mod, Show srcpkgid, Show srcpkgname) => Show (GenericUnitInfo srcpkgid srcpkgname uid modulename mod)Defined in ghc-boot-10.0.0.20260917 · GHC.Unit.Database
  • (Show a, Show b, Show c, Show d, Show e, Show f) => Show (a, b, c, d, e, f)Defined in ghc-internal-10.0.0 · GHC.Internal.Show
  • (Show a, Show b, Show c, Show d, Show e, Show f, Show g) => Show (a, b, c, d, e, f, g)Defined in ghc-internal-10.0.0 · GHC.Internal.Show
  • (Show a, Show b, Show c, Show d, Show e, Show f, Show g, Show h) => Show (a, b, c, d, e, f, g, h)Defined in ghc-internal-10.0.0 · GHC.Internal.Show
  • (Show a, Show b, Show c, Show d, Show e, Show f, Show g, Show h, Show i) => Show (a, b, c, d, e, f, g, h, i)Defined in ghc-internal-10.0.0 · GHC.Internal.Show
  • (Show a, Show b, Show c, Show d, Show e, Show f, Show g, Show h, Show i, Show j) => Show (a, b, c, d, e, f, g, h, i, j)Defined in ghc-internal-10.0.0 · GHC.Internal.Show
  • (Show a, Show b, Show c, Show d, Show e, Show f, Show g, Show h, Show i, Show j, Show k) => Show (a, b, c, d, e, f, g, h, i, j, k)Defined in ghc-internal-10.0.0 · GHC.Internal.Show
  • (Show a, Show b, Show c, Show d, Show e, Show f, Show g, Show h, Show i, Show j, Show k, Show l) => Show (a, b, c, d, e, f, g, h, i, j, k, l)Defined in ghc-internal-10.0.0 · GHC.Internal.Show
  • (Show a, Show b, Show c, Show d, Show e, Show f, Show g, Show h, Show i, Show j, Show k, Show l, Show m) => Show (a, b, c, d, e, f, g, h, i, j, k, l, m)Defined in ghc-internal-10.0.0 · GHC.Internal.Show
  • (Show a, Show b, Show c, Show d, Show e, Show f, Show g, Show h, Show i, Show j, Show k, Show l, Show m, Show n) => Show (a, b, c, d, e, f, g, h, i, j, k, l, m, n)Defined in ghc-internal-10.0.0 · GHC.Internal.Show
  • (Show a, Show b, Show c, Show d, Show e, Show f, Show g, Show h, Show i, Show j, Show k, Show l, Show m, Show n, Show o) => Show (a, b, c, d, e, f, g, h, i, j, k, l, m, n, o)Defined in ghc-internal-10.0.0 · GHC.Internal.Show
typetype ShowS = String -> String
#

The shows functions return a function that prepends the output String to an existing String. This allows constant-time concatenation of results using function composition.

typetype ReadS a = String -> [(a, String)]
#

A parser for a type a, represented as a function that takes a String and returns a list of possible parses as (a,String) pairs.

Note that this kind of backtracking parser is very inefficient; reading a large structure may be quite slow (cf ReadP).

newtypenewtype IO a
#

A value of type IO a is a computation which, when performed, does some I/O before returning a value of type a.

There is really only one way to "perform" an I/O action: bind it to Main.main in your program. When your program is run, the I/O will be performed. It isn't possible to perform I/O from an arbitrary function, unless that function is itself in the IO monad and called at some point, directly or indirectly, from Main.main.

IO is a monad, so IO actions can be combined using either the do-notation or the Prelude.>> and Prelude.>>= operations from the Prelude.Monad class.

Instances39Monad, Functor, MonadFix, MonadFail, Applicative, GHCiSandboxIO, …
datadata Ordering
#
Instances17Bounded, Enum, Eq, Data, Ord, Read, …
typetype String = [Char]
#

String is an alias for a list of characters.

String constants in Haskell are values of type String. That means if you write a string literal like "hello world", it will have the type [Char], which is the same as String.

Note: You can ask the compiler to automatically infer different types with the -XOverloadedStrings language extension, for example "hello world" :: Text. See IsString for more information.

Because String is just a list of characters, you can use normal list functions to do basic string manipulation. See Data.List for operations on lists.

Performance considerations

[Char] is a relatively memory-inefficient type. It is a linked list of boxed word-size characters, internally it looks something like:

╭─────┬───┬──╮  ╭─────┬───┬──╮  ╭─────┬───┬──╮  ╭────╮
│ (:) │   │ ─┼─>│ (:) │   │ ─┼─>│ (:) │   │ ─┼─>│ [] │
╰─────┴─┼─┴──╯  ╰─────┴─┼─┴──╯  ╰─────┴─┼─┴──╯  ╰────╯
        v               v               v
       'a'             'b'             'c'

The String "abc" will use 5*3+1 = 16 (in general 5n+1) words of space in memory.

Furthermore, operations like (++) (string concatenation) are O(n) (in the left argument).

For historical reasons, the base library uses String in a lot of places for the conceptual simplicity, but library code dealing with user-data should use the text package for Unicode text, or the the bytestring package for binary data.

Instances2ToJson, ToJExpr
datadata Integer
#

Arbitrary precision integers. In contrast with fixed-size integral types such as Int, the Integer type represents the entire infinite range of integers.

Integers are stored in a kind of sign-magnitude form, hence do not expect two's complement form when using bit operations.

If the value is small (i.e., fits into an Int), the IS constructor is used. Otherwise IP and IN constructors are used to store a BigNat representing the positive or the negative value magnitude, respectively.

Invariant: IP and IN are used iff the value does not fit in IS.

Instances23Enum, Eq, Integral, Data, Num, Ord, …
  • Enum IntegerDefined in ghc-internal-10.0.0 · GHC.Internal.Enum
  • Eq IntegerDefined in ghc-internal-10.0.0 · GHC.Internal.Bignum.Integer
  • Integral IntegerDefined in ghc-internal-10.0.0 · GHC.Internal.Real
  • Data IntegerDefined in ghc-internal-10.0.0 · GHC.Internal.Data.Data
  • Num IntegerDefined in ghc-internal-10.0.0 · GHC.Internal.Num
  • Ord IntegerDefined in ghc-internal-10.0.0 · GHC.Internal.Bignum.Integer
  • Read IntegerDefined in ghc-internal-10.0.0 · GHC.Internal.Read
  • Real IntegerDefined in ghc-internal-10.0.0 · GHC.Internal.Real
  • Show IntegerDefined in ghc-internal-10.0.0 · GHC.Internal.Show
  • Ix IntegerDefined in ghc-internal-10.0.0 · GHC.Internal.Ix
  • Bits IntegerDefined in ghc-internal-10.0.0 · GHC.Internal.Bits
  • PrintfArg IntegerDefined in base-4.23.0.0 · Text.Printf
  • NFData IntegerDefined in deepseq-1.5.2.0 · Control.DeepSeq
  • Pretty IntegerDefined in pretty-1.1.3.6 · Text.PrettyPrint.Annotated.HughesPJClass
  • Pretty IntegerDefined in pretty-1.1.3.6 · Text.PrettyPrint.HughesPJClass
  • Binary IntegerDefined in binary-0.8.9.3 · Data.Binary.Class
  • DayPeriod YearDefined in time-1.16.0.1 · Data.Time.Calendar.Gregorian · orphan
  • ShowPadded IntegerDefined in time-1.16.0.1 · Data.Time.Calendar.Private
  • HpcHash IntegerDefined in hpc-0.7.0.2 · Trace.Hpc.Util
  • Outputable IntegerDefined in ghc-10.0.0.20260917 · GHC.Utils.Outputable
  • Binary IntegerDefined in ghc-10.0.0.20260917 · GHC.Utils.Binary
  • ToJExpr IntegerDefined in ghc-10.0.0.20260917 · GHC.JS.Make
  • Lift IntegerDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Lift
datadata Maybe a
#

The Maybe type encapsulates an optional value. A value of type Maybe a either contains a value of type a (represented as Just a), or it is empty (represented as Nothing). Using Maybe is a good way to deal with errors or exceptional cases without resorting to drastic measures such as error.

The Maybe type is also a monad. It is a simple kind of error monad, where all errors are represented by Nothing. A richer error monad can be built using the Either type.

Constructors

Instances50Monad, Functor, MonadFix, MonadFail, Applicative, Foldable, …
datadata Bool
#
Instances32Bounded, Enum, Eq, Data, Ord, Read, …
  • Bounded BoolDefined in ghc-internal-10.0.0 · GHC.Internal.Enum
  • Enum BoolDefined in ghc-internal-10.0.0 · GHC.Internal.Enum
  • Eq BoolDefined in ghc-internal-10.0.0 · GHC.Internal.Classes
  • Data BoolDefined in ghc-internal-10.0.0 · GHC.Internal.Data.Data
  • Ord BoolDefined in ghc-internal-10.0.0 · GHC.Internal.Classes
  • Read BoolDefined in ghc-internal-10.0.0 · GHC.Internal.Read
  • Show BoolDefined in ghc-internal-10.0.0 · GHC.Internal.Show
  • Ix BoolDefined in ghc-internal-10.0.0 · GHC.Internal.Ix
  • Generic BoolDefined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Bits BoolDefined in ghc-internal-10.0.0 · GHC.Internal.Bits

    Interpret Bool as 1-bit bit-field

  • FiniteBits BoolDefined in ghc-internal-10.0.0 · GHC.Internal.Bits
  • Storable BoolDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.Storable
  • SingKind BoolDefined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • NFData BoolDefined in deepseq-1.5.2.0 · Control.DeepSeq
  • Pretty BoolDefined in pretty-1.1.3.6 · Text.PrettyPrint.Annotated.HughesPJClass
  • Pretty BoolDefined in pretty-1.1.3.6 · Text.PrettyPrint.HughesPJClass
  • Binary BoolDefined in binary-0.8.9.3 · Data.Binary.Class
  • HpcHash BoolDefined in hpc-0.7.0.2 · Trace.Hpc.Util
  • NoAnn BoolDefined in ghc-10.0.0.20260917 · GHC.Parser.Annotation
  • Outputable BoolDefined in ghc-10.0.0.20260917 · GHC.Utils.Outputable
  • Binary BoolDefined in ghc-10.0.0.20260917 · GHC.Utils.Binary
  • ToJExpr BoolDefined in ghc-10.0.0.20260917 · GHC.JS.Make
  • Lift BoolDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Lift
  • SingI 'FalseDefined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • SingI 'TrueDefined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • IArray UArray BoolDefined in array-0.5.8.0 · Data.Array.Base
  • MArray IOUArray Bool IODefined in array-0.5.8.0 · Data.Array.IO.Internals
  • MArray (STUArray s) Bool (ST s)Defined in array-0.5.8.0 · Data.Array.Base
  • type Rep Bool = D1 ('MetaData "Bool" "GHC.Internal.Types" "ghc-internal" 'False) (C1 ('MetaCons "False" 'PrefixI 'False) U1 :+: C1 ('MetaCons "True" 'PrefixI 'False) U1)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • type DemoteRep Bool = BoolDefined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • data Sing
    • STrue :: R:SingBoola 'True
    • SFalse :: R:SingBoola 'False
    Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • type Anno Bool = EpAnnCODefined in ghc-10.0.0.20260917 · GHC.Hs.Decls · orphan
datadata Char
#

The character type Char represents Unicode codespace and its elements are code points as in definitions D9 and D10 of the Unicode Standard.

Character literals in Haskell are single-quoted: 'Q', 'Я' or 'Ω'. To represent a single quote itself use '\'', and to represent a backslash use '\\'. The full grammar can be found in the section 2.6 of the Haskell 2010 Language Report.

To specify a character by its code point one can use decimal, hexadecimal or octal notation: '\65', '\x41' and '\o101' are all alternative forms of 'A'. The largest code point is '\x10ffff'.

There is a special escape syntax for ASCII control characters:

Escape

Alternatives

Meaning

'\NUL'

'\0'

null character

'\SOH'

'\1'

start of heading

'\STX'

'\2'

start of text

'\ETX'

'\3'

end of text

'\EOT'

'\4'

end of transmission

'\ENQ'

'\5'

enquiry

'\ACK'

'\6'

acknowledge

'\BEL'

'\7'

,

'\a'

bell (alert)

'\BS'

'\8'

,

'\b'

backspace

'\HT'

'\9'

,

'\t'

horizontal tab

'\LF'

'\10'

,

'\n'

line feed (new line)

'\VT'

'\11'

,

'\v'

vertical tab

'\FF'

'\12'

,

'\f'

form feed

'\CR'

'\13'

,

'\r'

carriage return

'\SO'

'\14'

shift out

'\SI'

'\15'

shift in

'\DLE'

'\16'

data link escape

'\DC1'

'\17'

device control 1

'\DC2'

'\18'

device control 2

'\DC3'

'\19'

device control 3

'\DC4'

'\20'

device control 4

'\NAK'

'\21'

negative acknowledge

'\SYN'

'\22'

synchronous idle

'\ETB'

'\23'

end of transmission block

'\CAN'

'\24'

cancel

'\EM'

'\25'

end of medium

'\SUB'

'\26'

substitute

'\ESC'

'\27'

escape

'\FS'

'\28'

file separator

'\GS'

'\29'

group separator

'\RS'

'\30'

record separator

'\US'

'\31'

unit separator

'\SP'

'\32'

,

' '

space

'\DEL'

'\127'

delete

Data.Char provides utilities to work with Char.

Instances38Bounded, Enum, Data, Read, Ix, Storable, …
datadata Double
#

Double-precision floating point numbers. It is desirable that this type be at least equal in range and precision to the IEEE double-precision type.

Instances36Enum, Floating, Fractional, Data, Num, Read, …
  • Enum DoubleDefined in ghc-internal-10.0.0 · GHC.Internal.Float · orphan

    fromEnum just truncates its argument, beware of all sorts of overflows.

    List generators have extremely peculiar behavior, mandated by Haskell Report 2010:

    Example1 expression
    [0..1.5][0.0,1.0,2.0]
  • Eq DoubleDefined in ghc-internal-10.0.0 · GHC.Internal.Classes

    Note that due to the presence of NaN, Double's Eq instance does not satisfy reflexivity.

    Example1 expression
    0/0 == (0/0 :: Double)False

    Also note that Double's Eq instance does not satisfy substitutivity:

    Example2 expressions
    0 == (-0 :: Double)Truerecip 0 == recip (-0 :: Double)False
  • Floating DoubleDefined in ghc-internal-10.0.0 · GHC.Internal.Float
  • Fractional DoubleDefined in ghc-internal-10.0.0 · GHC.Internal.Float · orphan

    This instance implements IEEE 754 standard with all its usual pitfalls about NaN, infinities and negative zero.

    Example4 expressions
    0 == (-0 :: Double)Truerecip 0 == recip (-0 :: Double)Falsemap (/ 0) [-1, 0, 1][-Infinity,NaN,Infinity]map (* 0) $ map (/ 0) [-1, 0, 1][NaN,NaN,NaN]
  • Data DoubleDefined in ghc-internal-10.0.0 · GHC.Internal.Data.Data
  • Num DoubleDefined in ghc-internal-10.0.0 · GHC.Internal.Float · orphan

    This instance implements IEEE 754 standard with all its usual pitfalls about NaN, infinities and negative zero. Neither addition nor multiplication are associative or distributive:

    Example3 expressions
    (0.1 + 0.1) + 0.4 == 0.1 + (0.1 + 0.4)False(0.1 + 0.2) * 0.3 == 0.1 * 0.3 + 0.2 * 0.3False(0.1 * 0.1) * 0.3 == 0.1 * (0.1 * 0.3)False
  • Ord DoubleDefined in ghc-internal-10.0.0 · GHC.Internal.Classes

    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.

  • Read DoubleDefined in ghc-internal-10.0.0 · GHC.Internal.Read
  • Real DoubleDefined in ghc-internal-10.0.0 · GHC.Internal.Float · orphan
  • RealFloat DoubleDefined in ghc-internal-10.0.0 · GHC.Internal.Float
  • RealFrac DoubleDefined in ghc-internal-10.0.0 · GHC.Internal.Float · orphan

    Beware that results for non-finite arguments are garbage:

    Example2 expressions
    [ f x | f <- [round, floor, ceiling], x <- [-1/0, 0/0, 1/0] ] :: [Int][0,0,0,0,0,0,0,0,0]map properFraction [-1/0, 0/0, 1/0] :: [(Int, Double)][(0,0.0),(0,0.0),(0,0.0)]

    and get even more non-sensical if you ask for Integer instead of Int.

  • Show DoubleDefined in ghc-internal-10.0.0 · GHC.Internal.Float · orphan
  • Storable DoubleDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.Storable
  • PrintfArg DoubleDefined in base-4.23.0.0 · Text.Printf
  • NFData DoubleDefined in deepseq-1.5.2.0 · Control.DeepSeq
  • Pretty DoubleDefined in pretty-1.1.3.6 · Text.PrettyPrint.Annotated.HughesPJClass
  • Pretty DoubleDefined in pretty-1.1.3.6 · Text.PrettyPrint.HughesPJClass
  • Binary DoubleDefined in binary-0.8.9.3 · Data.Binary.Class

    Uses non-IEEE754 encoding. Does not round-trip NaN.

  • Outputable DoubleDefined in ghc-10.0.0.20260917 · GHC.Utils.Outputable
  • Binary DoubleDefined in ghc-10.0.0.20260917 · GHC.Utils.Binary
  • ToJExpr DoubleDefined in ghc-10.0.0.20260917 · GHC.JS.Make
  • Lift DoubleDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Lift
  • IArray UArray DoubleDefined in array-0.5.8.0 · Data.Array.Base
  • MArray IOUArray Double IODefined in array-0.5.8.0 · Data.Array.IO.Internals
  • Generic1 (URec Double)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Foldable UDoubleDefined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Traversable UDoubleDefined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • MArray (STUArray s) Double (ST s)Defined in array-0.5.8.0 · Data.Array.Base
  • Functor (URec Double)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Eq (URec Double p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Ord (URec Double p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Show (URec Double p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Generic (URec Double p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • type Rep (URec Double p) = D1 ('MetaData "URec" "GHC.Internal.Generics" "ghc-internal" 'False) (C1 ('MetaCons "UDouble" 'PrefixI 'True) (S1 ('MetaSel ('Just "uDouble#") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) UDouble))Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • type Rep1 (URec Double) = D1 ('MetaData "URec" "GHC.Internal.Generics" "ghc-internal" 'False) (C1 ('MetaCons "UDouble" 'PrefixI 'True) (S1 ('MetaSel ('Just "uDouble#") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) UDouble))Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • data URec DoubleDefined in ghc-internal-10.0.0 · GHC.Internal.Generics

    Used for marking occurrences of Double#

datadata Float
#

Single-precision floating point numbers. It is desirable that this type be at least equal in range and precision to the IEEE single-precision type.

Instances35Enum, Floating, Fractional, Data, Num, Read, …
  • Enum FloatDefined in ghc-internal-10.0.0 · GHC.Internal.Float · orphan

    fromEnum just truncates its argument, beware of all sorts of overflows.

    List generators have extremely peculiar behavior, mandated by Haskell Report 2010:

    Example1 expression
    [0..1.5 :: Float][0.0,1.0,2.0]
  • Eq FloatDefined in ghc-internal-10.0.0 · GHC.Internal.Classes

    Note that due to the presence of NaN, Float's Eq instance does not satisfy reflexivity.

    Example1 expression
    0/0 == (0/0 :: Float)False

    Also note that Float's Eq instance does not satisfy extensionality:

    Example2 expressions
    0 == (-0 :: Float)Truerecip 0 == recip (-0 :: Float)False
  • Floating FloatDefined in ghc-internal-10.0.0 · GHC.Internal.Float
  • Fractional FloatDefined in ghc-internal-10.0.0 · GHC.Internal.Float · orphan

    This instance implements IEEE 754 standard with all its usual pitfalls about NaN, infinities and negative zero.

    Example4 expressions
    0 == (-0 :: Float)Truerecip 0 == recip (-0 :: Float)Falsemap (/ 0) [-1, 0, 1 :: Float][-Infinity,NaN,Infinity]map (* 0) $ map (/ 0) [-1, 0, 1 :: Float][NaN,NaN,NaN]
  • Data FloatDefined in ghc-internal-10.0.0 · GHC.Internal.Data.Data
  • Num FloatDefined in ghc-internal-10.0.0 · GHC.Internal.Float · orphan

    This instance implements IEEE 754 standard with all its usual pitfalls about NaN, infinities and negative zero. Neither addition nor multiplication are associative or distributive:

    Example3 expressions
    (0.1 + 0.1 :: Float) + 0.5 == 0.1 + (0.1 + 0.5)False(0.1 + 0.2 :: Float) * 0.9 == 0.1 * 0.9 + 0.2 * 0.9False(0.1 * 0.1 :: Float) * 0.9 == 0.1 * (0.1 * 0.9)False
  • Ord FloatDefined in ghc-internal-10.0.0 · GHC.Internal.Classes

    See instance Ord Double for discussion of deviations from IEEE 754 standard.

  • Read FloatDefined in ghc-internal-10.0.0 · GHC.Internal.Read
  • Real FloatDefined in ghc-internal-10.0.0 · GHC.Internal.Float · orphan
  • RealFloat FloatDefined in ghc-internal-10.0.0 · GHC.Internal.Float
  • RealFrac FloatDefined in ghc-internal-10.0.0 · GHC.Internal.Float · orphan

    Beware that results for non-finite arguments are garbage:

    Example2 expressions
    [ f x | f <- [round, floor, ceiling], x <- [-1/0, 0/0, 1/0 :: Float] ] :: [Int][0,0,0,0,0,0,0,0,0]map properFraction [-1/0, 0/0, 1/0] :: [(Int, Float)][(0,0.0),(0,0.0),(0,0.0)]

    and get even more non-sensical if you ask for Integer instead of Int.

  • Show FloatDefined in ghc-internal-10.0.0 · GHC.Internal.Float · orphan
  • Storable FloatDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.Storable
  • PrintfArg FloatDefined in base-4.23.0.0 · Text.Printf
  • NFData FloatDefined in deepseq-1.5.2.0 · Control.DeepSeq
  • Pretty FloatDefined in pretty-1.1.3.6 · Text.PrettyPrint.Annotated.HughesPJClass
  • Pretty FloatDefined in pretty-1.1.3.6 · Text.PrettyPrint.HughesPJClass
  • Binary FloatDefined in binary-0.8.9.3 · Data.Binary.Class

    Uses non-IEEE754 encoding. Does not round-trip NaN.

  • Outputable FloatDefined in ghc-10.0.0.20260917 · GHC.Utils.Outputable
  • Binary FloatDefined in ghc-10.0.0.20260917 · GHC.Utils.Binary
  • Lift FloatDefined in ghc-internal-10.0.0 · GHC.Internal.TH.Lift
  • IArray UArray FloatDefined in array-0.5.8.0 · Data.Array.Base
  • MArray IOUArray Float IODefined in array-0.5.8.0 · Data.Array.IO.Internals
  • Generic1 (URec Float)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Foldable UFloatDefined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Traversable UFloatDefined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • MArray (STUArray s) Float (ST s)Defined in array-0.5.8.0 · Data.Array.Base
  • Functor (URec Float)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Eq (URec Float p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Ord (URec Float p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Show (URec Float p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • Generic (URec Float p)Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • type Rep (URec Float p) = D1 ('MetaData "URec" "GHC.Internal.Generics" "ghc-internal" 'False) (C1 ('MetaCons "UFloat" 'PrefixI 'True) (S1 ('MetaSel ('Just "uFloat#") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) UFloat))Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • type Rep1 (URec Float) = D1 ('MetaData "URec" "GHC.Internal.Generics" "ghc-internal" 'False) (C1 ('MetaCons "UFloat" 'PrefixI 'True) (S1 ('MetaSel ('Just "uFloat#") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) UFloat))Defined in ghc-internal-10.0.0 · GHC.Internal.Generics
  • data URec FloatDefined in ghc-internal-10.0.0 · GHC.Internal.Generics

    Used for marking occurrences of Float#

datadata Int
#

A fixed-precision integer type with at least the range [-2^29 .. 2^29-1]. The exact range for a given implementation can be determined by using Prelude.minBound and Prelude.maxBound from the Prelude.Bounded class.

Instances48Bounded, Enum, Integral, Data, Num, Read, …
datadata Word
#

A Word is an unsigned integral type, with the same size as Int.

Instances36Bounded, Enum, Integral, Data, Num, Read, …
classclass a ~ b => (~) (a :: k) (b :: k)
#

Lifted, homogeneous equality. By lifted, we mean that it can be bogus (deferred type error). By homogeneous, the two types a and b must have the same kinds.

classclass Functor f => Applicative (f :: Type -> Type) where
#

A functor with application, providing operations to

  • embed pure expressions (pure), and

  • sequence computations and combine their results (<*> and liftA2).

A minimal complete definition must include implementations of pure and one of either <*> or liftA2. If it defines both, then they must behave the same as their default definitions:

(<*>) = liftA2 id
liftA2 f x y = f Prelude.<$> x <*> y

Further, any definition must satisfy the following:

Identity
pure id <*> v = v
Composition
pure (.) <*> u <*> v <*> w = u <*> (v <*> w)
Homomorphism
pure f <*> pure x = pure (f x)
Interchange
u <*> pure y = pure ($ y) <*> u

The other methods have the following default definitions, which may be overridden with equivalent specialized implementations:

As a consequence of these laws, the Functor instance for f will satisfy

It may be useful to note that supposing

forall x y. p (q x y) = f x . g y

it follows from the above that

liftA2 p (liftA2 q u v) = liftA2 f u . liftA2 g v

If f is also a Monad, it should satisfy

(which implies that pure and <*> satisfy the applicative functor laws).

Methods

  • pure :: a -> f a

    Lift a value into the Structure.

    Examples
    Example1 expression
    pure 1 :: Maybe IntJust 1
    Example1 expression
    pure 'z' :: [Char]"z"
    Example1 expression
    pure (pure ":D") :: Maybe [String]Just [":D"]
  • (<*>) :: f (a -> b) -> f a -> f binfixl 4

    Sequential application.

    A few functors support an implementation of <*> that is more efficient than the default one.

    Example

    Used in combination with (Data.Functor.<$>), (<*>) can be used to build a record.

    Example1 expression
    data MyState = MyState {arg1 :: Foo, arg2 :: Bar, arg3 :: Baz}
    Example3 expressions
    produceFoo :: Applicative f => f FooproduceBar :: Applicative f => f BarproduceBaz :: Applicative f => f Baz
    Example2 expressions
    mkState :: Applicative f => f MyStatemkState = MyState <$> produceFoo <*> produceBar <*> produceBaz
  • liftA2 :: (a -> b -> c) -> f a -> f b -> f c

    Lift a binary function to actions.

    Some functors support an implementation of liftA2 that is more efficient than the default one. In particular, if fmap is an expensive operation, it is likely better to use liftA2 than to fmap over the structure and then use <*>.

    This became a typeclass method in 4.10.0.0. Prior to that, it was a function defined in terms of <*> and fmap.

    Example
    Example1 expression
    liftA2 (,) (Just 3) (Just 5)Just (3,5)
    Example1 expression
    liftA2 (+) [1, 2, 3] [4, 5, 6][5,6,7,6,7,8,7,8,9]
  • (*>) :: f a -> f b -> f binfixl 4

    Sequence actions, discarding the value of the first argument.

    Examples

    If used in conjunction with the Applicative instance for Maybe, you can chain Maybe computations, with a possible "early return" in case of Nothing.

    Example1 expression
    Just 2 *> Just 3Just 3
    Example1 expression
    Nothing *> Just 3Nothing

    Of course a more interesting use case would be to have effectful computations instead of just returning pure values.

    Example4 expressions
    import Data.Charimport GHC.Internal.Text.ParserCombinators.ReadPlet p = string "my name is " *> munch1 isAlpha <* eofreadP_to_S p "my name is Simon"[("Simon","")]
  • (<*) :: f a -> f b -> f ainfixl 4

    Sequence actions, discarding the value of the second argument.

Instances158Applicative, …
valuepopCountDefault :: (Bits a, Num a) => a -> Int
#

Default implementation for popCount.

This implementation is intentionally naive. Instances are expected to provide an optimized implementation for their size.

valuetoIntegralSized :: (Integral a, Integral b, Bits a, Bits b) => a -> Maybe b
#

Attempt to convert an Integral type a to an Integral type b using the size of the types as measured by Bits methods.

A simpler version of this function is:

toIntegral :: (Integral a, Integral b) => a -> Maybe b
toIntegral x
  | toInteger x == toInteger y = Just y
  | otherwise                  = Nothing
  where
    y = fromIntegral x

This version requires going through Integer, which can be inefficient. However, toIntegralSized is optimized to allow GHC to statically determine the relative type sizes (as measured by bitSizeMaybe and isSigned) and avoid going through Integer for many types. (The implementation uses fromIntegral, which is itself optimized with rules for base types but may go through Integer for some type pairs.)

classclass Eq a => Bits a where
#

The Bits class defines bitwise operations over integral types.

  • Bits are numbered from 0 with bit 0 being the least significant bit.

Methods

  • (.&.) :: a -> a -> ainfixl 7

    Bitwise "and"

  • (.|.) :: a -> a -> ainfixl 5

    Bitwise "or"

  • xor :: a -> a -> ainfixl 6

    Bitwise "xor"

  • complement :: a -> a

    Reverse all the bits in the argument

  • shift :: a -> Int -> ainfixl 8

    shift x i shifts x left by i bits if i is positive, or right by -i bits otherwise. Right shifts perform sign extension on signed number types; i.e. they fill the top bits with 1 if the x is negative and with 0 otherwise.

    An instance can define either this unified shift or shiftL and shiftR, depending on which is more convenient for the type in question.

  • rotate :: a -> Int -> ainfixl 8

    rotate x i rotates x left by i bits if i is positive, or right by -i bits otherwise.

    For unbounded types like Integer, rotate is equivalent to shift.

    An instance can define either this unified rotate or rotateL and rotateR, depending on which is more convenient for the type in question.

  • zeroBits :: a

    zeroBits is the value with all bits unset.

    The following laws ought to hold (for all valid bit indices n):

    This method uses clearBit (bit 0) 0 as its default implementation (which ought to be equivalent to zeroBits for types which possess a 0th bit).

  • complementBit :: a -> Int -> a

    x `complementBit` i is the same as x `xor` bit i

  • testBit :: a -> Int -> Bool

    x `testBit` i is the same as x .&. bit n /= 0

    In other words it returns True if the bit at offset @n is set.

    Can be implemented using testBitDefault if a is also an instance of Num.

  • bitSizeMaybe :: a -> Maybe Int

    Return the number of bits in the type of the argument. The actual value of the argument is ignored. Returns Nothing for types that do not have a fixed bitsize, like Integer.

  • bitSize :: a -> Int

    Return the number of bits in the type of the argument. The actual value of the argument is ignored. The function bitSize is undefined for types that do not have a fixed bitsize, like Integer.

    Default implementation based upon bitSizeMaybe provided since 4.12.0.0.

  • isSigned :: a -> Bool

    Return True if the argument is a signed type. The actual value of the argument is ignored

  • unsafeShiftL :: a -> Int -> a

    Shift the argument left by the specified number of bits. The result is undefined for negative shift amounts and shift amounts greater or equal to the bitSize.

    Defaults to shiftL unless defined explicitly by an instance.

  • unsafeShiftR :: a -> Int -> a

    Shift the first argument right by the specified number of bits, which must be non-negative and smaller than the number of bits in the type.

    Right shifts perform sign extension on signed number types; i.e. they fill the top bits with 1 if the x is negative and with 0 otherwise.

    Defaults to shiftR unless defined explicitly by an instance.

  • rotateL :: a -> Int -> ainfixl 8

    Rotate the argument left by the specified number of bits (which must be non-negative).

    An instance can define either this and rotateR or the unified rotate, depending on which is more convenient for the type in question.

  • rotateR :: a -> Int -> ainfixl 8

    Rotate the argument right by the specified number of bits (which must be non-negative).

    An instance can define either this and rotateL or the unified rotate, depending on which is more convenient for the type in question.

  • popCount :: a -> Int

    Return the number of set bits in the argument. This number is known as the population count or the Hamming weight.

    Can be implemented using popCountDefault if a is also an instance of Num.

Instances70Bits, …
  • Bits RegBitmapDefined in ghc-10.0.0.20260917 · GHC.ByteCode.Types
  • Bits StgWordDefined in ghc-10.0.0.20260917 · GHC.Runtime.Heap.Layout
  • Bits IntegerDefined in ghc-internal-10.0.0 · GHC.Internal.Bits
  • Bits NaturalDefined in ghc-internal-10.0.0 · GHC.Internal.Bits
  • Bits EventTypeDefined in ghc-internal-10.0.0 · GHC.Internal.Event.EPoll
  • Bits EventDefined in ghc-internal-10.0.0 · GHC.Internal.Event.Poll
  • Bits CBoolDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Bits CCharDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Bits CIntDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Bits CIntMaxDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Bits CIntPtrDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Bits CLLongDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Bits CLongDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Bits CPtrdiffDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Bits CSCharDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Bits CShortDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Bits CSigAtomicDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Bits CSizeDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Bits CUCharDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Bits CUIntDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Bits CUIntMaxDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Bits CUIntPtrDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Bits CULLongDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Bits CULongDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Bits CUShortDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Bits CWcharDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.C.Types
  • Bits IntPtrDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.Ptr
  • Bits WordPtrDefined in ghc-internal-10.0.0 · GHC.Internal.Foreign.Ptr
  • Bits Int16Defined in ghc-internal-10.0.0 · GHC.Internal.Int
  • Bits Int32Defined in ghc-internal-10.0.0 · GHC.Internal.Int
  • Bits Int64Defined in ghc-internal-10.0.0 · GHC.Internal.Int
  • Bits Int8Defined in ghc-internal-10.0.0 · GHC.Internal.Int
  • Bits CBlkCntDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Bits CBlkSizeDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Bits CClockIdDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Bits CDevDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Bits CFsBlkCntDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Bits CFsFilCntDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Bits CGidDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Bits CIdDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Bits CInoDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Bits CKeyDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Bits CModeDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Bits CNfdsDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Bits CNlinkDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Bits COffDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Bits CPidDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Bits CRLimDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Bits CSocklenDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Bits CSsizeDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Bits CTcflagDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Bits CUidDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Bits FdDefined in ghc-internal-10.0.0 · GHC.Internal.System.Posix.Types
  • Bits BoolDefined in ghc-internal-10.0.0 · GHC.Internal.Bits

    Interpret Bool as 1-bit bit-field

  • Bits IntDefined in ghc-internal-10.0.0 · GHC.Internal.Bits
  • Bits WordDefined in ghc-internal-10.0.0 · GHC.Internal.Bits
  • Bits Word16Defined in ghc-internal-10.0.0 · GHC.Internal.Word
  • Bits Word32Defined in ghc-internal-10.0.0 · GHC.Internal.Word
  • Bits Word64Defined in ghc-internal-10.0.0 · GHC.Internal.Word
  • Bits Word8Defined in ghc-internal-10.0.0 · GHC.Internal.Word
  • Bits CAttributesDefined in unix-2.8.8.0 · System.Posix.Files.Common
  • Bits StatxFlagsDefined in unix-2.8.8.0 · System.Posix.Files.Common
  • Bits StatxMaskDefined in unix-2.8.8.0 · System.Posix.Files.Common
  • Bits a => Bits (And a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Bits
  • Bits a => Bits (Iff a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Bits
  • Bits a => Bits (Ior a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Bits
  • Bits a => Bits (Xor a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Bits
  • Bits a => Bits (Identity a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Functor.Identity
  • Bits a => Bits (Down a)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Ord
  • Bits a => Bits (Const a b)Defined in ghc-internal-10.0.0 · GHC.Internal.Data.Functor.Const
classclass Bits b => FiniteBits b where
#

The FiniteBits class denotes types with a finite, fixed number of bits.

Methods

Instances64FiniteBits, …
valuestrictGenericLength :: Num a => [x] -> a
#

The genericLength function defined in base can't be specialised due to the NOINLINE pragma.

It is also not strict in the accumulator, and strictGenericLength is not exported.

See #25706 for why it is important to use a strict, specialised version.