Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell2010 |
Reexports of most of the definitions from the "base" package, which it is a common practice to import unqualified.
For details check out the source.
Synopsis
- (++) :: [a] -> [a] -> [a]
- seq :: forall {r :: RuntimeRep} a (b :: TYPE r). a -> b -> b
- filter :: (a -> Bool) -> [a] -> [a]
- zip :: [a] -> [b] -> [(a, b)]
- newStablePtr :: a -> IO (StablePtr a)
- print :: Show a => a -> IO ()
- fst :: (a, b) -> a
- snd :: (a, b) -> b
- otherwise :: Bool
- assert :: Bool -> a -> a
- lazy :: a -> a
- assertError :: (?callStack :: CallStack) => Bool -> a -> a
- trace :: String -> a -> a
- inline :: a -> a
- map :: (a -> b) -> [a] -> [b]
- groupWith :: Ord b => (a -> b) -> [a] -> [[a]]
- ($) :: forall (r :: RuntimeRep) a (b :: TYPE r). (a -> b) -> a -> b
- coerce :: forall {k :: RuntimeRep} (a :: TYPE k) (b :: TYPE k). Coercible a b => a -> b
- fromIntegral :: (Integral a, Num b) => a -> b
- realToFrac :: (Real a, Fractional b) => a -> b
- guard :: Alternative f => Bool -> f ()
- class IsList l where
- toDyn :: Typeable a => a -> Dynamic
- unsafeEqualityProof :: forall {k} (a :: k) (b :: k). UnsafeEquality a b
- unsafeCoerce# :: forall (q :: RuntimeRep) (r :: RuntimeRep) (a :: TYPE q) (b :: TYPE r). a -> b
- join :: Monad m => m (m a) -> m a
- class Bounded a where
- class Enum a where
- succ :: a -> a
- pred :: a -> a
- toEnum :: Int -> a
- fromEnum :: a -> Int
- enumFrom :: a -> [a]
- enumFromThen :: a -> a -> [a]
- enumFromTo :: a -> a -> [a]
- enumFromThenTo :: a -> a -> a -> [a]
- class Eq a where
- class Fractional a => Floating a where
- pi :: a
- exp :: a -> a
- log :: a -> a
- sqrt :: a -> a
- (**) :: a -> a -> a
- logBase :: a -> a -> a
- sin :: a -> a
- cos :: a -> a
- tan :: a -> a
- asin :: a -> a
- acos :: a -> a
- atan :: a -> a
- sinh :: a -> a
- cosh :: a -> a
- tanh :: a -> a
- asinh :: a -> a
- acosh :: a -> a
- atanh :: a -> a
- log1p :: a -> a
- expm1 :: a -> a
- log1pexp :: a -> a
- log1mexp :: a -> a
- class Num a => Fractional a where
- (/) :: a -> a -> a
- recip :: a -> a
- fromRational :: Rational -> a
- class (Real a, Enum a) => Integral a where
- class Applicative m => Monad (m :: Type -> Type) where
- class Typeable a => Data a where
- gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> a -> c a
- gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c a
- toConstr :: a -> Constr
- dataTypeOf :: a -> DataType
- dataCast1 :: Typeable t => (forall d. Data d => c (t d)) -> Maybe (c a)
- dataCast2 :: Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c a)
- gmapT :: (forall b. Data b => b -> b) -> a -> a
- gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> a -> r
- gmapQr :: forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> a -> r
- gmapQ :: (forall d. Data d => d -> u) -> a -> [u]
- gmapQi :: Int -> (forall d. Data d => d -> u) -> a -> u
- gmapM :: Monad m => (forall d. Data d => d -> m d) -> a -> m a
- gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> a -> m a
- gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> a -> m a
- class Functor (f :: Type -> Type) where
- class Num a where
- class Eq a => Ord a where
- class Read a where
- class (Num a, Ord a) => Real a where
- toRational :: a -> Rational
- class (RealFrac a, Floating a) => RealFloat a where
- floatRadix :: a -> Integer
- floatDigits :: a -> Int
- floatRange :: a -> (Int, Int)
- decodeFloat :: a -> (Integer, Int)
- encodeFloat :: Integer -> Int -> a
- exponent :: a -> Int
- significand :: a -> a
- scaleFloat :: Int -> a -> a
- isNaN :: a -> Bool
- isInfinite :: a -> Bool
- isDenormalized :: a -> Bool
- isNegativeZero :: a -> Bool
- isIEEE :: a -> Bool
- atan2 :: a -> a -> a
- class (Real a, Fractional a) => RealFrac a where
- class Show a where
- class Ord a => Ix a where
- class Typeable (a :: k)
- class Monad m => MonadFix (m :: Type -> Type) where
- mfix :: (a -> m a) -> m a
- class Monad m => MonadFail (m :: Type -> Type) where
- class IsString a where
- fromString :: String -> a
- class Functor f => Applicative (f :: Type -> Type) where
- class Foldable (t :: TYPE LiftedRep -> Type) where
- fold :: Monoid m => t m -> m
- foldMap :: Monoid m => (a -> m) -> t a -> m
- foldMap' :: Monoid m => (a -> m) -> t a -> m
- foldr :: (a -> b -> b) -> b -> t a -> b
- foldr' :: (a -> b -> b) -> b -> t a -> b
- foldl :: (b -> a -> b) -> b -> t a -> b
- foldl' :: (b -> a -> b) -> b -> t a -> b
- foldr1 :: (a -> a -> a) -> t a -> a
- foldl1 :: (a -> a -> a) -> t a -> a
- null :: t a -> Bool
- length :: t a -> Int
- elem :: Eq a => a -> t a -> Bool
- maximum :: Ord a => t a -> a
- minimum :: Ord a => t a -> a
- sum :: Num a => t a -> a
- product :: Num a => t a -> a
- class (Functor t, Foldable t) => Traversable (t :: Type -> Type) where
- traverse :: Applicative f => (a -> f b) -> t a -> f (t b)
- sequenceA :: Applicative f => t (f a) -> f (t a)
- mapM :: Monad m => (a -> m b) -> t a -> m (t b)
- sequence :: Monad m => t (m a) -> m (t a)
- class Generic a
- class Generic1 (f :: k -> Type)
- class Semigroup a where
- class Semigroup a => Monoid a where
- class HasField (x :: k) r a | x r -> a where
- getField :: r -> a
- data Bool
- type String = [Char]
- data Char
- data Double
- data Float
- data Int
- data Int8
- data Int16
- data Int32
- data Int64
- data Integer
- data Natural
- data Maybe a
- data Ordering
- data Ratio a
- type Rational = Ratio Integer
- data RealWorld
- data StablePtr a
- data IO a
- data Word
- data Word8
- data Word16
- data Word32
- data Word64
- data Ptr a
- data FunPtr a
- data Either a b
- data NonEmpty a = a :| [a]
- class a ~R# b => Coercible (a :: k) (b :: k)
- data UnsafeEquality (a :: k) (b :: k) where
- UnsafeRefl :: forall {k} (a :: k). UnsafeEquality a a
- data TyCon
- newtype Predicate a = Predicate {
- getPredicate :: a -> Bool
- newtype Op a b = Op {
- getOp :: b -> a
- newtype Equivalence a = Equivalence {
- getEquivalence :: a -> a -> Bool
- class Contravariant (f :: Type -> Type) where
- newtype Comparison a = Comparison {
- getComparison :: a -> a -> Ordering
- phantom :: (Functor f, Contravariant f) => f a -> f b
- defaultEquivalence :: Eq a => Equivalence a
- defaultComparison :: Ord a => Comparison a
- comparisonEquivalence :: Comparison a -> Equivalence a
- (>$<) :: Contravariant f => (a -> b) -> f b -> f a
- (>$$<) :: Contravariant f => f b -> (a -> b) -> f a
- ($<) :: Contravariant f => f b -> b -> f a
- newtype Compose (f :: k -> Type) (g :: k1 -> k) (a :: k1) = Compose {
- getCompose :: f (g a)
- class Show2 (f :: TYPE LiftedRep -> TYPE LiftedRep -> TYPE LiftedRep) where
- class Show1 (f :: TYPE LiftedRep -> TYPE LiftedRep) where
- class Read2 (f :: Type -> Type -> Type) where
- liftReadsPrec2 :: (Int -> ReadS a) -> ReadS [a] -> (Int -> ReadS b) -> ReadS [b] -> Int -> ReadS (f a b)
- liftReadList2 :: (Int -> ReadS a) -> ReadS [a] -> (Int -> ReadS b) -> ReadS [b] -> ReadS [f a b]
- liftReadPrec2 :: ReadPrec a -> ReadPrec [a] -> ReadPrec b -> ReadPrec [b] -> ReadPrec (f a b)
- liftReadListPrec2 :: ReadPrec a -> ReadPrec [a] -> ReadPrec b -> ReadPrec [b] -> ReadPrec [f a b]
- class Read1 (f :: Type -> Type) where
- liftReadsPrec :: (Int -> ReadS a) -> ReadS [a] -> Int -> ReadS (f a)
- liftReadList :: (Int -> ReadS a) -> ReadS [a] -> ReadS [f a]
- liftReadPrec :: ReadPrec a -> ReadPrec [a] -> ReadPrec (f a)
- liftReadListPrec :: ReadPrec a -> ReadPrec [a] -> ReadPrec [f a]
- class Eq2 f => Ord2 (f :: Type -> Type -> Type) where
- liftCompare2 :: (a -> b -> Ordering) -> (c -> d -> Ordering) -> f a c -> f b d -> Ordering
- class Eq1 f => Ord1 (f :: Type -> Type) where
- liftCompare :: (a -> b -> Ordering) -> f a -> f b -> Ordering
- class Eq2 (f :: Type -> Type -> Type) where
- class Eq1 (f :: Type -> Type) where
- showsUnaryWith :: (Int -> a -> ShowS) -> String -> Int -> a -> ShowS
- showsUnary1 :: (Show1 f, Show a) => String -> Int -> f a -> ShowS
- showsUnary :: Show a => String -> Int -> a -> ShowS
- showsPrec2 :: (Show2 f, Show a, Show b) => Int -> f a b -> ShowS
- showsPrec1 :: (Show1 f, Show a) => Int -> f a -> ShowS
- showsBinaryWith :: (Int -> a -> ShowS) -> (Int -> b -> ShowS) -> String -> Int -> a -> b -> ShowS
- showsBinary1 :: (Show1 f, Show1 g, Show a) => String -> Int -> f a -> g a -> ShowS
- readsUnaryWith :: (Int -> ReadS a) -> String -> (a -> t) -> String -> ReadS t
- readsUnary1 :: (Read1 f, Read a) => String -> (f a -> t) -> String -> ReadS t
- readsUnary :: Read a => String -> (a -> t) -> String -> ReadS t
- readsPrec2 :: (Read2 f, Read a, Read b) => Int -> ReadS (f a b)
- readsPrec1 :: (Read1 f, Read a) => Int -> ReadS (f a)
- readsData :: (String -> ReadS a) -> Int -> ReadS a
- readsBinaryWith :: (Int -> ReadS a) -> (Int -> ReadS b) -> String -> (a -> b -> t) -> String -> ReadS t
- readsBinary1 :: (Read1 f, Read1 g, Read a) => String -> (f a -> g a -> t) -> String -> ReadS t
- readUnaryWith :: ReadPrec a -> String -> (a -> t) -> ReadPrec t
- readPrec2 :: (Read2 f, Read a, Read b) => ReadPrec (f a b)
- readPrec1 :: (Read1 f, Read a) => ReadPrec (f a)
- readData :: ReadPrec a -> ReadPrec a
- readBinaryWith :: ReadPrec a -> ReadPrec b -> String -> (a -> b -> t) -> ReadPrec t
- liftReadListPrecDefault :: Read1 f => ReadPrec a -> ReadPrec [a] -> ReadPrec [f a]
- liftReadListPrec2Default :: Read2 f => ReadPrec a -> ReadPrec [a] -> ReadPrec b -> ReadPrec [b] -> ReadPrec [f a b]
- liftReadListDefault :: Read1 f => (Int -> ReadS a) -> ReadS [a] -> ReadS [f a]
- liftReadList2Default :: Read2 f => (Int -> ReadS a) -> ReadS [a] -> (Int -> ReadS b) -> ReadS [b] -> ReadS [f a b]
- eq2 :: (Eq2 f, Eq a, Eq b) => f a b -> f a b -> Bool
- eq1 :: (Eq1 f, Eq a) => f a -> f a -> Bool
- compare2 :: (Ord2 f, Ord a, Ord b) => f a b -> f a b -> Ordering
- compare1 :: (Ord1 f, Ord a) => f a -> f a -> Ordering
- data Complex a = !a :+ !a
- realPart :: Complex a -> a
- polar :: RealFloat a => Complex a -> (a, a)
- phase :: RealFloat a => Complex a -> a
- mkPolar :: Floating a => a -> a -> Complex a
- magnitude :: RealFloat a => Complex a -> a
- imagPart :: Complex a -> a
- conjugate :: Num a => Complex a -> Complex a
- cis :: Floating a => a -> Complex a
- type Uni = Fixed E0
- type Pico = Fixed E12
- type Nano = Fixed E9
- type Milli = Fixed E3
- type Micro = Fixed E6
- class HasResolution (a :: k) where
- resolution :: p a -> Integer
- newtype Fixed (a :: k) = MkFixed Integer
- data E9
- data E6
- data E3
- data E2
- data E12
- data E1
- data E0
- type Deci = Fixed E1
- type Centi = Fixed E2
- showFixed :: forall {k} (a :: k). HasResolution a => Bool -> Fixed a -> String
- mod' :: Real a => a -> a -> a
- divMod' :: (Real a, Integral b) => a -> a -> (b, a)
- div' :: (Real a, Integral b) => a -> a -> b
- data Void
- vacuous :: Functor f => f Void -> f a
- absurd :: Void -> a
- newtype WrappedMonoid m = WrapMonoid {
- unwrapMonoid :: m
- newtype Min a = Min {
- getMin :: a
- newtype Max a = Max {
- getMax :: a
- newtype Last a = Last {
- getLast :: a
- newtype First a = First {
- getFirst :: a
- type ArgMin a b = Min (Arg a b)
- type ArgMax a b = Max (Arg a b)
- data Arg a b = Arg a b
- mtimesDefault :: (Integral b, Monoid a) => b -> a -> a
- diff :: Semigroup m => m -> Endo m
- cycle1 :: Semigroup m => m -> m
- type family Item l
- sortWith :: Ord b => (a -> b) -> [a] -> [a]
- data Fixity
- data DataType
- data DataRep
- data ConstrRep
- data Constr
- type ConIndex = Int
- tyconUQname :: String -> String
- tyconModule :: String -> String
- showConstr :: Constr -> String
- repConstr :: DataType -> ConstrRep -> Constr
- readConstr :: DataType -> String -> Maybe Constr
- mkRealConstr :: (Real a, Show a) => DataType -> a -> Constr
- mkNoRepType :: String -> DataType
- mkIntegralConstr :: (Integral a, Show a) => DataType -> a -> Constr
- mkIntType :: String -> DataType
- mkFloatType :: String -> DataType
- mkDataType :: String -> [Constr] -> DataType
- mkConstrTag :: DataType -> String -> Int -> [String] -> Fixity -> Constr
- mkConstr :: DataType -> String -> [String] -> Fixity -> Constr
- mkCharType :: String -> DataType
- mkCharConstr :: DataType -> Char -> Constr
- maxConstrIndex :: DataType -> ConIndex
- isNorepType :: DataType -> Bool
- isAlgType :: DataType -> Bool
- indexConstr :: DataType -> ConIndex -> Constr
- fromConstrM :: (Monad m, Data a) => (forall d. Data d => m d) -> Constr -> m a
- fromConstrB :: Data a => (forall d. Data d => d) -> Constr -> a
- fromConstr :: Data a => Constr -> a
- dataTypeRep :: DataType -> DataRep
- dataTypeName :: DataType -> String
- dataTypeConstrs :: DataType -> [Constr]
- constrType :: Constr -> DataType
- constrRep :: Constr -> ConstrRep
- constrIndex :: Constr -> ConIndex
- constrFixity :: Constr -> Fixity
- constrFields :: Constr -> [String]
- data Timeout
- timeout :: Int -> IO a -> IO (Maybe a)
- threadWaitWriteSTM :: Fd -> IO (STM (), IO ())
- threadWaitWrite :: Fd -> IO ()
- threadWaitReadSTM :: Fd -> IO (STM (), IO ())
- threadWaitRead :: Fd -> IO ()
- runInUnboundThread :: IO a -> IO a
- runInBoundThread :: IO a -> IO a
- rtsSupportsBoundThreads :: Bool
- isCurrentThreadBound :: IO Bool
- forkOSWithUnmask :: ((forall a. IO a -> IO a) -> IO ()) -> IO ThreadId
- forkOS :: IO () -> IO ThreadId
- forkFinally :: IO a -> (Either SomeException a -> IO ()) -> IO ThreadId
- data Chan a
- writeList2Chan :: Chan a -> [a] -> IO ()
- writeChan :: Chan a -> a -> IO ()
- readChan :: Chan a -> IO a
- newChan :: IO (Chan a)
- getChanContents :: Chan a -> IO [a]
- dupChan :: Chan a -> IO (Chan a)
- data QSem
- waitQSem :: QSem -> IO ()
- signalQSem :: QSem -> IO ()
- newQSem :: Int -> IO QSem
- data QSemN
- waitQSemN :: QSemN -> Int -> IO ()
- signalQSemN :: QSemN -> Int -> IO ()
- newQSemN :: Int -> IO QSemN
- class Bifunctor (p :: Type -> Type -> Type) where
- class Monad m => MonadIO (m :: Type -> Type) where
- approxRational :: RealFrac a => a -> a -> Rational
- modifySTRef' :: STRef s a -> (a -> a) -> ST s ()
- modifySTRef :: STRef s a -> (a -> a) -> ST s ()
- data Unique
- newUnique :: IO Unique
- hashUnique :: Unique -> Int
- class IsLabel (x :: Symbol) a where
- fromLabel :: a
- data StableName a
- makeStableName :: a -> IO (StableName a)
- hashStableName :: StableName a -> Int
- eqStableName :: StableName a -> StableName b -> Bool
- withProgName :: String -> IO a -> IO a
- withArgs :: [String] -> IO a -> IO a
- unsetEnv :: String -> IO ()
- setEnv :: String -> String -> IO ()
- lookupEnv :: String -> IO (Maybe String)
- getProgName :: IO String
- getEnvironment :: IO [(String, String)]
- getEnv :: String -> IO String
- getArgs :: IO [String]
- getExecutablePath :: IO FilePath
- exitWith :: ExitCode -> IO a
- exitSuccess :: IO a
- exitFailure :: IO a
- die :: String -> IO a
- performMinorGC :: IO ()
- performMajorGC :: IO ()
- performGC :: IO ()
- printf :: PrintfType r => String -> r
- hPrintf :: HPrintfType r => Handle -> String -> r
- zipWithM_ :: Applicative m => (a -> b -> m c) -> [a] -> [b] -> m ()
- zipWithM :: Applicative m => (a -> b -> m c) -> [a] -> [b] -> m [c]
- unless :: Applicative f => Bool -> f () -> f ()
- replicateM_ :: Applicative m => Int -> m a -> m ()
- replicateM :: Applicative m => Int -> m a -> m [a]
- mfilter :: MonadPlus m => (a -> Bool) -> m a -> m a
- mapAndUnzipM :: Applicative m => (a -> m (b, c)) -> [a] -> m ([b], [c])
- forever :: Applicative f => f a -> f b
- foldM_ :: (Foldable t, Monad m) => (b -> a -> m b) -> b -> t a -> m ()
- foldM :: (Foldable t, Monad m) => (b -> a -> m b) -> b -> t a -> m b
- filterM :: Applicative m => (a -> m Bool) -> [a] -> m [a]
- (>=>) :: Monad m => (a -> m b) -> (b -> m c) -> a -> m c
- (<=<) :: Monad m => (b -> m c) -> (a -> m b) -> a -> m c
- (<$!>) :: Monad m => (a -> b) -> m a -> m b
- showVersion :: Version -> String
- parseVersion :: ReadP Version
- traceStack :: String -> a -> a
- traceShowM :: (Show a, Applicative f) => a -> f ()
- traceShowId :: Show a => a -> a
- traceShow :: Show a => a -> b -> b
- traceMarkerIO :: String -> IO ()
- traceMarker :: String -> a -> a
- traceM :: Applicative f => String -> f ()
- traceId :: String -> String
- traceIO :: String -> IO ()
- traceEventIO :: String -> IO ()
- traceEvent :: String -> a -> a
- putTraceMsg :: String -> IO ()
- flushEventLog :: IO ()
- isSubsequenceOf :: Eq a => [a] -> [a] -> Bool
- mapAccumR :: Traversable t => (s -> a -> (s, b)) -> s -> t a -> (s, t b)
- mapAccumL :: Traversable t => (s -> a -> (s, b)) -> s -> t a -> (s, t b)
- forM :: (Traversable t, Monad m) => t a -> (a -> m b) -> m (t b)
- for :: (Traversable t, Applicative f) => t a -> (a -> f b) -> f (t b)
- foldMapDefault :: (Traversable t, Monoid m) => (a -> m) -> t a -> m
- fmapDefault :: Traversable t => (a -> b) -> t a -> t b
- newtype ZipList a = ZipList {
- getZipList :: [a]
- newtype WrappedMonad (m :: Type -> Type) a = WrapMonad {
- unwrapMonad :: m a
- newtype WrappedArrow (a :: Type -> Type -> Type) b c = WrapArrow {
- unwrapArrow :: a b c
- optional :: Alternative f => f a -> f (Maybe a)
- newtype Kleisli (m :: Type -> Type) a b = Kleisli {
- runKleisli :: a -> m b
- class Arrow a => ArrowZero (a :: TYPE LiftedRep -> TYPE LiftedRep -> Type) where
- zeroArrow :: a b c
- class ArrowZero a => ArrowPlus (a :: TYPE LiftedRep -> TYPE LiftedRep -> Type) where
- (<+>) :: a b c -> a b c -> a b c
- newtype ArrowMonad (a :: Type -> Type -> Type) b = ArrowMonad (a () b)
- class Arrow a => ArrowLoop (a :: TYPE LiftedRep -> TYPE LiftedRep -> Type) where
- loop :: a (b, d) (c, d) -> a b c
- class Arrow a => ArrowChoice (a :: TYPE LiftedRep -> TYPE LiftedRep -> Type) where
- class Arrow a => ArrowApply (a :: TYPE LiftedRep -> TYPE LiftedRep -> Type) where
- app :: a (a b c, b) c
- class Category a => Arrow (a :: TYPE LiftedRep -> TYPE LiftedRep -> Type) where
- returnA :: Arrow a => a b b
- leftApp :: ArrowApply a => a b c -> a (Either b d) (Either c d)
- (^>>) :: Arrow a => (b -> c) -> a c d -> a b d
- (^<<) :: Arrow a => (c -> d) -> a b c -> a b d
- (>>^) :: Arrow a => a b c -> (c -> d) -> a b d
- (<<^) :: Arrow a => a c d -> (b -> c) -> a b d
- newtype Identity a = Identity {
- runIdentity :: a
- writeFile :: FilePath -> String -> IO ()
- readLn :: Read a => IO a
- readIO :: Read a => String -> IO a
- readFile' :: FilePath -> IO String
- readFile :: FilePath -> IO String
- putStrLn :: String -> IO ()
- putStr :: String -> IO ()
- putChar :: Char -> IO ()
- openTempFileWithDefaultPermissions :: FilePath -> String -> IO (FilePath, Handle)
- openTempFile :: FilePath -> String -> IO (FilePath, Handle)
- openBinaryTempFileWithDefaultPermissions :: FilePath -> String -> IO (FilePath, Handle)
- openBinaryTempFile :: FilePath -> String -> IO (FilePath, Handle)
- localeEncoding :: TextEncoding
- interact :: (String -> String) -> IO ()
- hReady :: Handle -> IO Bool
- hPrint :: Show a => Handle -> a -> IO ()
- getLine :: IO String
- getContents' :: IO String
- getContents :: IO String
- getChar :: IO Char
- fixIO :: (a -> IO a) -> IO a
- appendFile :: FilePath -> String -> IO ()
- data HandlePosn
- isEOF :: IO Bool
- hTell :: Handle -> IO Integer
- hShow :: Handle -> IO String
- hSetPosn :: HandlePosn -> IO ()
- hSetNewlineMode :: Handle -> NewlineMode -> IO ()
- hSetFileSize :: Handle -> Integer -> IO ()
- hSetEncoding :: Handle -> TextEncoding -> IO ()
- hSetEcho :: Handle -> Bool -> IO ()
- hSetBuffering :: Handle -> BufferMode -> IO ()
- hSetBinaryMode :: Handle -> Bool -> IO ()
- hSeek :: Handle -> SeekMode -> Integer -> IO ()
- hLookAhead :: Handle -> IO Char
- hIsWritable :: Handle -> IO Bool
- hIsTerminalDevice :: Handle -> IO Bool
- hIsSeekable :: Handle -> IO Bool
- hIsReadable :: Handle -> IO Bool
- hIsOpen :: Handle -> IO Bool
- hIsEOF :: Handle -> IO Bool
- hIsClosed :: Handle -> IO Bool
- hGetPosn :: Handle -> IO HandlePosn
- hGetEncoding :: Handle -> IO (Maybe TextEncoding)
- hGetEcho :: Handle -> IO Bool
- hGetBuffering :: Handle -> IO BufferMode
- hFileSize :: Handle -> IO Integer
- hClose :: Handle -> IO ()
- withFile :: FilePath -> IOMode -> (Handle -> IO r) -> IO r
- withBinaryFile :: FilePath -> IOMode -> (Handle -> IO r) -> IO r
- stdin :: Handle
- stderr :: Handle
- openFile :: FilePath -> IOMode -> IO Handle
- openBinaryFile :: FilePath -> IOMode -> IO Handle
- threadDelay :: Int -> IO ()
- registerDelay :: Int -> IO (TVar Bool)
- ioManagerCapabilitiesChanged :: IO ()
- ensureIOManagerIsRunning :: IO ()
- closeFdWith :: (Fd -> IO ()) -> Fd -> IO ()
- type Signal = CInt
- type HandlerFun = ForeignPtr Word8 -> IO ()
- setHandler :: Signal -> Maybe (HandlerFun, Dynamic) -> IO (Maybe (HandlerFun, Dynamic))
- runHandlers :: ForeignPtr Word8 -> Signal -> IO ()
- withMVarMasked :: MVar a -> (a -> IO b) -> IO b
- withMVar :: MVar a -> (a -> IO b) -> IO b
- swapMVar :: MVar a -> a -> IO a
- modifyMVar_ :: MVar a -> (a -> IO a) -> IO ()
- modifyMVarMasked_ :: MVar a -> (a -> IO a) -> IO ()
- modifyMVarMasked :: MVar a -> (a -> IO (a, b)) -> IO b
- modifyMVar :: MVar a -> (a -> IO (a, b)) -> IO b
- mkWeakMVar :: MVar a -> IO () -> IO (Weak (MVar a))
- addMVarFinalizer :: MVar a -> IO () -> IO ()
- hWaitForInput :: Handle -> Int -> IO Bool
- hPutStrLn :: Handle -> String -> IO ()
- hPutStr :: Handle -> String -> IO ()
- hPutChar :: Handle -> Char -> IO ()
- hPutBufNonBlocking :: Handle -> Ptr a -> Int -> IO Int
- hPutBuf :: Handle -> Ptr a -> Int -> IO ()
- hGetLine :: Handle -> IO String
- hGetContents' :: Handle -> IO String
- hGetContents :: Handle -> IO String
- hGetChar :: Handle -> IO Char
- hGetBufSome :: Handle -> Ptr a -> Int -> IO Int
- hGetBufNonBlocking :: Handle -> Ptr a -> Int -> IO Int
- hGetBuf :: Handle -> Ptr a -> Int -> IO Int
- utf8_bom :: TextEncoding
- utf8 :: TextEncoding
- utf32le :: TextEncoding
- utf32be :: TextEncoding
- utf32 :: TextEncoding
- utf16le :: TextEncoding
- utf16be :: TextEncoding
- utf16 :: TextEncoding
- mkTextEncoding :: String -> IO TextEncoding
- latin1 :: TextEncoding
- char8 :: TextEncoding
- unsafeFixIO :: (a -> IO a) -> IO a
- data Handler a = Exception e => Handler (e -> IO a)
- catches :: IO a -> [Handler a] -> IO a
- allowInterrupt :: IO ()
- fixST :: (a -> ST s a) -> ST s a
- userErrorType :: IOErrorType
- tryIOError :: IO a -> IO (Either IOError a)
- resourceVanishedErrorType :: IOErrorType
- permissionErrorType :: IOErrorType
- modifyIOError :: (IOError -> IOError) -> IO a -> IO a
- mkIOError :: IOErrorType -> String -> Maybe Handle -> Maybe FilePath -> IOError
- isUserErrorType :: IOErrorType -> Bool
- isUserError :: IOError -> Bool
- isResourceVanishedErrorType :: IOErrorType -> Bool
- isResourceVanishedError :: IOError -> Bool
- isPermissionErrorType :: IOErrorType -> Bool
- isPermissionError :: IOError -> Bool
- isIllegalOperationErrorType :: IOErrorType -> Bool
- isIllegalOperation :: IOError -> Bool
- isFullErrorType :: IOErrorType -> Bool
- isFullError :: IOError -> Bool
- isEOFErrorType :: IOErrorType -> Bool
- isEOFError :: IOError -> Bool
- isDoesNotExistErrorType :: IOErrorType -> Bool
- isDoesNotExistError :: IOError -> Bool
- isAlreadyInUseErrorType :: IOErrorType -> Bool
- isAlreadyInUseError :: IOError -> Bool
- isAlreadyExistsErrorType :: IOErrorType -> Bool
- isAlreadyExistsError :: IOError -> Bool
- ioeSetLocation :: IOError -> String -> IOError
- ioeSetHandle :: IOError -> Handle -> IOError
- ioeSetFileName :: IOError -> FilePath -> IOError
- ioeSetErrorType :: IOError -> IOErrorType -> IOError
- ioeSetErrorString :: IOError -> String -> IOError
- ioeGetLocation :: IOError -> String
- ioeGetHandle :: IOError -> Maybe Handle
- ioeGetFileName :: IOError -> Maybe FilePath
- ioeGetErrorType :: IOError -> IOErrorType
- ioeGetErrorString :: IOError -> String
- illegalOperationErrorType :: IOErrorType
- fullErrorType :: IOErrorType
- eofErrorType :: IOErrorType
- doesNotExistErrorType :: IOErrorType
- catchIOError :: IO a -> (IOError -> IO a) -> IO a
- annotateIOError :: IOError -> String -> Maybe Handle -> Maybe FilePath -> IOError
- alreadyInUseErrorType :: IOErrorType
- alreadyExistsErrorType :: IOErrorType
- newtype TypeError = TypeError String
- newtype RecUpdError = RecUpdError String
- newtype RecSelError = RecSelError String
- newtype RecConError = RecConError String
- newtype PatternMatchFail = PatternMatchFail String
- data NonTermination = NonTermination
- newtype NoMethodError = NoMethodError String
- data NestedAtomically = NestedAtomically
- tryJust :: Exception e => (e -> Maybe b) -> IO a -> IO (Either b a)
- try :: Exception e => IO a -> IO (Either e a)
- onException :: IO a -> IO b -> IO a
- mapException :: (Exception e1, Exception e2) => (e1 -> e2) -> a -> a
- handleJust :: Exception e => (e -> Maybe b) -> (b -> IO a) -> IO a -> IO a
- handle :: Exception e => (e -> IO a) -> IO a -> IO a
- finally :: IO a -> IO b -> IO a
- catchJust :: Exception e => (e -> Maybe b) -> IO a -> (b -> IO a) -> IO a
- bracket_ :: IO a -> IO b -> IO c -> IO c
- bracketOnError :: IO a -> (a -> IO b) -> (a -> IO c) -> IO c
- bracket :: IO a -> (a -> IO b) -> (a -> IO c) -> IO c
- data ThreadStatus
- data ThreadId = ThreadId ThreadId#
- data TVar a = TVar (TVar# RealWorld a)
- newtype STM a = STM (State# RealWorld -> (# State# RealWorld, a #))
- data PrimMVar
- data BlockReason
- yield :: IO ()
- writeTVar :: TVar a -> a -> STM ()
- unsafeIOToSTM :: IO a -> STM a
- throwTo :: Exception e => ThreadId -> e -> IO ()
- throwSTM :: Exception e => e -> STM a
- threadStatus :: ThreadId -> IO ThreadStatus
- threadCapability :: ThreadId -> IO (Int, Bool)
- setUncaughtExceptionHandler :: (SomeException -> IO ()) -> IO ()
- setNumCapabilities :: Int -> IO ()
- setAllocationCounter :: Int64 -> IO ()
- runSparks :: IO ()
- retry :: STM a
- reportStackOverflow :: IO ()
- reportHeapOverflow :: IO ()
- reportError :: SomeException -> IO ()
- readTVarIO :: TVar a -> IO a
- readTVar :: TVar a -> STM a
- pseq :: a -> b -> b
- par :: a -> b -> b
- numSparks :: IO Int
- numCapabilities :: Int
- newTVarIO :: a -> IO (TVar a)
- newTVar :: a -> STM (TVar a)
- newStablePtrPrimMVar :: MVar () -> IO (StablePtr PrimMVar)
- myThreadId :: IO ThreadId
- mkWeakThreadId :: ThreadId -> IO (Weak ThreadId)
- labelThread :: ThreadId -> String -> IO ()
- killThread :: ThreadId -> IO ()
- getUncaughtExceptionHandler :: IO (SomeException -> IO ())
- getNumProcessors :: IO Int
- getNumCapabilities :: IO Int
- getAllocationCounter :: IO Int64
- forkOnWithUnmask :: Int -> ((forall a. IO a -> IO a) -> IO ()) -> IO ThreadId
- forkOn :: Int -> IO () -> IO ThreadId
- forkIOWithUnmask :: ((forall a. IO a -> IO a) -> IO ()) -> IO ThreadId
- forkIO :: IO () -> IO ThreadId
- enableAllocationLimit :: IO ()
- disableAllocationLimit :: IO ()
- childHandler :: SomeException -> IO ()
- catchSTM :: Exception e => STM a -> (e -> STM a) -> STM a
- atomically :: STM a -> IO a
- data Dynamic where
- fromDynamic :: Typeable a => Dynamic -> Maybe a
- fromDyn :: Typeable a => Dynamic -> a -> a
- dynTypeRep :: Dynamic -> SomeTypeRep
- dynApply :: Dynamic -> Dynamic -> Maybe Dynamic
- dynApp :: Dynamic -> Dynamic -> Dynamic
- data SomeAsyncException = Exception e => SomeAsyncException e
- data IOErrorType
- data FixIOException = FixIOException
- data ExitCode
- data Deadlock = Deadlock
- newtype CompactionFailed = CompactionFailed String
- data BlockedIndefinitelyOnSTM = BlockedIndefinitelyOnSTM
- data BlockedIndefinitelyOnMVar = BlockedIndefinitelyOnMVar
- data AsyncException
- newtype AssertionFailed = AssertionFailed String
- data ArrayException
- data AllocationLimitExceeded = AllocationLimitExceeded
- untangle :: Addr# -> String -> String
- stackOverflow :: SomeException
- ioException :: IOException -> IO a
- ioError :: IOError -> IO a
- heapOverflow :: SomeException
- cannotCompactPinned :: SomeException
- cannotCompactMutable :: SomeException
- cannotCompactFunction :: SomeException
- blockedIndefinitelyOnSTM :: SomeException
- blockedIndefinitelyOnMVar :: SomeException
- asyncExceptionToException :: Exception e => e -> SomeException
- asyncExceptionFromException :: Exception e => SomeException -> Maybe e
- allocationLimitExceeded :: SomeException
- hFlush :: Handle -> IO ()
- stdout :: Handle
- data NewlineMode = NewlineMode {}
- data Newline
- data Handle
- data BufferMode
- universalNewlineMode :: NewlineMode
- noNewlineTranslation :: NewlineMode
- nativeNewlineMode :: NewlineMode
- nativeNewline :: Newline
- data SeekMode
- modifyIORef' :: IORef a -> (a -> a) -> IO ()
- modifyIORef :: IORef a -> (a -> a) -> IO ()
- mkWeakIORef :: IORef a -> IO () -> IO (Weak (IORef a))
- atomicWriteIORef :: IORef a -> a -> IO ()
- atomicModifyIORef :: IORef a -> (a -> (a, b)) -> IO b
- data TextEncoding
- newForeignPtrEnv :: FinalizerEnvPtr env a -> Ptr env -> Ptr a -> IO (ForeignPtr a)
- newForeignPtr :: FinalizerPtr a -> Ptr a -> IO (ForeignPtr a)
- mallocForeignPtrArray0 :: Storable a => Int -> IO (ForeignPtr a)
- mallocForeignPtrArray :: Storable a => Int -> IO (ForeignPtr a)
- data ForeignPtr a
- type FinalizerPtr a = FunPtr (Ptr a -> IO ())
- type FinalizerEnvPtr env a = FunPtr (Ptr env -> Ptr a -> IO ())
- withForeignPtr :: ForeignPtr a -> (Ptr a -> IO b) -> IO b
- touchForeignPtr :: ForeignPtr a -> IO ()
- plusForeignPtr :: ForeignPtr a -> Int -> ForeignPtr b
- newForeignPtr_ :: Ptr a -> IO (ForeignPtr a)
- mallocForeignPtrBytes :: Int -> IO (ForeignPtr a)
- mallocForeignPtr :: Storable a => IO (ForeignPtr a)
- finalizeForeignPtr :: ForeignPtr a -> IO ()
- castForeignPtr :: ForeignPtr a -> ForeignPtr b
- addForeignPtrFinalizerEnv :: FinalizerEnvPtr env a -> Ptr env -> ForeignPtr a -> IO ()
- addForeignPtrFinalizer :: FinalizerPtr a -> ForeignPtr a -> IO ()
- data IORef a
- writeIORef :: IORef a -> a -> IO ()
- readIORef :: IORef a -> IO a
- newIORef :: a -> IO (IORef a)
- atomicModifyIORef' :: IORef a -> (a -> (a, b)) -> IO b
- data MaskingState
- type FilePath = String
- uninterruptibleMask_ :: IO a -> IO a
- uninterruptibleMask :: ((forall a. IO a -> IO a) -> IO b) -> IO b
- throwIO :: Exception e => e -> IO a
- stToIO :: ST RealWorld a -> IO a
- mask_ :: IO a -> IO a
- mask :: ((forall a. IO a -> IO a) -> IO b) -> IO b
- interruptible :: IO a -> IO a
- getMaskingState :: IO MaskingState
- evaluate :: a -> IO a
- catch :: Exception e => IO a -> (e -> IO a) -> IO a
- data IOException = IOError {}
- type IOError = IOException
- userError :: String -> IOError
- unsupportedOperation :: IOError
- data ErrorCall where
- throw :: forall (r :: RuntimeRep) (a :: TYPE r) e. Exception e => e -> a
- class (Typeable e, Show e) => Exception e where
- toException :: e -> SomeException
- fromException :: SomeException -> Maybe e
- displayException :: e -> String
- data ArithException
- type TypeRep = SomeTypeRep
- typeRepTyCon :: TypeRep -> TyCon
- typeRepFingerprint :: TypeRep -> Fingerprint
- typeRepArgs :: TypeRep -> [TypeRep]
- typeRep :: forall {k} proxy (a :: k). Typeable a => proxy a -> TypeRep
- typeOf7 :: Typeable t => t a b c d e f g -> TypeRep
- typeOf6 :: Typeable t => t a b c d e f -> TypeRep
- typeOf5 :: Typeable t => t a b c d e -> TypeRep
- typeOf4 :: Typeable t => t a b c d -> TypeRep
- typeOf3 :: Typeable t => t a b c -> TypeRep
- typeOf2 :: Typeable t => t a b -> TypeRep
- typeOf1 :: Typeable t => t a -> TypeRep
- typeOf :: Typeable a => a -> TypeRep
- splitTyConApp :: TypeRep -> (TyCon, [TypeRep])
- showsTypeRep :: TypeRep -> ShowS
- rnfTypeRep :: TypeRep -> ()
- mkFunTy :: TypeRep -> TypeRep -> TypeRep
- gcast2 :: forall {k1} {k2} {k3} c (t :: k2 -> k3 -> k1) (t' :: k2 -> k3 -> k1) (a :: k2) (b :: k3). (Typeable t, Typeable t') => c (t a b) -> Maybe (c (t' a b))
- gcast1 :: forall {k1} {k2} c (t :: k2 -> k1) (t' :: k2 -> k1) (a :: k2). (Typeable t, Typeable t') => c (t a) -> Maybe (c (t' a))
- gcast :: forall {k} (a :: k) (b :: k) c. (Typeable a, Typeable b) => c a -> Maybe (c b)
- funResultTy :: TypeRep -> TypeRep -> Maybe TypeRep
- eqT :: forall {k} (a :: k) (b :: k). (Typeable a, Typeable b) => Maybe (a :~: b)
- cast :: (Typeable a, Typeable b) => a -> Maybe b
- tyConPackage :: TyCon -> String
- tyConName :: TyCon -> String
- tyConModule :: TyCon -> String
- tyConFingerprint :: TyCon -> Fingerprint
- trLiftedRep :: TypeRep ('BoxedRep 'Lifted)
- rnfTyCon :: TyCon -> ()
- newtype Const a (b :: k) = Const {
- getConst :: a
- traverse_ :: (Foldable t, Applicative f) => (a -> f b) -> t a -> f ()
- sequence_ :: (Foldable t, Monad m) => t (m a) -> m ()
- sequenceA_ :: (Foldable t, Applicative f) => t (f a) -> f ()
- or :: Foldable t => t Bool -> Bool
- notElem :: (Foldable t, Eq a) => a -> t a -> Bool
- msum :: (Foldable t, MonadPlus m) => t (m a) -> m a
- minimumBy :: Foldable t => (a -> a -> Ordering) -> t a -> a
- maximumBy :: Foldable t => (a -> a -> Ordering) -> t a -> a
- mapM_ :: (Foldable t, Monad m) => (a -> m b) -> t a -> m ()
- for_ :: (Foldable t, Applicative f) => t a -> (a -> f b) -> f ()
- forM_ :: (Foldable t, Monad m) => t a -> (a -> m b) -> m ()
- foldrM :: (Foldable t, Monad m) => (a -> b -> m b) -> b -> t a -> m b
- foldlM :: (Foldable t, Monad m) => (b -> a -> m b) -> b -> t a -> m b
- find :: Foldable t => (a -> Bool) -> t a -> Maybe a
- concatMap :: Foldable t => (a -> [b]) -> t a -> [b]
- concat :: Foldable t => t [a] -> [a]
- asum :: (Foldable t, Alternative f) => t (f a) -> f a
- any :: Foldable t => (a -> Bool) -> t a -> Bool
- and :: Foldable t => t Bool -> Bool
- all :: Foldable t => (a -> Bool) -> t a -> Bool
- zipWith7 :: (a -> b -> c -> d -> e -> f -> g -> h) -> [a] -> [b] -> [c] -> [d] -> [e] -> [f] -> [g] -> [h]
- zipWith6 :: (a -> b -> c -> d -> e -> f -> g) -> [a] -> [b] -> [c] -> [d] -> [e] -> [f] -> [g]
- zipWith5 :: (a -> b -> c -> d -> e -> f) -> [a] -> [b] -> [c] -> [d] -> [e] -> [f]
- zipWith4 :: (a -> b -> c -> d -> e) -> [a] -> [b] -> [c] -> [d] -> [e]
- zip7 :: [a] -> [b] -> [c] -> [d] -> [e] -> [f] -> [g] -> [(a, b, c, d, e, f, g)]
- zip6 :: [a] -> [b] -> [c] -> [d] -> [e] -> [f] -> [(a, b, c, d, e, f)]
- zip5 :: [a] -> [b] -> [c] -> [d] -> [e] -> [(a, b, c, d, e)]
- zip4 :: [a] -> [b] -> [c] -> [d] -> [(a, b, c, d)]
- words :: String -> [String]
- unzip7 :: [(a, b, c, d, e, f, g)] -> ([a], [b], [c], [d], [e], [f], [g])
- unzip6 :: [(a, b, c, d, e, f)] -> ([a], [b], [c], [d], [e], [f])
- unzip5 :: [(a, b, c, d, e)] -> ([a], [b], [c], [d], [e])
- unzip4 :: [(a, b, c, d)] -> ([a], [b], [c], [d])
- unwords :: [String] -> String
- unlines :: [String] -> String
- unionBy :: (a -> a -> Bool) -> [a] -> [a] -> [a]
- union :: Eq a => [a] -> [a] -> [a]
- unfoldr :: (b -> Maybe (a, b)) -> b -> [a]
- transpose :: [[a]] -> [[a]]
- tails :: [a] -> [[a]]
- subsequences :: [a] -> [[a]]
- stripPrefix :: Eq a => [a] -> [a] -> Maybe [a]
- sortOn :: Ord b => (a -> b) -> [a] -> [a]
- sortBy :: (a -> a -> Ordering) -> [a] -> [a]
- sort :: Ord a => [a] -> [a]
- singleton :: a -> [a]
- permutations :: [a] -> [[a]]
- partition :: (a -> Bool) -> [a] -> ([a], [a])
- nubBy :: (a -> a -> Bool) -> [a] -> [a]
- nub :: Eq a => [a] -> [a]
- lines :: String -> [String]
- isSuffixOf :: Eq a => [a] -> [a] -> Bool
- isPrefixOf :: Eq a => [a] -> [a] -> Bool
- isInfixOf :: Eq a => [a] -> [a] -> Bool
- intersperse :: a -> [a] -> [a]
- intersectBy :: (a -> a -> Bool) -> [a] -> [a] -> [a]
- intersect :: Eq a => [a] -> [a] -> [a]
- intercalate :: [a] -> [[a]] -> [a]
- insertBy :: (a -> a -> Ordering) -> a -> [a] -> [a]
- insert :: Ord a => a -> [a] -> [a]
- inits :: [a] -> [[a]]
- groupBy :: (a -> a -> Bool) -> [a] -> [[a]]
- group :: Eq a => [a] -> [[a]]
- genericTake :: Integral i => i -> [a] -> [a]
- genericSplitAt :: Integral i => i -> [a] -> ([a], [a])
- genericReplicate :: Integral i => i -> a -> [a]
- genericLength :: Num i => [a] -> i
- genericIndex :: Integral i => [a] -> i -> a
- genericDrop :: Integral i => i -> [a] -> [a]
- findIndices :: (a -> Bool) -> [a] -> [Int]
- findIndex :: (a -> Bool) -> [a] -> Maybe Int
- elemIndices :: Eq a => a -> [a] -> [Int]
- elemIndex :: Eq a => a -> [a] -> Maybe Int
- dropWhileEnd :: (a -> Bool) -> [a] -> [a]
- deleteFirstsBy :: (a -> a -> Bool) -> [a] -> [a] -> [a]
- deleteBy :: (a -> a -> Bool) -> a -> [a] -> [a]
- delete :: Eq a => a -> [a] -> [a]
- (\\) :: Eq a => [a] -> [a] -> [a]
- newtype Ap (f :: k -> Type) (a :: k) = Ap {
- getAp :: f a
- newtype Sum a = Sum {
- getSum :: a
- newtype Product a = Product {
- getProduct :: a
- newtype Endo a = Endo {
- appEndo :: a -> a
- newtype Dual a = Dual {
- getDual :: a
- newtype Any = Any {}
- newtype Alt (f :: k -> Type) (a :: k) = Alt {
- getAlt :: f a
- newtype All = All {}
- stimesMonoid :: (Integral b, Monoid a) => b -> a -> a
- stimesIdempotent :: Integral b => b -> a -> a
- newtype Down a = Down {
- getDown :: a
- comparing :: Ord a => (b -> a) -> b -> b -> Ordering
- clamp :: Ord a => (a, a) -> a -> a
- newtype WordPtr = WordPtr Word
- newtype IntPtr = IntPtr Int
- wordPtrToPtr :: WordPtr -> Ptr a
- ptrToWordPtr :: Ptr a -> WordPtr
- ptrToIntPtr :: Ptr a -> IntPtr
- intPtrToPtr :: IntPtr -> Ptr a
- freeHaskellFunPtr :: FunPtr a -> IO ()
- class Storable a where
- freeStablePtr :: StablePtr a -> IO ()
- deRefStablePtr :: StablePtr a -> IO a
- castStablePtrToPtr :: StablePtr a -> Ptr ()
- castPtrToStablePtr :: Ptr () -> StablePtr a
- unsafeCoerceUnlifted :: forall (a :: UnliftedType) (b :: UnliftedType). a -> b
- unsafeCoerceAddr :: forall (a :: TYPE 'AddrRep) (b :: TYPE 'AddrRep). a -> b
- unsafeCoerce :: a -> b
- newtype Xor a = Xor {
- getXor :: a
- newtype Ior a = Ior {
- getIor :: a
- newtype Iff a = Iff {
- getIff :: a
- newtype And a = And {
- getAnd :: a
- oneBits :: FiniteBits a => a
- isSeparator :: Char -> Bool
- isNumber :: Char -> Bool
- isMark :: Char -> Bool
- isLetter :: Char -> Bool
- digitToInt :: Char -> Int
- reads :: Read a => ReadS a
- readMaybe :: Read a => String -> Maybe a
- readEither :: Read a => String -> Either String a
- read :: Read a => String -> a
- rights :: [Either a b] -> [b]
- partitionEithers :: [Either a b] -> ([a], [b])
- lefts :: [Either a b] -> [a]
- isRight :: Either a b -> Bool
- isLeft :: Either a b -> Bool
- fromRight :: b -> Either a b -> b
- fromLeft :: a -> Either a b -> a
- either :: (a -> c) -> (b -> c) -> Either a b -> c
- data Proxy (t :: k) = Proxy
- data KProxy t = KProxy
- asProxyTypeOf :: a -> proxy a -> a
- class Category (cat :: k -> k -> Type) where
- (>>>) :: forall {k} cat (a :: k) (b :: k) (c :: k). Category cat => cat a b -> cat b c -> cat a c
- (<<<) :: forall {k} cat (b :: k) (c :: k) (a :: k). Category cat => cat b c -> cat a b -> cat a c
- data (a :: k1) :~~: (b :: k2) where
- data (a :: k) :~: (b :: k) where
- data IOMode
- plusPtr :: Ptr a -> Int -> Ptr b
- nullPtr :: Ptr a
- nullFunPtr :: FunPtr a
- minusPtr :: Ptr a -> Ptr b -> Int
- castPtrToFunPtr :: Ptr a -> FunPtr b
- castPtr :: Ptr a -> Ptr b
- castFunPtrToPtr :: FunPtr a -> Ptr b
- castFunPtr :: FunPtr a -> FunPtr b
- alignPtr :: Ptr a -> Int -> Ptr a
- showOct :: (Integral a, Show a) => a -> ShowS
- showIntAtBase :: (Integral a, Show a) => a -> (Int -> Char) -> a -> ShowS
- showInt :: Integral a => a -> ShowS
- showHex :: (Integral a, Show a) => a -> ShowS
- showHFloat :: RealFloat a => a -> ShowS
- showGFloatAlt :: RealFloat a => Maybe Int -> a -> ShowS
- showGFloat :: RealFloat a => Maybe Int -> a -> ShowS
- showFFloatAlt :: RealFloat a => Maybe Int -> a -> ShowS
- showFFloat :: RealFloat a => Maybe Int -> a -> ShowS
- showEFloat :: RealFloat a => Maybe Int -> a -> ShowS
- showBin :: (Integral a, Show a) => a -> ShowS
- readSigned :: Real a => ReadS a -> ReadS a
- readOct :: (Eq a, Num a) => ReadS a
- readInt :: Num a => a -> (Char -> Bool) -> (Char -> Int) -> ReadS a
- readHex :: (Eq a, Num a) => ReadS a
- readFloat :: RealFrac a => ReadS a
- readDec :: (Eq a, Num a) => ReadS a
- readBin :: (Eq a, Num a) => ReadS a
- readParen :: Bool -> ReadS a -> ReadS a
- readLitChar :: ReadS Char
- lexLitChar :: ReadS String
- lexDigits :: ReadS String
- lex :: ReadS String
- data ReadPrec a
- readS_to_Prec :: (Int -> ReadS a) -> ReadPrec a
- readPrec_to_S :: ReadPrec a -> Int -> ReadS a
- readPrec_to_P :: ReadPrec a -> Int -> ReadP a
- readP_to_Prec :: (Int -> ReadP a) -> ReadPrec a
- type ReadS a = String -> [(a, String)]
- data ReadP a
- readS_to_P :: ReadS a -> ReadP a
- readP_to_S :: ReadP a -> ReadS a
- showFloat :: RealFloat a => a -> ShowS
- fromRat :: RealFloat a => Rational -> a
- floatToDigits :: RealFloat a => Integer -> a -> ([Int], Int)
- byteSwap64 :: Word64 -> Word64
- byteSwap32 :: Word32 -> Word32
- byteSwap16 :: Word16 -> Word16
- bitReverse8 :: Word8 -> Word8
- bitReverse64 :: Word64 -> Word64
- bitReverse32 :: Word32 -> Word32
- bitReverse16 :: Word16 -> Word16
- data GeneralCategory
- = UppercaseLetter
- | LowercaseLetter
- | TitlecaseLetter
- | ModifierLetter
- | OtherLetter
- | NonSpacingMark
- | SpacingCombiningMark
- | EnclosingMark
- | DecimalNumber
- | LetterNumber
- | OtherNumber
- | ConnectorPunctuation
- | DashPunctuation
- | OpenPunctuation
- | ClosePunctuation
- | InitialQuote
- | FinalQuote
- | OtherPunctuation
- | MathSymbol
- | CurrencySymbol
- | ModifierSymbol
- | OtherSymbol
- | Space
- | LineSeparator
- | ParagraphSeparator
- | Control
- | Format
- | Surrogate
- | PrivateUse
- | NotAssigned
- toUpper :: Char -> Char
- toTitle :: Char -> Char
- toLower :: Char -> Char
- isUpper :: Char -> Bool
- isSymbol :: Char -> Bool
- isSpace :: Char -> Bool
- isPunctuation :: Char -> Bool
- isPrint :: Char -> Bool
- isOctDigit :: Char -> Bool
- isLower :: Char -> Bool
- isLatin1 :: Char -> Bool
- isHexDigit :: Char -> Bool
- isDigit :: Char -> Bool
- isControl :: Char -> Bool
- isAsciiUpper :: Char -> Bool
- isAsciiLower :: Char -> Bool
- isAscii :: Char -> Bool
- isAlphaNum :: Char -> Bool
- isAlpha :: Char -> Bool
- generalCategory :: Char -> GeneralCategory
- class Bits b => FiniteBits b where
- finiteBitSize :: b -> Int
- countLeadingZeros :: b -> Int
- countTrailingZeros :: b -> Int
- class Eq a => Bits a where
- (.&.) :: a -> a -> a
- (.|.) :: a -> a -> a
- xor :: a -> a -> a
- complement :: a -> a
- shift :: a -> Int -> a
- rotate :: a -> Int -> a
- zeroBits :: a
- bit :: Int -> a
- setBit :: a -> Int -> a
- clearBit :: a -> Int -> a
- complementBit :: a -> Int -> a
- testBit :: a -> Int -> Bool
- bitSizeMaybe :: a -> Maybe Int
- bitSize :: a -> Int
- isSigned :: a -> Bool
- shiftL :: a -> Int -> a
- unsafeShiftL :: a -> Int -> a
- shiftR :: a -> Int -> a
- unsafeShiftR :: a -> Int -> a
- rotateL :: a -> Int -> a
- rotateR :: a -> Int -> a
- popCount :: a -> Int
- toIntegralSized :: (Integral a, Integral b, Bits a, Bits b) => a -> Maybe b
- testBitDefault :: (Bits a, Num a) => a -> Int -> Bool
- popCountDefault :: (Bits a, Num a) => a -> Int
- bitDefault :: (Bits a, Num a) => Int -> a
- showSigned :: Real a => (a -> ShowS) -> Int -> a -> ShowS
- odd :: Integral a => a -> Bool
- numerator :: Ratio a -> a
- lcm :: Integral a => a -> a -> a
- gcd :: Integral a => a -> a -> a
- even :: Integral a => a -> Bool
- denominator :: Ratio a -> a
- (^^) :: (Fractional a, Integral b) => a -> b -> a
- (^) :: (Num a, Integral b) => a -> b -> a
- (%) :: Integral a => a -> a -> Ratio a
- chr :: Int -> Char
- data STRef s a
- writeSTRef :: STRef s a -> a -> ST s ()
- readSTRef :: STRef s a -> ST s a
- newSTRef :: a -> ST s (STRef s a)
- data ST s a
- runST :: (forall s. ST s a) -> a
- type ShowS = String -> String
- shows :: Show a => a -> ShowS
- showString :: String -> ShowS
- showParen :: Bool -> ShowS -> ShowS
- showLitChar :: Char -> ShowS
- showChar :: Char -> ShowS
- intToDigit :: Int -> Char
- zipWith3 :: (a -> b -> c -> d) -> [a] -> [b] -> [c] -> [d]
- zipWith :: (a -> b -> c) -> [a] -> [b] -> [c]
- zip3 :: [a] -> [b] -> [c] -> [(a, b, c)]
- unzip3 :: [(a, b, c)] -> ([a], [b], [c])
- unzip :: [(a, b)] -> ([a], [b])
- uncons :: [a] -> Maybe (a, [a])
- takeWhile :: (a -> Bool) -> [a] -> [a]
- take :: Int -> [a] -> [a]
- tail :: [a] -> [a]
- splitAt :: Int -> [a] -> ([a], [a])
- span :: (a -> Bool) -> [a] -> ([a], [a])
- scanr1 :: (a -> a -> a) -> [a] -> [a]
- scanr :: (a -> b -> b) -> b -> [a] -> [b]
- scanl1 :: (a -> a -> a) -> [a] -> [a]
- scanl' :: (b -> a -> b) -> b -> [a] -> [b]
- scanl :: (b -> a -> b) -> b -> [a] -> [b]
- reverse :: [a] -> [a]
- replicate :: Int -> a -> [a]
- repeat :: a -> [a]
- lookup :: Eq a => a -> [(a, b)] -> Maybe b
- last :: [a] -> a
- iterate' :: (a -> a) -> a -> [a]
- iterate :: (a -> a) -> a -> [a]
- init :: [a] -> [a]
- head :: [a] -> a
- foldl1' :: (a -> a -> a) -> [a] -> a
- dropWhile :: (a -> Bool) -> [a] -> [a]
- drop :: Int -> [a] -> [a]
- cycle :: [a] -> [a]
- break :: (a -> Bool) -> [a] -> ([a], [a])
- (!!) :: [a] -> Int -> a
- maybeToList :: Maybe a -> [a]
- maybe :: b -> (a -> b) -> Maybe a -> b
- mapMaybe :: (a -> Maybe b) -> [a] -> [b]
- listToMaybe :: [a] -> Maybe a
- isNothing :: Maybe a -> Bool
- isJust :: Maybe a -> Bool
- fromMaybe :: a -> Maybe a -> a
- fromJust :: HasCallStack => Maybe a -> a
- catMaybes :: [Maybe a] -> [a]
- bool :: a -> a -> Bool -> a
- on :: (b -> b -> c) -> (a -> b) -> a -> a -> c
- fix :: (a -> a) -> a
- (&) :: a -> (a -> b) -> b
- void :: Functor f => f a -> f ()
- (<&>) :: Functor f => f a -> (a -> b) -> f b
- (<$>) :: Functor f => (a -> b) -> f a -> f b
- ($>) :: Functor f => f a -> b -> f b
- uncurry :: (a -> b -> c) -> (a, b) -> c
- swap :: (a, b) -> (b, a)
- curry :: ((a, b) -> c) -> a -> b -> c
- data Version = Version {
- versionBranch :: [Int]
- versionTags :: [String]
- makeVersion :: [Int] -> Version
- unsafePerformIO :: IO a -> a
- unsafeInterleaveIO :: IO a -> IO a
- unsafeDupablePerformIO :: IO a -> a
- data MVar a
- tryTakeMVar :: MVar a -> IO (Maybe a)
- tryReadMVar :: MVar a -> IO (Maybe a)
- tryPutMVar :: MVar a -> a -> IO Bool
- takeMVar :: MVar a -> IO a
- readMVar :: MVar a -> IO a
- putMVar :: MVar a -> a -> IO ()
- newMVar :: a -> IO (MVar a)
- newEmptyMVar :: IO (MVar a)
- isEmptyMVar :: MVar a -> IO Bool
- subtract :: Num a => a -> a -> a
- class (Alternative m, Monad m) => MonadPlus (m :: Type -> Type) where
- class Applicative f => Alternative (f :: Type -> Type) where
- when :: Applicative f => Bool -> f () -> f ()
- until :: (a -> Bool) -> (a -> a) -> a -> a
- ord :: Char -> Int
- liftM5 :: Monad m => (a1 -> a2 -> a3 -> a4 -> a5 -> r) -> m a1 -> m a2 -> m a3 -> m a4 -> m a5 -> m r
- liftM4 :: Monad m => (a1 -> a2 -> a3 -> a4 -> r) -> m a1 -> m a2 -> m a3 -> m a4 -> m r
- liftM3 :: Monad m => (a1 -> a2 -> a3 -> r) -> m a1 -> m a2 -> m a3 -> m r
- liftM2 :: Monad m => (a1 -> a2 -> r) -> m a1 -> m a2 -> m r
- liftM :: Monad m => (a1 -> r) -> m a1 -> m r
- liftA3 :: Applicative f => (a -> b -> c -> d) -> f a -> f b -> f c -> f d
- liftA :: Applicative f => (a -> b) -> f a -> f b
- flip :: (a -> b -> c) -> b -> a -> c
- const :: a -> b -> a
- asTypeOf :: a -> a -> a
- ap :: Monad m => m (a -> b) -> m a -> m b
- (=<<) :: Monad m => (a -> m b) -> m a -> m b
- (<**>) :: Applicative f => f a -> f (a -> b) -> f b
- ($!) :: forall (r :: RuntimeRep) a (b :: TYPE r). (a -> b) -> a -> b
- undefined :: forall (r :: RuntimeRep) (a :: TYPE r). HasCallStack => a
- errorWithoutStackTrace :: forall (r :: RuntimeRep) (a :: TYPE r). [Char] -> a
- error :: forall (r :: RuntimeRep) (a :: TYPE r). HasCallStack => [Char] -> a
- stimesIdempotentMonoid :: (Integral b, Monoid a) => b -> a -> a
- data SomeException = Exception e => SomeException e
- (&&) :: Bool -> Bool -> Bool
- not :: Bool -> Bool
- (||) :: Bool -> Bool -> Bool
Documentation
(++) :: [a] -> [a] -> [a] infixr 5 #
Append 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.
seq :: forall {r :: RuntimeRep} a (b :: TYPE r). a -> b -> b infixr 0 #
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.
filter :: (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]
>>>
filter odd [1, 2, 3]
[1,3]
zip :: [a] -> [b] -> [(a, b)] #
\(\mathcal{O}(\min(m,n))\). zip
takes two lists and returns a list of
corresponding pairs.
>>>
zip [1, 2] ['a', 'b']
[(1,'a'),(2,'b')]
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:
>>>
zip [1] ['a', 'b']
[(1,'a')]>>>
zip [1, 2] ['a']
[(1,'a')]>>>
zip [] [1..]
[]>>>
zip [1..] []
[]
zip
is right-lazy:
>>>
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.
newStablePtr :: a -> IO (StablePtr a) #
Create a stable pointer referring to the given Haskell value.
print :: 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.
For example, a program to print the first 20 integers and their powers of 2 could be written as:
main = print ([(n, 2^n) | n <- [0..19]])
If the first argument evaluates to True
, then the result is the
second argument. Otherwise an AssertionFailed
exception
is raised, containing a String
with the source file and line number of the
call to assert
.
Assertions can normally be turned on or off with a compiler flag
(for GHC, assertions are normally on unless optimisation is turned on
with -O
or the -fignore-asserts
option is given). When assertions are turned off, the first
argument to assert
is ignored, and the second argument is
returned as the result.
The lazy
function restrains strictness analysis a little. The
call lazy e
means the same as e
, but lazy
has a magical
property so far as strictness analysis is concerned: it is lazy in
its first argument, even though its semantics is strict. After
strictness analysis has run, calls to lazy
are inlined to be the
identity function.
This behaviour is occasionally useful when controlling evaluation
order. Notably, lazy
is used in the library definition of
par
:
par :: a -> b -> b par x y = case (par# x) of _ -> lazy y
If lazy
were not lazy, par
would look strict in
y
which would defeat the whole purpose of par
.
assertError :: (?callStack :: CallStack) => Bool -> a -> a #
The trace
function outputs the trace message given as its first argument,
before returning the second argument as its result.
For example, this returns the value of f x
and outputs the message to stderr.
Depending on your terminal (settings), they may or may not be mixed.
>>>
let x = 123; f = show
>>>
trace ("calling f with x = " ++ show x) (f x)
calling f with x = 123 "123"
The trace
function should only be used for debugging, or for monitoring
execution. The function is not referentially transparent: its type indicates
that it is a pure function but it has the side effect of outputting the
trace message.
The call inline f
arranges that f
is inlined, regardless of
its size. More precisely, the call inline f
rewrites to the
right-hand side of f
's definition. This allows the programmer to
control inlining from a particular call site rather than the
definition site of the function (c.f. INLINE
pragmas).
This inlining occurs regardless of the argument to the call or the
size of f
's definition; it is unconditional. The main caveat is
that f
's definition must be visible to the compiler; it is
therefore recommended to mark the function with an INLINABLE
pragma at its definition so that GHC guarantees to record its
unfolding regardless of size.
If no inlining takes place, the inline
function expands to the
identity function in Phase zero, so its use imposes no overhead.
map :: (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, ...]
>>>
map (+1) [1, 2, 3]
[2,3,4]
groupWith :: Ord b => (a -> b) -> [a] -> [[a]] #
The groupWith
function uses the user supplied function which
projects an element out of every list element in order to first sort the
input list and then to form groups by equality on these projected elements
($) :: forall (r :: RuntimeRep) a (b :: TYPE r). (a -> b) -> a -> b infixr 0 #
Application operator. This operator is redundant, since ordinary
application (f x)
means the same as (f
. However, $
x)$
has
low, right-associative binding precedence, so it sometimes allows
parentheses to be omitted; for example:
f $ g $ h x = f (g (h x))
It is also useful in higher-order situations, such as
,
or map
($
0) xs
.zipWith
($
) fs xs
Note that (
is levity-polymorphic in its result type, so that
$
)foo
where $
Truefoo :: Bool -> Int#
is well-typed.
coerce :: forall {k :: RuntimeRep} (a :: TYPE k) (b :: TYPE k). Coercible a b => a -> b #
The function coerce
allows you to safely convert between values of
types that have the same representation with no run-time overhead. In the
simplest case you can use it instead of a newtype constructor, to go from
the newtype's concrete type to the abstract type. But it also works in
more complicated settings, e.g. converting a list of newtypes to a list of
concrete types.
This function is runtime-representation polymorphic, but the
RuntimeRep
type argument is marked as Inferred
, meaning
that it is not available for visible type application. This means
the typechecker will accept coerce @Int @Age 42
.
fromIntegral :: (Integral a, Num b) => a -> b #
general coercion from integral types
realToFrac :: (Real a, Fractional b) => a -> b #
general coercion to fractional types
guard :: Alternative f => Bool -> f () #
Conditional failure of Alternative
computations. Defined by
guard True =pure
() guard False =empty
Examples
Common uses of guard
include conditionally signaling an error in
an error monad and conditionally rejecting the current choice in an
Alternative
-based parser.
As an example of signaling an error in the error monad Maybe
,
consider a safe division function safeDiv x y
that returns
Nothing
when the denominator y
is zero and
otherwise. For example:Just
(x `div`
y)
>>>
safeDiv 4 0
Nothing
>>>
safeDiv 4 2
Just 2
A definition of safeDiv
using guards, but not guard
:
safeDiv :: Int -> Int -> Maybe Int safeDiv x y | y /= 0 = Just (x `div` y) | otherwise = Nothing
A definition of safeDiv
using guard
and Monad
do
-notation:
safeDiv :: Int -> Int -> Maybe Int safeDiv x y = do guard (y /= 0) return (x `div` y)
The IsList
class and its methods are intended to be used in
conjunction with the OverloadedLists extension.
Since: base-4.7.0.0
The fromList
function constructs the structure l
from the given
list of Item l
fromListN :: Int -> [Item l] -> l #
The fromListN
function takes the input list's length and potentially
uses it to construct the structure l
more efficiently compared to
fromList
. If the given number does not equal to the input list's length
the behaviour of fromListN
is not specified.
fromListN (length xs) xs == fromList xs
The toList
function extracts a list of Item l
from the structure l
.
It should satisfy fromList . toList = id.
Instances
toDyn :: Typeable a => a -> Dynamic #
Converts an arbitrary value into an object of type Dynamic
.
The type of the object must be an instance of Typeable
, which
ensures that only monomorphically-typed objects may be converted to
Dynamic
. To convert a polymorphic object into Dynamic
, give it
a monomorphic type signature. For example:
toDyn (id :: Int -> Int)
unsafeEqualityProof :: forall {k} (a :: k) (b :: k). UnsafeEquality a b #
unsafeCoerce# :: forall (q :: RuntimeRep) (r :: RuntimeRep) (a :: TYPE q) (b :: TYPE r). a -> b #
Highly, terribly dangerous coercion from one representation type to another. Misuse of this function can invite the garbage collector to trounce upon your data and then laugh in your face. You don't want this function. Really.
join :: Monad m => m (m a) -> m a #
The join
function is the conventional monad join operator. It
is used to remove one level of monadic structure, projecting its
bound argument into the outer level.
'
' can be understood as the join
bssdo
expression
do bs <- bss bs
Examples
A common use of join
is to run an IO
computation returned from
an STM
transaction, since STM
transactions
can't perform IO
directly. Recall that
atomically
:: STM a -> IO a
is used to run STM
transactions atomically. So, by
specializing the types of atomically
and join
to
atomically
:: STM (IO b) -> IO (IO b)join
:: IO (IO b) -> IO b
we can compose them as
join
.atomically
:: STM (IO b) -> IO b
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
.
Instances
Bounded All | Since: base-2.1 |
Bounded Any | Since: base-2.1 |
Bounded CBool | |
Bounded CChar | |
Bounded CInt | |
Bounded CIntMax | |
Bounded CIntPtr | |
Bounded CLLong | |
Bounded CLong | |
Bounded CPtrdiff | |
Bounded CSChar | |
Bounded CShort | |
Bounded CSigAtomic | |
Defined in Foreign.C.Types minBound :: CSigAtomic # maxBound :: CSigAtomic # | |
Bounded CSize | |
Bounded CUChar | |
Bounded CUInt | |
Bounded CUIntMax | |
Bounded CUIntPtr | |
Bounded CULLong | |
Bounded CULong | |
Bounded CUShort | |
Bounded CWchar | |
Bounded IntPtr | |
Bounded WordPtr | |
Bounded Associativity | Since: base-4.9.0.0 |
Defined in GHC.Generics | |
Bounded DecidedStrictness | Since: base-4.9.0.0 |
Defined in GHC.Generics | |
Bounded SourceStrictness | Since: base-4.9.0.0 |
Defined in GHC.Generics | |
Bounded SourceUnpackedness | Since: base-4.9.0.0 |
Defined in GHC.Generics | |
Bounded Int16 | Since: base-2.1 |
Bounded Int32 | Since: base-2.1 |
Bounded Int64 | Since: base-2.1 |
Bounded Int8 | Since: base-2.1 |
Bounded GeneralCategory | Since: base-2.1 |
Defined in GHC.Unicode | |
Bounded Word16 | Since: base-2.1 |
Bounded Word32 | Since: base-2.1 |
Bounded Word64 | Since: base-2.1 |
Bounded Word8 | Since: base-2.1 |
Bounded CBlkCnt | |
Bounded CBlkSize | |
Bounded CClockId | |
Bounded CDev | |
Bounded CFsBlkCnt | |
Bounded CFsFilCnt | |
Bounded CGid | |
Bounded CId | |
Bounded CIno | |
Bounded CKey | |
Bounded CMode | |
Bounded CNfds | |
Bounded CNlink | |
Bounded COff | |
Bounded CPid | |
Bounded CRLim | |
Bounded CSocklen | |
Bounded CSsize | |
Bounded CTcflag | |
Bounded CUid | |
Bounded Fd | |
Bounded Ordering | Since: base-2.1 |
Bounded () | Since: base-2.1 |
Bounded Bool | Since: base-2.1 |
Bounded Char | Since: base-2.1 |
Bounded Int | Since: base-2.1 |
Bounded Levity | Since: base-4.16.0.0 |
Bounded VecCount | Since: base-4.10.0.0 |
Bounded VecElem | Since: base-4.10.0.0 |
Bounded Word | Since: base-2.1 |
Bounded a => Bounded (And a) | Since: base-4.16 |
Bounded a => Bounded (Iff a) | Since: base-4.16 |
Bounded a => Bounded (Ior a) | Since: base-4.16 |
Bounded a => Bounded (Xor a) | Since: base-4.16 |
Bounded a => Bounded (Identity a) | Since: base-4.9.0.0 |
Bounded a => Bounded (Down a) | Swaps Since: base-4.14.0.0 |
Bounded a => Bounded (First a) | Since: base-4.9.0.0 |
Bounded a => Bounded (Last a) | Since: base-4.9.0.0 |
Bounded a => Bounded (Max a) | Since: base-4.9.0.0 |
Bounded a => Bounded (Min a) | Since: base-4.9.0.0 |
Bounded m => Bounded (WrappedMonoid m) | Since: base-4.9.0.0 |
Defined in Data.Semigroup minBound :: WrappedMonoid m # maxBound :: WrappedMonoid m # | |
Bounded a => Bounded (Dual a) | Since: base-2.1 |
Bounded a => Bounded (Product a) | Since: base-2.1 |
Bounded a => Bounded (Sum a) | Since: base-2.1 |
Bounded a => Bounded (a) | |
Bounded (Proxy t) | Since: base-4.7.0.0 |
(Bounded a, Bounded b) => Bounded (a, b) | Since: base-2.1 |
Bounded a => Bounded (Const a b) | Since: base-4.9.0.0 |
(Applicative f, Bounded a) => Bounded (Ap f a) | Since: base-4.12.0.0 |
a ~ b => Bounded (a :~: b) | Since: base-4.7.0.0 |
(Bounded a, Bounded b, Bounded c) => Bounded (a, b, c) | Since: base-2.1 |
a ~~ b => Bounded (a :~~: b) | Since: base-4.10.0.0 |
(Bounded a, Bounded b, Bounded c, Bounded d) => Bounded (a, b, c, d) | Since: base-2.1 |
(Bounded a, Bounded b, Bounded c, Bounded d, Bounded e) => Bounded (a, b, c, d, e) | Since: base-2.1 |
(Bounded a, Bounded b, Bounded c, Bounded d, Bounded e, Bounded f) => Bounded (a, b, c, d, e, f) | Since: base-2.1 |
(Bounded a, Bounded b, Bounded c, Bounded d, Bounded e, Bounded f, Bounded g) => Bounded (a, b, c, d, e, f, g) | Since: base-2.1 |
(Bounded a, Bounded b, Bounded c, Bounded d, Bounded e, Bounded f, Bounded g, Bounded h) => Bounded (a, b, c, d, e, f, g, h) | Since: base-2.1 |
(Bounded a, Bounded b, Bounded c, Bounded d, Bounded e, Bounded f, Bounded g, Bounded h, Bounded i) => Bounded (a, b, c, d, e, f, g, h, i) | Since: base-2.1 |
(Bounded a, Bounded b, Bounded c, Bounded d, Bounded e, Bounded f, Bounded g, Bounded h, Bounded i, Bounded j) => Bounded (a, b, c, d, e, f, g, h, i, j) | Since: base-2.1 |
(Bounded a, Bounded b, Bounded c, Bounded d, Bounded e, Bounded f, Bounded g, Bounded h, Bounded i, Bounded j, Bounded k) => Bounded (a, b, c, d, e, f, g, h, i, j, k) | Since: base-2.1 |
(Bounded a, Bounded b, Bounded c, Bounded d, Bounded e, Bounded f, Bounded g, Bounded h, Bounded i, Bounded j, Bounded k, Bounded l) => Bounded (a, b, c, d, e, f, g, h, i, j, k, l) | Since: base-2.1 |
(Bounded a, Bounded b, Bounded c, Bounded d, Bounded e, Bounded f, Bounded g, Bounded h, Bounded i, Bounded j, Bounded k, Bounded l, Bounded m) => Bounded (a, b, c, d, e, f, g, h, i, j, k, l, m) | Since: base-2.1 |
(Bounded a, Bounded b, Bounded c, Bounded d, Bounded e, Bounded f, Bounded g, Bounded h, Bounded i, Bounded j, Bounded k, Bounded l, Bounded m, Bounded n) => Bounded (a, b, c, d, e, f, g, h, i, j, k, l, m, n) | Since: base-2.1 |
(Bounded a, Bounded b, Bounded c, Bounded d, Bounded e, Bounded f, Bounded g, Bounded h, Bounded i, Bounded j, Bounded k, Bounded l, Bounded m, Bounded n, Bounded o) => Bounded (a, b, c, d, e, f, g, h, i, j, k, l, m, n, o) | Since: base-2.1 |
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:
- The calls
andsucc
maxBound
should result in a runtime error.pred
minBound
fromEnum
andtoEnum
should give a runtime error if the result value is not representable in the result type. For example,
is an error.toEnum
7 ::Bool
enumFrom
andenumFromThen
should be defined with an implicit bound, thus:
enumFrom x = enumFromTo x maxBound enumFromThen x y = enumFromThenTo x y bound where bound | fromEnum y >= fromEnum x = maxBound | otherwise = minBound
the successor of a value. For numeric types, succ
adds 1.
the predecessor of a value. For numeric types, pred
subtracts 1.
Convert from an 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
.
Used in Haskell's translation of [n..]
with [n..] = enumFrom n
,
a possible implementation being enumFrom n = n : enumFrom (succ n)
.
For example:
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
For example:
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 = []
.
For example:
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 = []
For example:
enumFromThenTo 4 2 -6 :: [Integer] = [4,2,0,-2,-4,-6]
enumFromThenTo 6 8 2 :: [Int] = []
Instances
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:
Instances
Eq Constr | Equality of constructors Since: base-4.0.0.0 |
Eq ConstrRep | Since: base-4.0.0.0 |
Eq DataRep | Since: base-4.0.0.0 |
Eq Fixity | Since: base-4.0.0.0 |
Eq All | Since: base-2.1 |
Eq Any | Since: base-2.1 |
Eq SomeTypeRep | |
Defined in Data.Typeable.Internal (==) :: SomeTypeRep -> SomeTypeRep -> Bool # (/=) :: SomeTypeRep -> SomeTypeRep -> Bool # | |
Eq Unique | |
Eq Version | Since: base-2.1 |
Eq Void | Since: base-4.8.0.0 |
Eq CBool | |
Eq CChar | |
Eq CClock | |
Eq CDouble | |
Eq CFloat | |
Eq CInt | |
Eq CIntMax | |
Eq CIntPtr | |
Eq CLLong | |
Eq CLong | |
Eq CPtrdiff | |
Eq CSChar | |
Eq CSUSeconds | |
Defined in Foreign.C.Types (==) :: CSUSeconds -> CSUSeconds -> Bool # (/=) :: CSUSeconds -> CSUSeconds -> Bool # | |
Eq CShort | |
Eq CSigAtomic | |
Defined in Foreign.C.Types (==) :: CSigAtomic -> CSigAtomic -> Bool # (/=) :: CSigAtomic -> CSigAtomic -> Bool # | |
Eq CSize | |
Eq CTime | |
Eq CUChar | |
Eq CUInt | |
Eq CUIntMax | |
Eq CUIntPtr | |
Eq CULLong | |
Eq CULong | |
Eq CUSeconds | |
Eq CUShort | |
Eq CWchar | |
Eq IntPtr | |
Eq WordPtr | |
Eq BlockReason | Since: base-4.3.0.0 |
Defined in GHC.Conc.Sync (==) :: BlockReason -> BlockReason -> Bool # (/=) :: BlockReason -> BlockReason -> Bool # | |
Eq ThreadId | Since: base-4.2.0.0 |
Eq ThreadStatus | Since: base-4.3.0.0 |
Defined in GHC.Conc.Sync (==) :: ThreadStatus -> ThreadStatus -> Bool # (/=) :: ThreadStatus -> ThreadStatus -> Bool # | |
Eq ErrorCall | Since: base-4.7.0.0 |
Eq ArithException | Since: base-3.0 |
Defined in GHC.Exception.Type (==) :: ArithException -> ArithException -> Bool # (/=) :: ArithException -> ArithException -> Bool # | |
Eq SpecConstrAnnotation | Since: base-4.3.0.0 |
Defined in GHC.Exts (==) :: SpecConstrAnnotation -> SpecConstrAnnotation -> Bool # (/=) :: SpecConstrAnnotation -> SpecConstrAnnotation -> Bool # | |
Eq Fingerprint | Since: base-4.4.0.0 |
Defined in GHC.Fingerprint.Type (==) :: Fingerprint -> Fingerprint -> Bool # (/=) :: Fingerprint -> Fingerprint -> Bool # | |
Eq Associativity | Since: base-4.6.0.0 |
Defined in GHC.Generics (==) :: Associativity -> Associativity -> Bool # (/=) :: Associativity -> Associativity -> Bool # | |
Eq DecidedStrictness | Since: base-4.9.0.0 |
Defined in GHC.Generics (==) :: DecidedStrictness -> DecidedStrictness -> Bool # (/=) :: DecidedStrictness -> DecidedStrictness -> Bool # | |
Eq Fixity | Since: base-4.6.0.0 |
Eq SourceStrictness | Since: base-4.9.0.0 |
Defined in GHC.Generics (==) :: SourceStrictness -> SourceStrictness -> Bool # (/=) :: SourceStrictness -> SourceStrictness -> Bool # | |
Eq SourceUnpackedness | Since: base-4.9.0.0 |
Defined in GHC.Generics (==) :: SourceUnpackedness -> SourceUnpackedness -> Bool # (/=) :: SourceUnpackedness -> SourceUnpackedness -> Bool # | |
Eq MaskingState | Since: base-4.3.0.0 |
Defined in GHC.IO (==) :: MaskingState -> MaskingState -> Bool # (/=) :: MaskingState -> MaskingState -> Bool # | |
Eq IODeviceType | Since: base-4.2.0.0 |
Defined in GHC.IO.Device (==) :: IODeviceType -> IODeviceType -> Bool # (/=) :: IODeviceType -> IODeviceType -> Bool # | |
Eq SeekMode | Since: base-4.2.0.0 |
Eq CodingProgress | Since: base-4.4.0.0 |
Defined in GHC.IO.Encoding.Types (==) :: CodingProgress -> CodingProgress -> Bool # (/=) :: CodingProgress -> CodingProgress -> Bool # | |
Eq ArrayException | Since: base-4.2.0.0 |
Defined in GHC.IO.Exception (==) :: ArrayException -> ArrayException -> Bool # (/=) :: ArrayException -> ArrayException -> Bool # | |
Eq AsyncException | Since: base-4.2.0.0 |
Defined in GHC.IO.Exception (==) :: AsyncException -> AsyncException -> Bool # (/=) :: AsyncException -> AsyncException -> Bool # | |
Eq ExitCode | |
Eq IOErrorType | Since: base-4.1.0.0 |
Defined in GHC.IO.Exception (==) :: IOErrorType -> IOErrorType -> Bool # (/=) :: IOErrorType -> IOErrorType -> Bool # | |
Eq IOException | Since: base-4.1.0.0 |
Defined in GHC.IO.Exception (==) :: IOException -> IOException -> Bool # (/=) :: IOException -> IOException -> Bool # | |
Eq HandlePosn | Since: base-4.1.0.0 |
Defined in GHC.IO.Handle (==) :: HandlePosn -> HandlePosn -> Bool # (/=) :: HandlePosn -> HandlePosn -> Bool # | |
Eq BufferMode | Since: base-4.2.0.0 |
Defined in GHC.IO.Handle.Types (==) :: BufferMode -> BufferMode -> Bool # (/=) :: BufferMode -> BufferMode -> Bool # | |
Eq Handle | Since: base-4.1.0.0 |
Eq Newline | Since: base-4.2.0.0 |
Eq NewlineMode | Since: base-4.2.0.0 |
Defined in GHC.IO.Handle.Types (==) :: NewlineMode -> NewlineMode -> Bool # (/=) :: NewlineMode -> NewlineMode -> Bool # | |
Eq IOMode | Since: base-4.2.0.0 |
Eq Int16 | Since: base-2.1 |
Eq Int32 | Since: base-2.1 |
Eq Int64 | Since: base-2.1 |
Eq Int8 | Since: base-2.1 |
Eq SrcLoc | Since: base-4.9.0.0 |
Eq GeneralCategory | Since: base-2.1 |
Defined in GHC.Unicode (==) :: GeneralCategory -> GeneralCategory -> Bool # (/=) :: GeneralCategory -> GeneralCategory -> Bool # | |
Eq Word16 | Since: base-2.1 |
Eq Word32 | Since: base-2.1 |
Eq Word64 | Since: base-2.1 |
Eq Word8 | Since: base-2.1 |
Eq CBlkCnt | |
Eq CBlkSize | |
Eq CCc | |
Eq CClockId | |
Eq CDev | |
Eq CFsBlkCnt | |
Eq CFsFilCnt | |
Eq CGid | |
Eq CId | |
Eq CIno | |
Eq CKey | |
Eq CMode | |
Eq CNfds | |
Eq CNlink | |
Eq COff | |
Eq CPid | |
Eq CRLim | |
Eq CSocklen | |
Eq CSpeed | |
Eq CSsize | |
Eq CTcflag | |
Eq CTimer | |
Eq CUid | |
Eq Fd | |
Eq Timeout | |
Eq Module | |
Eq Ordering | |
Eq TrName | |
Eq TyCon | |
Eq Integer | |
Eq Natural | |
Eq () | |
Eq Bool | |
Eq Char | |
Eq Double | Note that due to the presence of
Also note that
|
Eq Float | Note that due to the presence of
Also note that
|
Eq Int | |
Eq Word | |
Eq a => Eq (ZipList a) | Since: base-4.7.0.0 |
Eq (Chan a) | Since: base-4.4.0.0 |
Eq a => Eq (And a) | Since: base-4.16 |
Eq a => Eq (Iff a) | Since: base-4.16 |
Eq a => Eq (Ior a) | Since: base-4.16 |
Eq a => Eq (Xor a) | Since: base-4.16 |
Eq a => Eq (Complex a) | Since: base-2.1 |
Eq a => Eq (Identity a) | Since: base-4.8.0.0 |
Eq a => Eq (First a) | Since: base-2.1 |
Eq a => Eq (Last a) | Since: base-2.1 |
Eq a => Eq (Down a) | Since: base-4.6.0.0 |
Eq a => Eq (First a) | Since: base-4.9.0.0 |
Eq a => Eq (Last a) | Since: base-4.9.0.0 |
Eq a => Eq (Max a) | Since: base-4.9.0.0 |
Eq a => Eq (Min a) | Since: base-4.9.0.0 |
Eq m => Eq (WrappedMonoid m) | Since: base-4.9.0.0 |
Defined in Data.Semigroup (==) :: WrappedMonoid m -> WrappedMonoid m -> Bool # (/=) :: WrappedMonoid m -> WrappedMonoid m -> Bool # | |
Eq a => Eq (Dual a) | Since: base-2.1 |
Eq a => Eq (Product a) | Since: base-2.1 |
Eq a => Eq (Sum a) | Since: base-2.1 |
Eq (TVar a) | Since: base-4.8.0.0 |
Eq (ForeignPtr a) | Since: base-2.1 |
Defined in GHC.ForeignPtr (==) :: ForeignPtr a -> ForeignPtr a -> Bool # (/=) :: ForeignPtr a -> ForeignPtr a -> Bool # | |
Eq p => Eq (Par1 p) | Since: base-4.7.0.0 |
Eq (IORef a) | Pointer equality. Since: base-4.0.0.0 |
Eq (MVar a) | Since: base-4.1.0.0 |
Eq (FunPtr a) | |
Eq (Ptr a) | Since: base-2.1 |
Eq a => Eq (Ratio a) | Since: base-2.1 |
Eq (StablePtr a) | Since: base-2.1 |
Eq (StableName a) | Since: base-2.1 |
Defined in GHC.StableName (==) :: StableName a -> StableName a -> Bool # (/=) :: StableName a -> StableName a -> Bool # | |
Eq a => Eq (NonEmpty a) | Since: base-4.9.0.0 |
Eq a => Eq (Maybe a) | Since: base-2.1 |
Eq a => Eq (a) | |
Eq a => Eq [a] | |
(Eq a, Eq b) => Eq (Either a b) | Since: base-2.1 |
Eq (Fixed a) | Since: base-2.1 |
Eq (Proxy s) | Since: base-4.7.0.0 |
Eq a => Eq (Arg a b) | Since: base-4.9.0.0 |
Eq (TypeRep a) | Since: base-2.1 |
Eq (U1 p) | Since: base-4.9.0.0 |
Eq (V1 p) | Since: base-4.9.0.0 |
Eq (STRef s a) | Pointer equality. Since: base-2.1 |
(Eq a, Eq b) => Eq (a, b) | |
Eq a => Eq (Const a b) | Since: base-4.9.0.0 |
Eq (f a) => Eq (Ap f a) | Since: base-4.12.0.0 |
Eq (f a) => Eq (Alt f a) | Since: base-4.8.0.0 |
Eq (a :~: b) | Since: base-4.7.0.0 |
Eq (f p) => Eq (Rec1 f p) | Since: base-4.7.0.0 |
Eq (URec (Ptr ()) p) | Since: base-4.9.0.0 |
Eq (URec Char p) | Since: base-4.9.0.0 |
Eq (URec Double p) | Since: base-4.9.0.0 |
Eq (URec Float p) | |
Eq (URec Int p) | Since: base-4.9.0.0 |
Eq (URec Word p) | Since: base-4.9.0.0 |
(Eq a, Eq b, Eq c) => Eq (a, b, c) | |
(Eq1 f, Eq1 g, Eq a) => Eq (Product f g a) | Since: base-4.9.0.0 |
(Eq1 f, Eq1 g, Eq a) => Eq (Sum f g a) | Since: base-4.9.0.0 |
Eq (a :~~: b) | Since: base-4.10.0.0 |
(Eq (f p), Eq (g p)) => Eq ((f :*: g) p) | Since: base-4.7.0.0 |
(Eq (f p), Eq (g p)) => Eq ((f :+: g) p) | Since: base-4.7.0.0 |
Eq c => Eq (K1 i c p) | Since: base-4.7.0.0 |
(Eq a, Eq b, Eq c, Eq d) => Eq (a, b, c, d) | |
(Eq1 f, Eq1 g, Eq a) => Eq (Compose f g a) | Since: base-4.9.0.0 |
Eq (f (g p)) => Eq ((f :.: g) p) | Since: base-4.7.0.0 |
Eq (f p) => Eq (M1 i c f p) | Since: base-4.7.0.0 |
(Eq a, Eq b, Eq c, Eq d, Eq e) => Eq (a, b, c, d, e) | |
(Eq a, Eq b, Eq c, Eq d, Eq e, Eq f) => Eq (a, b, c, d, e, f) | |
(Eq a, Eq b, Eq c, Eq d, Eq e, Eq f, Eq g) => Eq (a, b, c, d, e, f, g) | |
(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) | |
(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) | |
(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) | |
(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) | |
(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) | |
(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) | |
(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) | |
(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) | |
class 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
(**) :: a -> a -> a infixr 8 #
computes log1p
x
, but provides more precise
results for small (absolute) values of log
(1 + x)x
if possible.
Since: base-4.9.0.0
computes expm1
x
, but provides more precise
results for small (absolute) values of exp
x - 1x
if possible.
Since: base-4.9.0.0
Instances
Floating CDouble | |
Floating CFloat | |
Floating Double | Since: base-2.1 |
Floating Float | Since: base-2.1 |
RealFloat a => Floating (Complex a) | Since: base-2.1 |
Defined in Data.Complex exp :: Complex a -> Complex a # log :: Complex a -> Complex a # sqrt :: Complex a -> Complex a # (**) :: Complex a -> Complex a -> Complex a # logBase :: Complex a -> Complex a -> Complex a # sin :: Complex a -> Complex a # cos :: Complex a -> Complex a # tan :: Complex a -> Complex a # asin :: Complex a -> Complex a # acos :: Complex a -> Complex a # atan :: Complex a -> Complex a # sinh :: Complex a -> Complex a # cosh :: Complex a -> Complex a # tanh :: Complex a -> Complex a # |