Safe Haskell | Trustworthy |
---|---|
Language | Haskell2010 |
Space-efficient deques with amortized \( O(\log n) \) operations. These directly use an underlying array-based implementation, without doing any special optimization for the first few and last few elements of the deque.
Synopsis
Documentation
A deque.
pattern Empty :: Deque a | A bidirectional pattern synonym for the empty deque. |
pattern (:<) :: a -> Deque a -> Deque a infixr 5 | A bidirectional pattern synonym for manipulating the front of a deque. |
pattern (:>) :: Deque a -> a -> Deque a | A bidirectional pattern synonym for manipulating the rear of a deque. |
Instances
Functor Deque Source # | |
Foldable Deque Source # | |
Defined in Data.CompactSequence.Deque.Simple.Internal fold :: Monoid m => Deque m -> m # foldMap :: Monoid m => (a -> m) -> Deque a -> m # foldr :: (a -> b -> b) -> b -> Deque a -> b # foldr' :: (a -> b -> b) -> b -> Deque a -> b # foldl :: (b -> a -> b) -> b -> Deque a -> b # foldl' :: (b -> a -> b) -> b -> Deque a -> b # foldr1 :: (a -> a -> a) -> Deque a -> a # foldl1 :: (a -> a -> a) -> Deque a -> a # elem :: Eq a => a -> Deque a -> Bool # maximum :: Ord a => Deque a -> a # minimum :: Ord a => Deque a -> a # | |
Traversable Deque Source # | |
IsList (Deque a) Source # | |
Eq a => Eq (Deque a) Source # | |
Ord a => Ord (Deque a) Source # | |
Defined in Data.CompactSequence.Deque.Simple.Internal | |
Show a => Show (Deque a) Source # | |
Semigroup (Deque a) Source # | |
Monoid (Deque a) Source # | |
type Item (Deque a) Source # | |
Defined in Data.CompactSequence.Deque.Simple.Internal |