Hoogle Search
Within LTS Haskell 24.28 (ghc-9.10.3)
Note that Stackage only displays results for the latest LTS and Nightly snapshot. Learn more.
fromList :: Ord k => [(k, v)] -> v -> SF k vstep-function Data.Function.Step.Discrete.Open Create function from list of cases and default value.
>>> putSF $ fromList [(1,2),(3,4)] 5 \x -> if | x < 1 -> 2 | x < 3 -> 4 | otherwise -> 5
>>> map (fromList [(1,2),(3,4)] 5 !) [0..10] [2,4,4,5,5,5,5,5,5,5,5]
fromList :: Unbox a => [a] -> Array astreamly Streamly.Data.Array.Foreign Create an Array from a list. The list must be of finite size.
fromListN :: Unbox a => Int -> [a] -> Array astreamly Streamly.Data.Array.Foreign Create an Array from the first N elements of a list. The array is allocated to size N, if the list terminates before N elements then the array may hold less than N elements.
toList :: Unbox a => Array a -> [a]streamly Streamly.Data.Array.Foreign Convert an Array into a list.
-
streamly Streamly.Data.Stream.MkType The IsList class and its methods are intended to be used in conjunction with the OverloadedLists extension.
readList :: Read a => ReadS [a]streamly Streamly.Data.Stream.MkType 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.
readListPrec :: Read a => ReadPrec [a]streamly Streamly.Data.Stream.MkType Proposed replacement for readList using new-style parsers (GHC only). The default definition uses readList. Instances that define readPrec should also define readListPrec as readListPrecDefault.
-
streamly Streamly.Data.Stream.Prelude Like parConcat but works on a list of streams.
>>> parList modifier = Stream.parConcat modifier . Stream.fromList
contListMap :: (a -> (b -> r) -> r) -> ([b] -> (c -> r) -> r) -> [a] -> (c -> r) -> rstreamly Streamly.Internal.Data.Cont Given a continuation based transformation from a to b and a continuation based transformation from [b] to c, make continuation based transformation from [a] to c. Pre-release
fromList :: forall (m :: Type -> Type) t a . (Monad m, IsStream t) => [a] -> t m astreamly Streamly.Internal.Data.Stream.IsStream fromList = foldr cons nil
Construct a stream from a list of pure values. This is more efficient than fromFoldable for serial streams.