Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell2010 |
This module contains strict versions of some standard data structures.
Synopsis
- data List a
- singleton :: a -> List a
- class IsList l where
- init' :: List a -> List a
- reverse' :: List a -> List a
- union' :: Eq a => List a -> List a -> List a
- unionBy' :: (a -> a -> Bool) -> List a -> List a -> List a
- nub' :: Eq a => List a -> List a
- nubBy' :: (a -> a -> Bool) -> List a -> List a
- filter' :: (a -> Bool) -> List a -> List a
- delete' :: Eq a => a -> List a -> List a
- deleteBy' :: (a -> a -> Bool) -> a -> List a -> List a
- (+++) :: List a -> List a -> List a
- listToMaybe' :: List a -> Maybe' a
- map' :: (a -> b) -> List a -> List b
- zip' :: List a -> List b -> List (a :* b)
- zipWith' :: (a -> b -> c) -> List a -> List b -> List c
- mapMaybe' :: (a -> Maybe' b) -> List a -> List b
- data a :* b = !a :* !b
- data Maybe' a
- maybe' :: b -> (a -> b) -> Maybe' a -> b
- fromMaybe' :: a -> Maybe' a -> a
- fst' :: (a :* b) -> a
- snd' :: (a :* b) -> b
- curry' :: ((a :* b) -> c) -> a -> b -> c
- uncurry' :: (a -> b -> c) -> (a :* b) -> c
Documentation
Strict list type.
Instances
Foldable List Source # | |
Defined in AsyncRattus.Strict fold :: Monoid m => List m -> m # foldMap :: Monoid m => (a -> m) -> List a -> m # foldMap' :: Monoid m => (a -> m) -> List a -> m # foldr :: (a -> b -> b) -> b -> List a -> b # foldr' :: (a -> b -> b) -> b -> List a -> b # foldl :: (b -> a -> b) -> b -> List a -> b # foldl' :: (b -> a -> b) -> b -> List a -> b # foldr1 :: (a -> a -> a) -> List a -> a # foldl1 :: (a -> a -> a) -> List a -> a # elem :: Eq a => a -> List a -> Bool # maximum :: Ord a => List a -> a # | |
Traversable List Source # | |
Functor List Source # | |
Continuous a => Continuous (List a) Source # | |
Defined in AsyncRattus.Strict progressAndNext :: InputValue -> List a -> (List a, Clock) Source # progressInternal :: InputValue -> List a -> List a Source # nextProgress :: List a -> Clock Source # | |
IsList (List a) Source # | |
Show a => Show (List a) Source # | |
Eq a => Eq (List a) Source # | |
type Item (List a) Source # | |
Defined in AsyncRattus.Strict |
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
init' :: List a -> List a Source #
Remove the last element from a list if there is one, otherwise
return Nil
.
listToMaybe' :: List a -> Maybe' a Source #
Strict pair type.
!a :* !b infixr 2 |
Instances
Functor ((:*) a) Source # | |
(Continuous a, Continuous b) => Continuous (a :* b) Source # | |
Defined in AsyncRattus.Strict progressAndNext :: InputValue -> (a :* b) -> (a :* b, Clock) Source # progressInternal :: InputValue -> (a :* b) -> a :* b Source # nextProgress :: (a :* b) -> Clock Source # | |
(Show a, Show b) => Show (a :* b) Source # | |
(Eq a, Eq b) => Eq (a :* b) Source # | |
(VectorSpace v a, VectorSpace w a, Floating a, Eq a) => VectorSpace (v :* w) a Source # | |
Defined in AsyncRattus.Strict |
Strict variant of Maybe
.
Instances
Continuous a => Continuous (Maybe' a) Source # | |
Defined in AsyncRattus.Strict progressAndNext :: InputValue -> Maybe' a -> (Maybe' a, Clock) Source # progressInternal :: InputValue -> Maybe' a -> Maybe' a Source # nextProgress :: Maybe' a -> Clock Source # | |
Show a => Show (Maybe' a) Source # | |
Eq a => Eq (Maybe' a) Source # | |
fromMaybe' :: a -> Maybe' a -> a Source #