-- Hoogle documentation, generated by Haddock
-- See Hoogle, http://www.haskell.org/hoogle/


-- | Advanced keyboard remapping utility
--   
--   KMonad is a cross-platform command-line utility that runs as a daemon.
--   It captures keyboard input (exactly how depends on the OS) and remaps
--   it. The mapping is highly configurable, and provides options like
--   (transparent) layer overlays, tap-mod buttons, multi-tap buttons,
--   leader-key style buttons, and keyboard macros. Functionality heavily
--   inspired by the QMK-firmware.
@package kmonad
@version 0.4.4

module KMonad.Prelude.Imports
deepseq :: NFData a => a -> b -> b
class Monad m => PrimMonad (m :: Type -> Type) where {
    type PrimState (m :: Type -> Type);
}
primitive :: PrimMonad m => (State# (PrimState m) -> (# State# (PrimState m), a #)) -> m a
async :: MonadUnliftIO m => m a -> m (Async a)
strict :: Strict lazy strict => Iso' lazy strict
void :: Functor f => f a -> f ()
lens :: (s -> a) -> (s -> b -> t) -> Lens s t a b
data NonEmpty a
(:|) :: a -> [a] -> NonEmpty a
newtype RIO env a
RIO :: ReaderT env IO a -> RIO env a
[unRIO] :: RIO env a -> ReaderT env IO a
newtype UnliftIO (m :: Type -> Type)
UnliftIO :: (forall a. () => m a -> IO a) -> UnliftIO (m :: Type -> Type)
[unliftIO] :: UnliftIO (m :: Type -> Type) -> forall a. () => m a -> IO a
label :: MonadCont m => a -> m (a -> m b, a)
(.) :: (b -> c) -> (a -> b) -> a -> c
data Handler (m :: Type -> Type) a
Handler :: (e -> m a) -> Handler (m :: Type -> Type) a
class Num a
(+) :: Num a => a -> a -> a
(-) :: Num a => a -> a -> a
(*) :: Num a => a -> a -> a
negate :: Num a => a -> a
abs :: Num a => a -> a
signum :: Num a => a -> a
fromInteger :: Num a => Integer -> a
data IO a
try :: (MonadUnliftIO m, Exception e) => m a -> m (Either e a)
class Typeable a => Data a
gfoldl :: Data a => (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. () => g -> c g) -> a -> c a
gunfold :: Data a => (forall b r. Data b => c (b -> r) -> c r) -> (forall r. () => r -> c r) -> Constr -> c a
toConstr :: Data a => a -> Constr
dataTypeOf :: Data a => a -> DataType
dataCast1 :: (Data a, Typeable t) => (forall d. Data d => c (t d)) -> Maybe (c a)
dataCast2 :: (Data a, Typeable t) => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c a)
gmapT :: Data a => (forall b. Data b => b -> b) -> a -> a
gmapQl :: Data a => (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> a -> r
gmapQr :: forall r r'. Data a => (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> a -> r
gmapQ :: Data a => (forall d. Data d => d -> u) -> a -> [u]
gmapQi :: Data a => Int -> (forall d. Data d => d -> u) -> a -> u
gmapM :: (Data a, Monad m) => (forall d. Data d => d -> m d) -> a -> m a
gmapMp :: (Data a, MonadPlus m) => (forall d. Data d => d -> m d) -> a -> m a
gmapMo :: (Data a, MonadPlus m) => (forall d. Data d => d -> m d) -> a -> m a
class Functor f => Applicative (f :: Type -> Type)
pure :: Applicative f => a -> f a
(<*>) :: Applicative f => f (a -> b) -> f a -> f b
liftA2 :: Applicative f => (a -> b -> c) -> f a -> f b -> f c
(*>) :: Applicative f => f a -> f b -> f b
(<*) :: Applicative f => f a -> f b -> f a
bool :: a -> a -> Bool -> a
data Char
pattern List :: IsList l => [Item l] -> l
data Text
uncons :: Cons s s a a => s -> Maybe (a, s)
data HashMap k v
data Maybe a
Nothing :: Maybe a
Just :: a -> Maybe a
timeout :: MonadUnliftIO m => Int -> m a -> m (Maybe a)
data HashSet a
data Seq a
data Set a
class Storable a
class Foldable (t :: Type -> Type)
fold :: (Foldable t, Monoid m) => t m -> m
foldMap :: (Foldable t, Monoid m) => (a -> m) -> t a -> m
foldr :: Foldable t => (a -> b -> b) -> b -> t a -> b
foldl' :: Foldable t => (b -> a -> b) -> b -> t a -> b
toList :: Foldable t => t a -> [a]
null :: Foldable t => t a -> Bool
length :: Foldable t => t a -> Int
elem :: (Foldable t, Eq a) => a -> t a -> Bool
sum :: (Foldable t, Num a) => t a -> a
product :: (Foldable t, Num a) => t a -> a
orElse :: STM a -> STM a -> STM a
unlines :: [Text] -> Text
lines :: Text -> [Text]
unpack :: Text -> String
pack :: String -> Text
view :: MonadReader s m => Getting a s a -> m a
type ASetter s t a b = a -> Identity b -> s -> Identity t
type ASetter' s a = ASetter s s a a
type Lens s t a b = forall (f :: Type -> Type). Functor f => a -> f b -> s -> f t
newtype ReifiedLens s t a b
Lens :: Lens s t a b -> ReifiedLens s t a b
[runLens] :: ReifiedLens s t a b -> Lens s t a b
type Getting r s a = a -> Const r a -> s -> Const r s
type Lens' s a = Lens s s a a
over :: ASetter s t a b -> (a -> b) -> s -> t
set :: ASetter s t a b -> b -> s -> t
sets :: (Profunctor p, Profunctor q, Settable f) => (p a b -> q s t) -> Optical p q f s t a b
to :: (Profunctor p, Contravariant f) => (s -> a) -> Optic' p f s a
type Cont r = ContT r Identity
data Acquire a
data Conc (m :: Type -> Type) a
(^.) :: s -> Getting a s a -> a
(^..) :: s -> Getting (Endo [a]) s a -> [a]
(^?) :: s -> Getting (First a) s a -> Maybe a
preview :: MonadReader s m => Getting (First a) s a -> m (Maybe a)
(%~) :: ASetter s t a b -> (a -> b) -> s -> t
(.~) :: ASetter s t a b -> b -> s -> t
reverse :: [a] -> [a]
class (Typeable e, Show e) => Exception e
toException :: Exception e => e -> SomeException
fromException :: Exception e => SomeException -> Maybe e
displayException :: Exception e => e -> String
catchIO :: MonadUnliftIO m => m a -> (IOException -> m a) -> m a
data ByteString
type String = [Char]
data Async a
class Ixed m => At m
at :: At m => Index m -> Lens' m (Maybe (IxValue m))
class Contains m
contains :: Contains m => Index m -> Lens' m Bool
type family Index s
type family IxValue m
class Ixed m
ix :: Ixed m => Index m -> Traversal' m (IxValue m)
iat :: At m => Index m -> IndexedLens' (Index m) m (Maybe (IxValue m))
icontains :: Contains m => Index m -> IndexedLens' (Index m) m Bool
iix :: Ixed m => Index m -> IndexedTraversal' (Index m) m (IxValue m)
ixAt :: At m => Index m -> Traversal' m (IxValue m)
sans :: At m => Index m -> m -> m
pattern (:<) :: Cons b b a a => a -> b -> b
pattern (:>) :: Snoc a a b b => a -> b -> a
(<<<|=) :: (MonadState s m, Cons b b a a) => LensLike ((,) b) s s b b -> a -> m b
(<<<|~) :: Cons b b a a => LensLike' ((,) b) s b -> a -> s -> (b, s)
(<<|=) :: (MonadState s m, Cons b b a a) => LensLike ((,) b) s s b b -> a -> m b
(<<|>=) :: (MonadState s m, Snoc b b p p) => LensLike ((,) b) s s b b -> p -> m b
(<<|>~) :: Snoc b b p p => LensLike' ((,) b) s b -> p -> s -> (b, s)
(<<|~) :: Cons b b a a => LensLike ((,) b) s t b b -> a -> s -> (b, t)
(<|) :: Cons s s a a => a -> s -> s
(<|=) :: (MonadState s m, Cons b b a a) => ASetter s s b b -> a -> m ()
(<|>=) :: (MonadState s m, Snoc b b p p) => LensLike ((,) b) s s b b -> p -> m b
(<|>~) :: Snoc b b p p => LensLike ((,) b) s t b b -> p -> s -> (b, t)
(<|~) :: Cons b b a a => ASetter s t b b -> a -> s -> t
class Cons s t a b | s -> a, t -> b, s b -> t, t a -> s
_Cons :: Cons s t a b => Prism s t (a, s) (b, t)
class Snoc s t a b | s -> a, t -> b, s b -> t, t a -> s
_Snoc :: Snoc s t a b => Prism s t (s, a) (t, b)
_head :: Cons s s a a => Traversal' s a
_init :: Snoc s s a a => Traversal' s s
_last :: Snoc s s a a => Traversal' s a
_tail :: Cons s s a a => Traversal' s s
cons :: Cons s s a a => a -> s -> s
snoc :: Snoc s s a a => s -> a -> s
unsnoc :: Snoc s s a a => s -> Maybe (s, a)
(|>) :: Snoc s s a a => s -> a -> s
(|>=) :: (MonadState s m, Snoc b b a a) => ASetter s s b b -> a -> m ()
(|>~) :: Snoc b b a a => ASetter s t b b -> a -> s -> t
class Each s t a b | s -> a, t -> b, s b -> t, t a -> s
each :: Each s t a b => Traversal s t a b
class AsEmpty a
_Empty :: AsEmpty a => Prism' a ()
pattern Empty :: AsEmpty s => s
type AnEquality (s :: k) (t :: k1) (a :: k) (b :: k2) = Identical a Proxy b a Proxy b -> Identical a Proxy b s Proxy t
type AnEquality' (s :: k) (a :: k) = AnEquality s s a a
data Identical (a :: k) (b :: k1) (s :: k) (t :: k1)
[Identical] :: forall {k} {k1} (a :: k) (b :: k1). Identical a b a b
cloneEquality :: forall {k1} {k2} (s :: k1) (t :: k2) (a :: k1) (b :: k2). AnEquality s t a b -> Equality s t a b
equality :: forall {k1} {k2} (s :: k1) (a :: k1) (b :: k2) (t :: k2). (s :~: a) -> (b :~: t) -> Equality s t a b
equality' :: forall {k2} (a :: k2) (b :: k2). (a :~: b) -> Equality' a b
fromEq :: forall {k2} {k1} (s :: k2) (t :: k1) (a :: k2) (b :: k1). AnEquality s t a b -> Equality b a t s
fromLeibniz :: forall {k1} {k2} (a :: k1) (b :: k2) (s :: k1) (t :: k2). (Identical a b a b -> Identical a b s t) -> Equality s t a b
fromLeibniz' :: forall {k2} (s :: k2) (a :: k2). ((s :~: s) -> s :~: a) -> Equality' s a
mapEq :: forall k1 k2 (s :: k1) (t :: k2) (a :: k1) (b :: k2) f. AnEquality s t a b -> f s -> f a
overEquality :: forall {k1} {k2} (s :: k1) (t :: k2) (a :: k1) (b :: k2) p. AnEquality s t a b -> p a b -> p s t
runEq :: forall {k1} {k2} (s :: k1) (t :: k2) (a :: k1) (b :: k2). AnEquality s t a b -> Identical s t a b
simple :: forall {k2} (a :: k2) k3 p (f :: k2 -> k3). p a (f a) -> p a (f a)
simply :: forall {k} {k1} p (f :: k -> k1) (s :: k) (a :: k) r. (Optic' p f s a -> r) -> Optic' p f s a -> r
substEq :: forall {k1} {k2} (s :: k1) (t :: k2) (a :: k1) (b :: k2) r. AnEquality s t a b -> ((s ~ a, t ~ b) => r) -> r
underEquality :: forall {k1} {k2} (s :: k1) (t :: k2) (a :: k1) (b :: k2) p. AnEquality s t a b -> p t s -> p b a
withEquality :: forall {k1} {k2} (s :: k1) (t :: k2) (a :: k1) (b :: k2) r. AnEquality s t a b -> ((s :~: a) -> (b :~: t) -> r) -> r
(^?!) :: HasCallStack => s -> Getting (Endo a) s a -> a
(^@..) :: s -> IndexedGetting i (Endo [(i, a)]) s a -> [(i, a)]
(^@?) :: s -> IndexedGetting i (Endo (Maybe (i, a))) s a -> Maybe (i, a)
(^@?!) :: HasCallStack => s -> IndexedGetting i (Endo (i, a)) s a -> (i, a)
allOf :: Getting All s a -> (a -> Bool) -> s -> Bool
altOf :: Applicative f => Getting (Alt f a) s a -> s -> f a
andOf :: Getting All s Bool -> s -> Bool
anyOf :: Getting Any s a -> (a -> Bool) -> s -> Bool
asumOf :: Alternative f => Getting (Endo (f a)) s (f a) -> s -> f a
backwards :: (Profunctor p, Profunctor q) => Optical p q (Backwards f) s t a b -> Optical p q f s t a b
concatMapOf :: Getting [r] s a -> (a -> [r]) -> s -> [r]
concatOf :: Getting [r] s [r] -> s -> [r]
cycled :: Apply f => LensLike f s t a b -> LensLike f s t a b
droppingWhile :: (Conjoined p, Profunctor q, Applicative f) => (a -> Bool) -> Optical p q (Compose (State Bool) f) s t a a -> Optical p q f s t a a
elemIndexOf :: Eq a => IndexedGetting i (First i) s a -> a -> s -> Maybe i
elemIndicesOf :: Eq a => IndexedGetting i (Endo [i]) s a -> a -> s -> [i]
elemOf :: Eq a => Getting Any s a -> a -> s -> Bool
filtered :: (Choice p, Applicative f) => (a -> Bool) -> Optic' p f a a
filteredBy :: (Indexable i p, Applicative f) => Getting (First i) a i -> p a (f a) -> a -> f a
findIndexOf :: IndexedGetting i (First i) s a -> (a -> Bool) -> s -> Maybe i
findIndicesOf :: IndexedGetting i (Endo [i]) s a -> (a -> Bool) -> s -> [i]
findMOf :: Monad m => Getting (Endo (m (Maybe a))) s a -> (a -> m Bool) -> s -> m (Maybe a)
findOf :: Getting (Endo (Maybe a)) s a -> (a -> Bool) -> s -> Maybe a
first1Of :: Getting (First a) s a -> s -> a
firstOf :: Getting (Leftmost a) s a -> s -> Maybe a
foldByOf :: Fold s a -> (a -> a -> a) -> a -> s -> a
foldMapByOf :: Fold s a -> (r -> r -> r) -> r -> (a -> r) -> s -> r
foldMapOf :: Getting r s a -> (a -> r) -> s -> r
foldOf :: Getting a s a -> s -> a
folded :: forall (f :: Type -> Type) a. Foldable f => IndexedFold Int (f a) a
folded64 :: forall (f :: Type -> Type) a. Foldable f => IndexedFold Int64 (f a) a
folding :: Foldable f => (s -> f a) -> Fold s a
foldl1Of :: HasCallStack => Getting (Dual (Endo (Maybe a))) s a -> (a -> a -> a) -> s -> a
foldl1Of' :: HasCallStack => Getting (Endo (Endo (Maybe a))) s a -> (a -> a -> a) -> s -> a
foldlMOf :: Monad m => Getting (Endo (r -> m r)) s a -> (r -> a -> m r) -> r -> s -> m r
foldlOf :: Getting (Dual (Endo r)) s a -> (r -> a -> r) -> r -> s -> r
foldlOf' :: Getting (Endo (Endo r)) s a -> (r -> a -> r) -> r -> s -> r
foldr1Of :: HasCallStack => Getting (Endo (Maybe a)) s a -> (a -> a -> a) -> s -> a
foldr1Of' :: HasCallStack => Getting (Dual (Endo (Endo (Maybe a)))) s a -> (a -> a -> a) -> s -> a
foldrMOf :: Monad m => Getting (Dual (Endo (r -> m r))) s a -> (a -> r -> m r) -> r -> s -> m r
foldrOf :: Getting (Endo r) s a -> (a -> r -> r) -> r -> s -> r
foldrOf' :: Getting (Dual (Endo (Endo r))) s a -> (a -> r -> r) -> r -> s -> r
foldring :: (Contravariant f, Applicative f) => ((a -> f a -> f a) -> f a -> s -> f a) -> LensLike f s t a b
for1Of_ :: Functor f => Getting (TraversedF r f) s a -> s -> (a -> f r) -> f ()
forMOf_ :: Monad m => Getting (Sequenced r m) s a -> s -> (a -> m r) -> m ()
forOf_ :: Functor f => Getting (Traversed r f) s a -> s -> (a -> f r) -> f ()
has :: Getting Any s a -> s -> Bool
hasn't :: Getting All s a -> s -> Bool
iallOf :: IndexedGetting i All s a -> (i -> a -> Bool) -> s -> Bool
ianyOf :: IndexedGetting i Any s a -> (i -> a -> Bool) -> s -> Bool
iconcatMapOf :: IndexedGetting i [r] s a -> (i -> a -> [r]) -> s -> [r]
idroppingWhile :: (Indexable i p, Profunctor q, Applicative f) => (i -> a -> Bool) -> Optical (Indexed i) q (Compose (State Bool) f) s t a a -> Optical p q f s t a a
ifiltered :: (Indexable i p, Applicative f) => (i -> a -> Bool) -> Optical' p (Indexed i) f a a
ifindMOf :: Monad m => IndexedGetting i (Endo (m (Maybe a))) s a -> (i -> a -> m Bool) -> s -> m (Maybe a)
ifindOf :: IndexedGetting i (Endo (Maybe a)) s a -> (i -> a -> Bool) -> s -> Maybe a
ifoldMapOf :: IndexedGetting i m s a -> (i -> a -> m) -> s -> m
ifolding :: (Foldable f, Indexable i p, Contravariant g, Applicative g) => (s -> f (i, a)) -> Over p g s t a b
ifoldlMOf :: Monad m => IndexedGetting i (Endo (r -> m r)) s a -> (i -> r -> a -> m r) -> r -> s -> m r
ifoldlOf :: IndexedGetting i (Dual (Endo r)) s a -> (i -> r -> a -> r) -> r -> s -> r
ifoldlOf' :: IndexedGetting i (Endo (r -> r)) s a -> (i -> r -> a -> r) -> r -> s -> r
ifoldrMOf :: Monad m => IndexedGetting i (Dual (Endo (r -> m r))) s a -> (i -> a -> r -> m r) -> r -> s -> m r
ifoldrOf :: IndexedGetting i (Endo r) s a -> (i -> a -> r -> r) -> r -> s -> r
ifoldrOf' :: IndexedGetting i (Dual (Endo (r -> r))) s a -> (i -> a -> r -> r) -> r -> s -> r
ifoldring :: (Indexable i p, Contravariant f, Applicative f) => ((i -> a -> f a -> f a) -> f a -> s -> f a) -> Over p f s t a b
iforMOf_ :: Monad m => IndexedGetting i (Sequenced r m) s a -> s -> (i -> a -> m r) -> m ()
iforOf_ :: Functor f => IndexedGetting i (Traversed r f) s a -> s -> (i -> a -> f r) -> f ()
imapMOf_ :: Monad m => IndexedGetting i (Sequenced r m) s a -> (i -> a -> m r) -> s -> m ()
inoneOf :: IndexedGetting i Any s a -> (i -> a -> Bool) -> s -> Bool
ipre :: IndexedGetting i (First (i, a)) s a -> IndexPreservingGetter s (Maybe (i, a))
ipreuse :: MonadState s m => IndexedGetting i (First (i, a)) s a -> m (Maybe (i, a))
ipreuses :: MonadState s m => IndexedGetting i (First r) s a -> (i -> a -> r) -> m (Maybe r)
ipreview :: MonadReader s m => IndexedGetting i (First (i, a)) s a -> m (Maybe (i, a))
ipreviews :: MonadReader s m => IndexedGetting i (First r) s a -> (i -> a -> r) -> m (Maybe r)
itakingWhile :: (Indexable i p, Profunctor q, Contravariant f, Applicative f) => (i -> a -> Bool) -> Optical' (Indexed i) q (Const (Endo (f s)) :: Type -> Type) s a -> Optical' p q f s a
iterated :: Apply f => (a -> a) -> LensLike' f a a
itoListOf :: IndexedGetting i (Endo [(i, a)]) s a -> s -> [(i, a)]
itraverseOf_ :: Functor f => IndexedGetting i (Traversed r f) s a -> (i -> a -> f r) -> s -> f ()
last1Of :: Getting (Last a) s a -> s -> a
lastOf :: Getting (Rightmost a) s a -> s -> Maybe a
lengthOf :: Getting (Endo (Endo Int)) s a -> s -> Int
lined :: forall (f :: Type -> Type). Applicative f => IndexedLensLike' Int f String String
lookupOf :: Eq k => Getting (Endo (Maybe v)) s (k, v) -> k -> s -> Maybe v
mapMOf_ :: Monad m => Getting (Sequenced r m) s a -> (a -> m r) -> s -> m ()
maximum1Of :: Ord a => Getting (Max a) s a -> s -> a
maximumByOf :: Getting (Endo (Endo (Maybe a))) s a -> (a -> a -> Ordering) -> s -> Maybe a
maximumOf :: Ord a => Getting (Endo (Endo (Maybe a))) s a -> s -> Maybe a
minimum1Of :: Ord a => Getting (Min a) s a -> s -> a
minimumByOf :: Getting (Endo (Endo (Maybe a))) s a -> (a -> a -> Ordering) -> s -> Maybe a
minimumOf :: Ord a => Getting (Endo (Endo (Maybe a))) s a -> s -> Maybe a
msumOf :: MonadPlus m => Getting (Endo (m a)) s (m a) -> s -> m a
noneOf :: Getting Any s a -> (a -> Bool) -> s -> Bool
notElemOf :: Eq a => Getting All s a -> a -> s -> Bool
notNullOf :: Getting Any s a -> s -> Bool
nullOf :: Getting All s a -> s -> Bool
orOf :: Getting Any s Bool -> s -> Bool
pre :: Getting (First a) s a -> IndexPreservingGetter s (Maybe a)
preuse :: MonadState s m => Getting (First a) s a -> m (Maybe a)
preuses :: MonadState s m => Getting (First r) s a -> (a -> r) -> m (Maybe r)
previews :: MonadReader s m => Getting (First r) s a -> (a -> r) -> m (Maybe r)
productOf :: Num a => Getting (Endo (Endo a)) s a -> s -> a
repeated :: Apply f => LensLike' f a a
replicated :: Int -> Fold a a
sequence1Of_ :: Functor f => Getting (TraversedF a f) s (f a) -> s -> f ()
sequenceAOf_ :: Functor f => Getting (Traversed a f) s (f a) -> s -> f ()
sequenceOf_ :: Monad m => Getting (Sequenced a m) s (m a) -> s -> m ()
sumOf :: Num a => Getting (Endo (Endo a)) s a -> s -> a
takingWhile :: (Conjoined p, Applicative f) => (a -> Bool) -> Over p (TakingWhile p f a a) s t a a -> Over p f s t a a
toListOf :: Getting (Endo [a]) s a -> s -> [a]
toNonEmptyOf :: Getting (NonEmptyDList a) s a -> s -> NonEmpty a
traverse1Of_ :: Functor f => Getting (TraversedF r f) s a -> (a -> f r) -> s -> f ()
traverseOf_ :: Functor f => Getting (Traversed r f) s a -> (a -> f r) -> s -> f ()
unfolded :: (b -> Maybe (a, b)) -> Fold b a
worded :: forall (f :: Type -> Type). Applicative f => IndexedLensLike' Int f String String
type Accessing (p :: Type -> Type -> Type) m s a = p a Const m a -> s -> Const m s
type IndexedGetting i m s a = Indexed i a Const m a -> s -> Const m s
(^@.) :: s -> IndexedGetting i (i, a) s a -> (i, a)
getting :: (Profunctor p, Profunctor q, Functor f, Contravariant f) => Optical p q f s t a b -> Optical' p q f s a
ilike :: (Indexable i p, Contravariant f, Functor f) => i -> a -> Over' p f s a
ilistening :: MonadWriter w m => IndexedGetting i (i, u) w u -> m a -> m (a, (i, u))
ilistenings :: MonadWriter w m => IndexedGetting i v w u -> (i -> u -> v) -> m a -> m (a, v)
ito :: (Indexable i p, Contravariant f) => (s -> (i, a)) -> Over' p f s a
iuse :: MonadState s m => IndexedGetting i (i, a) s a -> m (i, a)
iuses :: MonadState s m => IndexedGetting i r s a -> (i -> a -> r) -> m r
iview :: MonadReader s m => IndexedGetting i (i, a) s a -> m (i, a)
iviews :: MonadReader s m => IndexedGetting i r s a -> (i -> a -> r) -> m r
like :: (Profunctor p, Contravariant f, Functor f) => a -> Optic' p f s a
listening :: MonadWriter w m => Getting u w u -> m a -> m (a, u)
listenings :: MonadWriter w m => Getting v w u -> (u -> v) -> m a -> m (a, v)
use :: MonadState s m => Getting a s a -> m a
uses :: MonadState s m => LensLike' (Const r :: Type -> Type) s a -> (a -> r) -> m r
views :: MonadReader s m => LensLike' (Const r :: Type -> Type) s a -> (a -> r) -> m r
(.>) :: (st -> r) -> (kab -> st) -> kab -> r
(<.) :: Indexable i p => (Indexed i s t -> r) -> ((a -> b) -> s -> t) -> p a b -> r
(<.>) :: Indexable (i, j) p => (Indexed i s t -> r) -> (Indexed j a b -> s -> t) -> p a b -> r
icompose :: Indexable p c => (i -> j -> p) -> (Indexed i s t -> r) -> (Indexed j a b -> s -> t) -> c a b -> r
ifoldMapBy :: FoldableWithIndex i t => (r -> r -> r) -> r -> (i -> a -> r) -> t a -> r
ifoldMapByOf :: IndexedFold i t a -> (r -> r -> r) -> r -> (i -> a -> r) -> t -> r
ifolded :: forall i (f :: Type -> Type) a. FoldableWithIndex i f => IndexedFold i (f a) a
imapped :: forall i (f :: Type -> Type) a b. FunctorWithIndex i f => IndexedSetter i (f a) (f b) a b
index :: (Indexable i p, Eq i, Applicative f) => i -> Optical' p (Indexed i) f a a
indices :: (Indexable i p, Applicative f) => (i -> Bool) -> Optical' p (Indexed i) f a a
itraverseBy :: TraversableWithIndex i t => (forall x. () => x -> f x) -> (forall x y. () => f (x -> y) -> f x -> f y) -> (i -> a -> f b) -> t a -> f (t b)
itraverseByOf :: IndexedTraversal i s t a b -> (forall x. () => x -> f x) -> (forall x y. () => f (x -> y) -> f x -> f y) -> (i -> a -> f b) -> s -> f t
itraversed :: forall i (t :: Type -> Type) a b. TraversableWithIndex i t => IndexedTraversal i (t a) (t b) a b
reindexed :: Indexable j p => (i -> j) -> (Indexed i a b -> r) -> p a b -> r
selfIndex :: Indexable a p => p a fb -> a -> fb
newtype Bazaar (p :: Type -> Type -> Type) a b t
Bazaar :: (forall (f :: Type -> Type). Applicative f => p a (f b) -> f t) -> Bazaar (p :: Type -> Type -> Type) a b t
[runBazaar] :: Bazaar (p :: Type -> Type -> Type) a b t -> forall (f :: Type -> Type). Applicative f => p a (f b) -> f t
type Bazaar' (p :: Type -> Type -> Type) a = Bazaar p a a
newtype Bazaar1 (p :: Type -> Type -> Type) a b t
Bazaar1 :: (forall (f :: Type -> Type). Apply f => p a (f b) -> f t) -> Bazaar1 (p :: Type -> Type -> Type) a b t
[runBazaar1] :: Bazaar1 (p :: Type -> Type -> Type) a b t -> forall (f :: Type -> Type). Apply f => p a (f b) -> f t
type Bazaar1' (p :: Type -> Type -> Type) a = Bazaar1 p a a
data Context a b t
Context :: (b -> t) -> a -> Context a b t
type Context' a = Context a a
type ClassyNamer = Name -> Maybe (Name, Name)
data DefName
TopName :: Name -> DefName
MethodName :: Name -> Name -> DefName
type FieldNamer = Name -> [Name] -> Name -> [DefName]
data LensRules
data Leftmost a
data Rightmost a
data Sequenced a (m :: Type -> Type)
data Traversed a (f :: Type -> Type)
class (Choice p, Corepresentable p, Comonad Corep p, Traversable Corep p, Strong p, Representable p, Monad Rep p, MonadFix Rep p, Distributive Rep p, Costrong p, ArrowLoop p, ArrowApply p, ArrowChoice p, Closed p) => Conjoined (p :: Type -> Type -> Type)
distrib :: (Conjoined p, Functor f) => p a b -> p (f a) (f b)
conjoined :: Conjoined p => (p ~ (->) => q (a -> b) r) -> q (p a b) r -> q (p a b) r
class Conjoined p => Indexable i (p :: Type -> Type -> Type)
indexed :: Indexable i p => p a b -> i -> a -> b
newtype Indexed i a b
Indexed :: (i -> a -> b) -> Indexed i a b
[runIndexed] :: Indexed i a b -> i -> a -> b
asIndex :: (Indexable i p, Contravariant f, Functor f) => p i (f i) -> Indexed i s (f s)
indexing :: Indexable Int p => ((a -> Indexing f b) -> s -> Indexing f t) -> p a (f b) -> s -> f t
indexing64 :: Indexable Int64 p => ((a -> Indexing64 f b) -> s -> Indexing64 f t) -> p a (f b) -> s -> f t
withIndex :: (Indexable i p, Functor f) => p (i, s) (f (j, t)) -> Indexed i s (f t)
class Reversing t
reversing :: Reversing t => t -> t
data Level i a
data Magma i t b a
makeClassyPrisms :: Name -> DecsQ
makePrisms :: Name -> DecsQ
class (Profunctor p, Bifunctor p) => Reviewable (p :: Type -> Type -> Type)
retagged :: (Profunctor p, Bifunctor p) => p a b -> p s b
class (Applicative f, Distributive f, Traversable f) => Settable (f :: Type -> Type)
type AnIso s t a b = Exchange a b a Identity b -> Exchange a b s Identity t
type AnIso' s a = AnIso s s a a
pattern Lazy :: Strict t s => t -> s
pattern Reversed :: Reversing t => t -> t
pattern Strict :: Strict s t => t -> s
pattern Swapped :: Swap p => p b a -> p a b
anon :: a -> (a -> Bool) -> Iso' (Maybe a) a
au :: Functor f => AnIso s t a b -> ((b -> t) -> f s) -> f a
auf :: (Functor f, Functor g) => AnIso s t a b -> (f t -> g s) -> f b -> g a
bimapping :: forall (f :: Type -> Type -> Type) (g :: Type -> Type -> Type) s t a b s' t' a' b'. (Bifunctor f, Bifunctor g) => AnIso s t a b -> AnIso s' t' a' b' -> Iso (f s s') (g t t') (f a a') (g b b')
cloneIso :: AnIso s t a b -> Iso s t a b
coerced :: forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
contramapping :: forall (f :: Type -> Type) s t a b. Contravariant f => AnIso s t a b -> Iso (f a) (f b) (f s) (f t)
curried :: forall a b c d e f1 p f2. (Profunctor p, Functor f2) => p (a -> b -> c) (f2 (d -> e -> f1)) -> p ((a, b) -> c) (f2 ((d, e) -> f1))
dimapping :: forall (p :: Type -> Type -> Type) (q :: Type -> Type -> Type) s t a b s' t' a' b'. (Profunctor p, Profunctor q) => AnIso s t a b -> AnIso s' t' a' b' -> Iso (p a s') (q b t') (p s a') (q t b')
enum :: Enum a => Iso' Int a
firsting :: forall (f :: Type -> Type -> Type) (g :: Type -> Type -> Type) s t a b x y. (Bifunctor f, Bifunctor g) => AnIso s t a b -> Iso (f s x) (g t y) (f a x) (g b y)
flipped :: forall a b c a' b' c' p f. (Profunctor p, Functor f) => p (b -> a -> c) (f (b' -> a' -> c')) -> p (a -> b -> c) (f (a' -> b' -> c'))
from :: AnIso s t a b -> Iso b a t s
imagma :: Over (Indexed i) (Molten i a b) s t a b -> Iso s t' (Magma i t b a) (Magma j t' c c)
involuted :: (a -> a) -> Iso' a a
iso :: (s -> a) -> (b -> t) -> Iso s t a b
lazy :: Strict lazy strict => Iso' strict lazy
lmapping :: forall (p :: Type -> Type -> Type) (q :: Type -> Type -> Type) s t a b x y. (Profunctor p, Profunctor q) => AnIso s t a b -> Iso (p a x) (q b y) (p s x) (q t y)
magma :: LensLike (Mafic a b) s t a b -> Iso s u (Magma Int t b a) (Magma j u c c)
mapping :: forall (f :: Type -> Type) (g :: Type -> Type) s t a b. (Functor f, Functor g) => AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
non :: Eq a => a -> Iso' (Maybe a) a
non' :: APrism' a () -> Iso' (Maybe a) a
reversed :: Reversing a => Iso' a a
rmapping :: forall (p :: Type -> Type -> Type) (q :: Type -> Type -> Type) s t a b x y. (Profunctor p, Profunctor q) => AnIso s t a b -> Iso (p x s) (q y t) (p x a) (q y b)
seconding :: forall (f :: Type -> Type -> Type) (g :: Type -> Type -> Type) s t a b x y. (Bifunctor f, Bifunctor g) => AnIso s t a b -> Iso (f x s) (g y t) (f x a) (g y b)
swapped :: forall (p :: Type -> Type -> Type) a b c d. Swap p => Iso (p a b) (p c d) (p b a) (p d c)
uncurried :: forall a b c d e f1 p f2. (Profunctor p, Functor f2) => p ((a, b) -> c) (f2 ((d, e) -> f1)) -> p (a -> b -> c) (f2 (d -> e -> f1))
under :: AnIso s t a b -> (t -> s) -> b -> a
withIso :: AnIso s t a b -> ((s -> a) -> (b -> t) -> r) -> r
xplat :: forall {k2} s g (t :: k2) a (b :: k2). Optic (Costar ((->) s)) g s t a b -> ((s -> a) -> g b) -> g t
xplatf :: forall {k} {k2} f g (s :: k) (t :: k2) (a :: k) (b :: k2). Optic (Costar f) g s t a b -> (f a -> g b) -> f s -> g t
(#%%=) :: MonadState s m => ALens s s a b -> (a -> (r, b)) -> m r
(#%%~) :: Functor f => ALens s t a b -> (a -> f b) -> s -> f t
(#%=) :: MonadState s m => ALens s s a b -> (a -> b) -> m ()
(#%~) :: ALens s t a b -> (a -> b) -> s -> t
(#=) :: MonadState s m => ALens s s a b -> b -> m ()
(#~) :: ALens s t a b -> b -> s -> t
(%%=) :: forall {k} s m p r (a :: k) b. MonadState s m => Over p ((,) r) s s a b -> p a (r, b) -> m r
(%%@=) :: MonadState s m => Over (Indexed i) ((,) r) s s a b -> (i -> a -> (r, b)) -> m r
(%%@~) :: forall {k1} i f s (t :: k1) a (b :: k1). Over (Indexed i) f s t a b -> (i -> a -> f b) -> s -> f t
(%%~) :: forall {k} f s (t :: k) a (b :: k). LensLike f s t a b -> (a -> f b) -> s -> f t
(&~) :: s -> State s a -> s
(<#%=) :: MonadState s m => ALens s s a b -> (a -> b) -> m b
(<#%~) :: ALens s t a b -> (a -> b) -> s -> (b, t)
(<#=) :: MonadState s m => ALens s s a b -> b -> m b
(<#~) :: ALens s t a b -> b -> s -> (b, t)
(<%=) :: MonadState s m => LensLike ((,) b) s s a b -> (a -> b) -> m b
(<%@=) :: MonadState s m => Over (Indexed i) ((,) b) s s a b -> (i -> a -> b) -> m b
(<%@~) :: Over (Indexed i) ((,) b) s t a b -> (i -> a -> b) -> s -> (b, t)
(<%~) :: LensLike ((,) b) s t a b -> (a -> b) -> s -> (b, t)
(<&&=) :: MonadState s m => LensLike' ((,) Bool) s Bool -> Bool -> m Bool
(<&&~) :: LensLike ((,) Bool) s t Bool Bool -> Bool -> s -> (Bool, t)
(<**=) :: (MonadState s m, Floating a) => LensLike' ((,) a) s a -> a -> m a
(<**~) :: Floating a => LensLike ((,) a) s t a a -> a -> s -> (a, t)
(<*=) :: (MonadState s m, Num a) => LensLike' ((,) a) s a -> a -> m a
(<*~) :: Num a => LensLike ((,) a) s t a a -> a -> s -> (a, t)
(<+=) :: (MonadState s m, Num a) => LensLike' ((,) a) s a -> a -> m a
(<+~) :: Num a => LensLike ((,) a) s t a a -> a -> s -> (a, t)
(<-=) :: (MonadState s m, Num a) => LensLike' ((,) a) s a -> a -> m a
(<-~) :: Num a => LensLike ((,) a) s t a a -> a -> s -> (a, t)
(<//=) :: (MonadState s m, Fractional a) => LensLike' ((,) a) s a -> a -> m a
(<//~) :: Fractional a => LensLike ((,) a) s t a a -> a -> s -> (a, t)
(<<%=) :: (Strong p, MonadState s m) => Over p ((,) a) s s a b -> p a b -> m a
(<<%@=) :: MonadState s m => Over (Indexed i) ((,) a) s s a b -> (i -> a -> b) -> m a
(<<%@~) :: Over (Indexed i) ((,) a) s t a b -> (i -> a -> b) -> s -> (a, t)
(<<%~) :: LensLike ((,) a) s t a b -> (a -> b) -> s -> (a, t)
(<<&&=) :: MonadState s m => LensLike' ((,) Bool) s Bool -> Bool -> m Bool
(<<&&~) :: LensLike' ((,) Bool) s Bool -> Bool -> s -> (Bool, s)
(<<**=) :: (MonadState s m, Floating a) => LensLike' ((,) a) s a -> a -> m a
(<<**~) :: Floating a => LensLike' ((,) a) s a -> a -> s -> (a, s)
(<<*=) :: (MonadState s m, Num a) => LensLike' ((,) a) s a -> a -> m a
(<<*~) :: Num a => LensLike' ((,) a) s a -> a -> s -> (a, s)
(<<+=) :: (MonadState s m, Num a) => LensLike' ((,) a) s a -> a -> m a
(<<+~) :: Num a => LensLike' ((,) a) s a -> a -> s -> (a, s)
(<<-=) :: (MonadState s m, Num a) => LensLike' ((,) a) s a -> a -> m a
(<<-~) :: Num a => LensLike' ((,) a) s a -> a -> s -> (a, s)
(<<.=) :: MonadState s m => LensLike ((,) a) s s a b -> b -> m a
(<<.~) :: LensLike ((,) a) s t a b -> b -> s -> (a, t)
(<<//=) :: (MonadState s m, Fractional a) => LensLike' ((,) a) s a -> a -> m a
(<<//~) :: Fractional a => LensLike' ((,) a) s a -> a -> s -> (a, s)
(<<<>:=) :: (MonadState s m, Semigroup r) => LensLike' ((,) r) s r -> r -> m r
(<<<>:~) :: Semigroup m => LensLike' ((,) m) s m -> m -> s -> (m, s)
(<<<>=) :: (MonadState s m, Semigroup r) => LensLike' ((,) r) s r -> r -> m r
(<<<>~) :: Semigroup r => LensLike' ((,) r) s r -> r -> s -> (r, s)
(<<>:=) :: (MonadState s m, Semigroup r) => LensLike' ((,) r) s r -> r -> m r
(<<>:~) :: Semigroup m => LensLike ((,) m) s t m m -> m -> s -> (m, t)
(<<>=) :: (MonadState s m, Semigroup r) => LensLike' ((,) r) s r -> r -> m r
(<<>~) :: Semigroup m => LensLike ((,) m) s t m m -> m -> s -> (m, t)
(<<?=) :: MonadState s m => LensLike ((,) a) s s a (Maybe b) -> b -> m a
(<<?~) :: LensLike ((,) a) s t a (Maybe b) -> b -> s -> (a, t)
(<<^=) :: (MonadState s m, Num a, Integral e) => LensLike' ((,) a) s a -> e -> m a
(<<^^=) :: (MonadState s m, Fractional a, Integral e) => LensLike' ((,) a) s a -> e -> m a
(<<^^~) :: (Fractional a, Integral e) => LensLike' ((,) a) s a -> e -> s -> (a, s)
(<<^~) :: (Num a, Integral e) => LensLike' ((,) a) s a -> e -> s -> (a, s)
(<<||=) :: MonadState s m => LensLike' ((,) Bool) s Bool -> Bool -> m Bool
(<<||~) :: LensLike' ((,) Bool) s Bool -> Bool -> s -> (Bool, s)
(<<~) :: MonadState s m => ALens s s a b -> m b -> m b
(<^=) :: (MonadState s m, Num a, Integral e) => LensLike' ((,) a) s a -> e -> m a
(<^^=) :: (MonadState s m, Fractional a, Integral e) => LensLike' ((,) a) s a -> e -> m a
(<^^~) :: (Fractional a, Integral e) => LensLike ((,) a) s t a a -> e -> s -> (a, t)
(<^~) :: (Num a, Integral e) => LensLike ((,) a) s t a a -> e -> s -> (a, t)
(<||=) :: MonadState s m => LensLike' ((,) Bool) s Bool -> Bool -> m Bool
(<||~) :: LensLike ((,) Bool) s t Bool Bool -> Bool -> s -> (Bool, t)
(??) :: Functor f => f (a -> b) -> a -> f b
type ALens s t a b = LensLike Pretext (->) a b s t a b
type ALens' s a = ALens s s a a
type AnIndexedLens i s t a b = Optical Indexed i (->) Pretext Indexed i a b s t a b
type AnIndexedLens' i s a = AnIndexedLens i s s a a
(^#) :: s -> ALens s t a b -> a
alongside :: LensLike (AlongsideLeft f b') s t a b -> LensLike (AlongsideRight f t) s' t' a' b' -> LensLike f (s, s') (t, t') (a, a') (b, b')
choosing :: Functor f => LensLike f s t a b -> LensLike f s' t' a b -> LensLike f (Either s s') (Either t t') a b
chosen :: forall a b p f. (Conjoined p, Functor f) => p a (f b) -> p (Either a a) (f (Either b b))
cloneIndexPreservingLens :: ALens s t a b -> IndexPreservingLens s t a b
cloneIndexedLens :: AnIndexedLens i s t a b -> IndexedLens i s t a b
cloneLens :: ALens s t a b -> Lens s t a b
devoid :: forall {k} p f (a :: k) b. Over p f Void Void a b
fusing :: Functor f => LensLike (Yoneda f) s t a b -> LensLike f s t a b
head1 :: forall (t :: Type -> Type) a. Traversable1 t => Lens' (t a) a
ilens :: (s -> (i, a)) -> (s -> b -> t) -> IndexedLens i s t a b
inside :: forall (p :: Type -> Type -> Type) s t a b e. Corepresentable p => ALens s t a b -> Lens (p e s) (p e t) (p e a) (p e b)
iplens :: (s -> a) -> (s -> b -> t) -> IndexPreservingLens s t a b
last1 :: forall (t :: Type -> Type) a. Traversable1 t => Lens' (t a) a
locus :: forall (p :: Type -> Type -> Type -> Type) a c s b. IndexedComonadStore p => Lens (p a c s) (p b c s) a b
overA :: Arrow ar => LensLike (Context a b) s t a b -> ar a b -> ar s t
storing :: ALens s t a b -> b -> s -> t
united :: forall a f. Functor f => (() -> f ()) -> a -> f a
withLens :: ALens s t a b -> ((s -> a) -> (s -> b -> t) -> r) -> r
ilevels :: forall (f :: Type -> Type) i s t a b j. Applicative f => Traversing (Indexed i) f s t a b -> IndexedLensLike Int f s t (Level i a) (Level j b)
levels :: forall (f :: Type -> Type) s t a b. Applicative f => Traversing (->) f s t a b -> IndexedLensLike Int f s t (Level () a) (Level () b)
(...) :: forall {k} f c s t p (a :: k) b. (Applicative f, Plated c) => LensLike f s t c c -> Over p f c c a b -> Over p f s t a b
class GPlated a (g :: k -> Type)
class GPlated1 (f :: k -> Type) (g :: k -> Type)
class Plated a
plate :: Plated a => Traversal' a a
children :: Plated a => a -> [a]
composOpFold :: Plated a => b -> (b -> b -> b) -> (a -> b) -> a -> b
contexts :: Plated a => a -> [Context a a a]
contextsOf :: ATraversal' a a -> a -> [Context a a a]
contextsOn :: Plated a => ATraversal s t a a -> s -> [Context a a t]
contextsOnOf :: ATraversal s t a a -> ATraversal' a a -> s -> [Context a a t]
cosmos :: Plated a => Fold a a
cosmosOf :: (Applicative f, Contravariant f) => LensLike' f a a -> LensLike' f a a
cosmosOn :: (Applicative f, Contravariant f, Plated a) => LensLike' f s a -> LensLike' f s a
cosmosOnOf :: (Applicative f, Contravariant f) => LensLike' f s a -> LensLike' f a a -> LensLike' f s a
deep :: (Conjoined p, Applicative f, Plated s) => Traversing p f s s a b -> Over p f s s a b
gplate :: (Generic a, GPlated a (Rep a)) => Traversal' a a
gplate1 :: forall {k} (f :: k -> Type) (a :: k). (Generic1 f, GPlated1 f (Rep1 f)) => Traversal' (f a) (f a)
holes :: Plated a => a -> [Pretext (->) a a a]
holesOn :: Conjoined p => Over p (Bazaar p a a) s t a a -> s -> [Pretext p a a t]
holesOnOf :: Conjoined p => LensLike (Bazaar p r r) s t a b -> Over p (Bazaar p r r) a b r r -> s -> [Pretext p r r t]
para :: Plated a => (a -> [r] -> r) -> a -> r
paraOf :: Getting (Endo [a]) a a -> (a -> [r] -> r) -> a -> r
parts :: Plated a => Lens' a [a]
rewrite :: Plated a => (a -> Maybe a) -> a -> a
rewriteM :: (Monad m, Plated a) => (a -> m (Maybe a)) -> a -> m a
rewriteMOf :: Monad m => LensLike (WrappedMonad m) a b a b -> (b -> m (Maybe a)) -> a -> m b
rewriteMOn :: (Monad m, Plated a) => LensLike (WrappedMonad m) s t a a -> (a -> m (Maybe a)) -> s -> m t
rewriteMOnOf :: Monad m => LensLike (WrappedMonad m) s t a b -> LensLike (WrappedMonad m) a b a b -> (b -> m (Maybe a)) -> s -> m t
rewriteOf :: ASetter a b a b -> (b -> Maybe a) -> a -> b
rewriteOn :: Plated a => ASetter s t a a -> (a -> Maybe a) -> s -> t
rewriteOnOf :: ASetter s t a b -> ASetter a b a b -> (b -> Maybe a) -> s -> t
transform :: Plated a => (a -> a) -> a -> a
transformM :: (Monad m, Plated a) => (a -> m a) -> a -> m a
transformMOf :: Monad m => LensLike (WrappedMonad m) a b a b -> (b -> m b) -> a -> m b
transformMOn :: (Monad m, Plated a) => LensLike (WrappedMonad m) s t a a -> (a -> m a) -> s -> m t
transformMOnOf :: Monad m => LensLike (WrappedMonad m) s t a b -> LensLike (WrappedMonad m) a b a b -> (b -> m b) -> s -> m t
transformOf :: ASetter a b a b -> (b -> b) -> a -> b
transformOn :: Plated a => ASetter s t a a -> (a -> a) -> s -> t
transformOnOf :: ASetter s t a b -> ASetter a b a b -> (b -> b) -> s -> t
universe :: Plated a => a -> [a]
universeOf :: Getting (Endo [a]) a a -> a -> [a]
universeOn :: Plated a => Getting (Endo [a]) s a -> s -> [a]
universeOnOf :: Getting (Endo [a]) s a -> Getting (Endo [a]) a a -> s -> [a]
type APrism s t a b = Market a b a Identity b -> Market a b s Identity t
type APrism' s a = APrism s s a a
class Prefixed t
prefixed :: Prefixed t => t -> Prism' t t
class Suffixed t
suffixed :: Suffixed t => t -> Prism' t t
_Just :: forall a b p f. (Choice p, Applicative f) => p a (f b) -> p (Maybe a) (f (Maybe b))
_Left :: forall a c b p f. (Choice p, Applicative f) => p a (f b) -> p (Either a c) (f (Either b c))
_Nothing :: forall a p f. (Choice p, Applicative f) => p () (f ()) -> p (Maybe a) (f (Maybe a))
_Right :: forall c a b p f. (Choice p, Applicative f) => p a (f b) -> p (Either c a) (f (Either c b))
_Show :: (Read a, Show a) => Prism' String a
_Void :: forall s a p f. (Choice p, Applicative f) => p a (f Void) -> p s (f s)
aside :: APrism s t a b -> Prism (e, s) (e, t) (e, a) (e, b)
below :: forall (f :: Type -> Type) s a. Traversable f => APrism' s a -> Prism' (f s) (f a)
clonePrism :: APrism s t a b -> Prism s t a b
isn't :: APrism s t a b -> s -> Bool
matching :: APrism s t a b -> s -> Either t a
matching' :: LensLike (Either a) s t a b -> s -> Either t a
nearly :: a -> (a -> Bool) -> Prism' a ()
only :: Eq a => a -> Prism' a ()
outside :: forall (p :: Type -> Type -> Type) s t a b r. Representable p => APrism s t a b -> Lens (p t r) (p s r) (p b r) (p a r)
prism :: (b -> t) -> (s -> Either t a) -> Prism s t a b
prism' :: (b -> s) -> (s -> Maybe a) -> Prism s s a b
withPrism :: APrism s t a b -> ((b -> t) -> (s -> Either t a) -> r) -> r
without :: APrism s t a b -> APrism u v c d -> Prism (Either s u) (Either t v) (Either a c) (Either b d)
type Fold s a = forall (f :: Type -> Type). (Contravariant f, Applicative f) => a -> f a -> s -> f s
newtype ReifiedFold s a
Fold :: Fold s a -> ReifiedFold s a
[runFold] :: ReifiedFold s a -> Fold s a
type Getter s a = forall (f :: Type -> Type). (Contravariant f, Functor f) => a -> f a -> s -> f s
newtype ReifiedGetter s a
Getter :: Getter s a -> ReifiedGetter s a
[runGetter] :: ReifiedGetter s a -> Getter s a
type IndexedFold i s a = forall (p :: Type -> Type -> Type) (f :: Type -> Type). (Indexable i p, Contravariant f, Applicative f) => p a f a -> s -> f s
newtype ReifiedIndexedFold i s a
IndexedFold :: IndexedFold i s a -> ReifiedIndexedFold i s a
[runIndexedFold] :: ReifiedIndexedFold i s a -> IndexedFold i s a
type IndexedGetter i s a = forall (p :: Type -> Type -> Type) (f :: Type -> Type). (Indexable i p, Contravariant f, Functor f) => p a f a -> s -> f s
newtype ReifiedIndexedGetter i s a
IndexedGetter :: IndexedGetter i s a -> ReifiedIndexedGetter i s a
[runIndexedGetter] :: ReifiedIndexedGetter i s a -> IndexedGetter i s a
type IndexedLens i s t a b = forall (f :: Type -> Type) (p :: Type -> Type -> Type). (Indexable i p, Functor f) => p a f b -> s -> f t
newtype ReifiedIndexedLens i s t a b
IndexedLens :: IndexedLens i s t a b -> ReifiedIndexedLens i s t a b
[runIndexedLens] :: ReifiedIndexedLens i s t a b -> IndexedLens i s t a b
type IndexedSetter i s t a b = forall (f :: Type -> Type) (p :: Type -> Type -> Type). (Indexable i p, Settable f) => p a f b -> s -> f t
newtype ReifiedIndexedSetter i s t a b
IndexedSetter :: IndexedSetter i s t a b -> ReifiedIndexedSetter i s t a b
[runIndexedSetter] :: ReifiedIndexedSetter i s t a b -> IndexedSetter i s t a b
type IndexedTraversal i s t a b = forall (p :: Type -> Type -> Type) (f :: Type -> Type). (Indexable i p, Applicative f) => p a f b -> s -> f t
newtype ReifiedIndexedTraversal i s t a b
IndexedTraversal :: IndexedTraversal i s t a b -> ReifiedIndexedTraversal i s t a b
[runIndexedTraversal] :: ReifiedIndexedTraversal i s t a b -> IndexedTraversal i s t a b
type Iso s t a b = forall (p :: Type -> Type -> Type) (f :: Type -> Type). (Profunctor p, Functor f) => p a f b -> p s f t
newtype ReifiedIso s t a b
Iso :: Iso s t a b -> ReifiedIso s t a b
[runIso] :: ReifiedIso s t a b -> Iso s t a b
type Prism s t a b = forall (p :: Type -> Type -> Type) (f :: Type -> Type). (Choice p, Applicative f) => p a f b -> p s f t
newtype ReifiedPrism s t a b
Prism :: Prism s t a b -> ReifiedPrism s t a b
[runPrism] :: ReifiedPrism s t a b -> Prism s t a b
type ReifiedIndexedLens' i s a = ReifiedIndexedLens i s s a a
type ReifiedIndexedSetter' i s a = ReifiedIndexedSetter i s s a a
type ReifiedIndexedTraversal' i s a = ReifiedIndexedTraversal i s s a a
type ReifiedIso' s a = ReifiedIso s s a a
type ReifiedLens' s a = ReifiedLens s s a a
type ReifiedPrism' s a = ReifiedPrism s s a a
newtype ReifiedSetter s t a b
Setter :: Setter s t a b -> ReifiedSetter s t a b
[runSetter] :: ReifiedSetter s t a b -> Setter s t a b
type ReifiedSetter' s a = ReifiedSetter s s a a
newtype ReifiedTraversal s t a b
Traversal :: Traversal s t a b -> ReifiedTraversal s t a b
[runTraversal] :: ReifiedTraversal s t a b -> Traversal s t a b
type ReifiedTraversal' s a = ReifiedTraversal s s a a
type Setter s t a b = forall (f :: Type -> Type). Settable f => a -> f b -> s -> f t
type Traversal s t a b = forall (f :: Type -> Type). Applicative f => a -> f b -> s -> f t
(#) :: AReview t b -> b -> t
re :: AReview t b -> Getter b t
reuse :: MonadState b m => AReview t b -> m t
reuses :: MonadState b m => AReview t b -> (t -> r) -> m r
review :: MonadReader b m => AReview t b -> m t
reviewing :: (Bifunctor p, Functor f) => Optic (Tagged :: Type -> Type -> Type) Identity s t a b -> Optic' p f t b
reviews :: MonadReader b m => AReview t b -> (t -> r) -> m r
un :: (Profunctor p, Bifunctor p, Functor f) => Getting a s a -> Optic' p f a s
unto :: (Profunctor p, Bifunctor p, Functor f) => (b -> t) -> Optic p f s t a b
(%=) :: MonadState s m => ASetter s s a b -> (a -> b) -> m ()
(%@=) :: MonadState s m => AnIndexedSetter i s s a b -> (i -> a -> b) -> m ()
(%@~) :: AnIndexedSetter i s t a b -> (i -> a -> b) -> s -> t
(&&=) :: MonadState s m => ASetter' s Bool -> Bool -> m ()
(&&~) :: ASetter s t Bool Bool -> Bool -> s -> t
(**=) :: (MonadState s m, Floating a) => ASetter' s a -> a -> m ()
(**~) :: Floating a => ASetter s t a a -> a -> s -> t
(*=) :: (MonadState s m, Num a) => ASetter' s a -> a -> m ()
(*~) :: Num a => ASetter s t a a -> a -> s -> t
(+=) :: (MonadState s m, Num a) => ASetter' s a -> a -> m ()
(+~) :: Num a => ASetter s t a a -> a -> s -> t
(-=) :: (MonadState s m, Num a) => ASetter' s a -> a -> m ()
(-~) :: Num a => ASetter s t a a -> a -> s -> t
(.=) :: MonadState s m => ASetter s s a b -> b -> m ()
(.@=) :: MonadState s m => AnIndexedSetter i s s a b -> (i -> b) -> m ()
(.@~) :: AnIndexedSetter i s t a b -> (i -> b) -> s -> t
(//=) :: (MonadState s m, Fractional a) => ASetter' s a -> a -> m ()
(//~) :: Fractional a => ASetter s t a a -> a -> s -> t
(<.=) :: MonadState s m => ASetter s s a b -> b -> m b
(<.~) :: ASetter s t a b -> b -> s -> (b, t)
(<>:=) :: (MonadState s m, Semigroup a) => ASetter' s a -> a -> m ()
(<>:~) :: Semigroup b => ASetter s t b b -> b -> s -> t
(<>=) :: (MonadState s m, Semigroup a) => ASetter' s a -> a -> m ()
(<>~) :: Semigroup a => ASetter s t a a -> a -> s -> t
(<?=) :: MonadState s m => ASetter s s a (Maybe b) -> b -> m b
(<?~) :: ASetter s t a (Maybe b) -> b -> s -> (b, t)
(<~) :: MonadState s m => ASetter s s a b -> m b -> m ()
(?=) :: MonadState s m => ASetter s s a (Maybe b) -> b -> m ()
(?~) :: ASetter s t a (Maybe b) -> b -> s -> t
type AnIndexedSetter i s t a b = Indexed i a Identity b -> s -> Identity t
type AnIndexedSetter' i s a = AnIndexedSetter i s s a a
type Setting (p :: Type -> Type -> Type) s t a b = p a Identity b -> s -> Identity t
type Setting' (p :: Type -> Type -> Type) s a = Setting p s s a a
(^=) :: (MonadState s m, Num a, Integral e) => ASetter' s a -> e -> m ()
(^^=) :: (MonadState s m, Fractional a, Integral e) => ASetter' s a -> e -> m ()
(^^~) :: (Fractional a, Integral e) => ASetter s t a a -> e -> s -> t
(^~) :: (Num a, Integral e) => ASetter s t a a -> e -> s -> t
argument :: forall (p :: Type -> Type -> Type) b r a. Profunctor p => Setter (p b r) (p a r) a b
assign :: MonadState s m => ASetter s s a b -> b -> m ()
assignA :: Arrow p => ASetter s t a b -> p s b -> p s t
censoring :: MonadWriter w m => Setter w w u v -> (u -> v) -> m a -> m a
cloneIndexPreservingSetter :: ASetter s t a b -> IndexPreservingSetter s t a b
cloneIndexedSetter :: AnIndexedSetter i s t a b -> IndexedSetter i s t a b
cloneSetter :: ASetter s t a b -> Setter s t a b
contramapped :: forall (f :: Type -> Type) b a. Contravariant f => Setter (f b) (f a) a b
icensoring :: MonadWriter w m => IndexedSetter i w w u v -> (i -> u -> v) -> m a -> m a
ilocally :: MonadReader s m => AnIndexedSetter i s s a b -> (i -> a -> b) -> m r -> m r
imapOf :: AnIndexedSetter i s t a b -> (i -> a -> b) -> s -> t
imodifying :: MonadState s m => AnIndexedSetter i s s a b -> (i -> a -> b) -> m ()
iover :: AnIndexedSetter i s t a b -> (i -> a -> b) -> s -> t
ipassing :: MonadWriter w m => IndexedSetter i w w u v -> m (a, i -> u -> v) -> m a
iset :: AnIndexedSetter i s t a b -> (i -> b) -> s -> t
isets :: ((i -> a -> b) -> s -> t) -> IndexedSetter i s t a b
lifted :: forall (m :: Type -> Type) a b. Monad m => Setter (m a) (m b) a b
locally :: MonadReader s m => ASetter s s a b -> (a -> b) -> m r -> m r
mapOf :: ASetter s t a b -> (a -> b) -> s -> t
mapped :: forall (f :: Type -> Type) a b. Functor f => Setter (f a) (f b) a b
modifying :: MonadState s m => ASetter s s a b -> (a -> b) -> m ()
passing :: MonadWriter w m => Setter w w u v -> m (a, u -> v) -> m a
scribe :: (MonadWriter t m, Monoid s) => ASetter s t a b -> b -> m ()
set' :: ASetter' s a -> a -> s -> s
setting :: ((a -> b) -> s -> t) -> IndexPreservingSetter s t a b
(||=) :: MonadState s m => ASetter' s Bool -> Bool -> m ()
(||~) :: ASetter s t Bool Bool -> Bool -> s -> t
abbreviatedFields :: LensRules
abbreviatedNamer :: FieldNamer
camelCaseFields :: LensRules
camelCaseNamer :: FieldNamer
classIdFields :: LensRules
classIdNamer :: FieldNamer
classUnderscoreNoPrefixFields :: LensRules
classUnderscoreNoPrefixNamer :: FieldNamer
classyRules :: LensRules
classyRules_ :: LensRules
createClass :: Lens' LensRules Bool
declareClassy :: DecsQ -> DecsQ
declareClassyFor :: [(String, (String, String))] -> [(String, String)] -> DecsQ -> DecsQ
declareFields :: DecsQ -> DecsQ
declareLenses :: DecsQ -> DecsQ
declareLensesFor :: [(String, String)] -> DecsQ -> DecsQ
declareLensesWith :: LensRules -> DecsQ -> DecsQ
declarePrisms :: DecsQ -> DecsQ
declareWrapped :: DecsQ -> DecsQ
defaultFieldRules :: LensRules
generateLazyPatterns :: Lens' LensRules Bool
generateRecordSyntax :: Lens' LensRules Bool
generateSignatures :: Lens' LensRules Bool
generateUpdateableOptics :: Lens' LensRules Bool
lensClass :: Lens' LensRules ClassyNamer
lensField :: Lens' LensRules FieldNamer
lensRules :: LensRules
lensRulesFor :: [(String, String)] -> LensRules
lookingupNamer :: [(String, String)] -> FieldNamer
makeClassy :: Name -> DecsQ
makeClassyFor :: String -> String -> [(String, String)] -> Name -> DecsQ
makeClassy_ :: Name -> DecsQ
makeFields :: Name -> DecsQ
makeFieldsId :: Name -> DecsQ
makeFieldsNoPrefix :: Name -> DecsQ
makeLenses :: Name -> DecsQ
makeLensesFor :: [(String, String)] -> Name -> DecsQ
makeLensesWith :: LensRules -> Name -> DecsQ
makeWrapped :: Name -> DecsQ
mappingNamer :: (String -> [String]) -> FieldNamer
simpleLenses :: Lens' LensRules Bool
underscoreFields :: LensRules
underscoreNamer :: FieldNamer
underscoreNoPrefixNamer :: FieldNamer
type ATraversal s t a b = LensLike Bazaar (->) a b s t a b
type ATraversal' s a = ATraversal s s a a
type ATraversal1 s t a b = LensLike Bazaar1 (->) a b s t a b
type ATraversal1' s a = ATraversal1 s s a a
type AnIndexedTraversal i s t a b = Over Indexed i Bazaar Indexed i a b s t a b
type AnIndexedTraversal' i s a = AnIndexedTraversal i s s a a
type AnIndexedTraversal1 i s t a b = Over Indexed i Bazaar1 Indexed i a b s t a b
type AnIndexedTraversal1' i s a = AnIndexedTraversal1 i s s a a
class Ord k => TraverseMax k (m :: Type -> Type) | m -> k
traverseMax :: TraverseMax k m => IndexedTraversal' k (m v) v
class Ord k => TraverseMin k (m :: Type -> Type) | m -> k
traverseMin :: TraverseMin k m => IndexedTraversal' k (m v) v
type Traversing (p :: Type -> Type -> Type) (f :: Type -> Type) s t a b = Over p BazaarT p f a b s t a b
type Traversing' (p :: Type -> Type -> Type) (f :: Type -> Type) s a = Traversing p f s s a a
type Traversing1 (p :: Type -> Type -> Type) (f :: Type -> Type) s t a b = Over p BazaarT1 p f a b s t a b
type Traversing1' (p :: Type -> Type -> Type) (f :: Type -> Type) s a = Traversing1 p f s s a a
beside :: (Representable q, Applicative (Rep q), Applicative f, Bitraversable r) => Optical p q f s t a b -> Optical p q f s' t' a b -> Optical p q f (r s s') (r t t') a b
both :: forall (r :: Type -> Type -> Type) a b. Bitraversable r => Traversal (r a a) (r b b) a b
both1 :: forall (r :: Type -> Type -> Type) a b. Bitraversable1 r => Traversal1 (r a a) (r b b) a b
cloneIndexPreservingTraversal :: ATraversal s t a b -> IndexPreservingTraversal s t a b
cloneIndexPreservingTraversal1 :: ATraversal1 s t a b -> IndexPreservingTraversal1 s t a b
cloneIndexedTraversal :: AnIndexedTraversal i s t a b -> IndexedTraversal i s t a b
cloneIndexedTraversal1 :: AnIndexedTraversal1 i s t a b -> IndexedTraversal1 i s t a b
cloneTraversal :: ATraversal s t a b -> Traversal s t a b
cloneTraversal1 :: ATraversal1 s t a b -> Traversal1 s t a b
confusing :: Applicative f => LensLike (Curried (Yoneda f) (Yoneda f)) s t a b -> LensLike f s t a b
deepOf :: (Conjoined p, Applicative f) => LensLike f s t s t -> Traversing p f s t a b -> Over p f s t a b
dropping :: (Conjoined p, Applicative f) => Int -> Over p (Indexing f) s t a a -> Over p f s t a a
element :: forall (t :: Type -> Type) a. Traversable t => Int -> IndexedTraversal' Int (t a) a
elementOf :: forall (f :: Type -> Type) s t a. Applicative f => LensLike (Indexing f) s t a a -> Int -> IndexedLensLike Int f s t a a
elements :: forall (t :: Type -> Type) a. Traversable t => (Int -> Bool) -> IndexedTraversal' Int (t a) a
elementsOf :: forall (f :: Type -> Type) s t a. Applicative f => LensLike (Indexing f) s t a a -> (Int -> Bool) -> IndexedLensLike Int f s t a a
failing :: (Conjoined p, Applicative f) => Traversing p f s t a b -> Over p f s t a b -> Over p f s t a b
failover :: Alternative m => LensLike ((,) Any) s t a b -> (a -> b) -> s -> m t
forMOf :: LensLike (WrappedMonad m) s t a b -> s -> (a -> m b) -> m t
forOf :: LensLike f s t a b -> s -> (a -> f b) -> f t
holes1Of :: Conjoined p => Over p (Bazaar1 p a a) s t a a -> s -> NonEmpty (Pretext p a a t)
holesOf :: Conjoined p => Over p (Bazaar p a a) s t a a -> s -> [Pretext p a a t]
ifailover :: Alternative m => Over (Indexed i) ((,) Any) s t a b -> (i -> a -> b) -> s -> m t
iforMOf :: (Indexed i a (WrappedMonad m b) -> s -> WrappedMonad m t) -> s -> (i -> a -> m b) -> m t
iforOf :: (Indexed i a (f b) -> s -> f t) -> s -> (i -> a -> f b) -> f t
ignored :: Applicative f => pafb -> s -> f s
iloci :: forall i a c s b p f. (Indexable i p, Applicative f) => p a (f b) -> Bazaar (Indexed i) a c s -> f (Bazaar (Indexed i) b c s)
imapAccumLOf :: Over (Indexed i) (State acc) s t a b -> (i -> acc -> a -> (acc, b)) -> acc -> s -> (acc, t)
imapAccumROf :: Over (Indexed i) (Backwards (State acc)) s t a b -> (i -> acc -> a -> (acc, b)) -> acc -> s -> (acc, t)
imapMOf :: Over (Indexed i) (WrappedMonad m) s t a b -> (i -> a -> m b) -> s -> m t
ipartsOf :: (Indexable [i] p, Functor f) => Traversing (Indexed i) f s t a a -> Over p f s t [a] [a]
ipartsOf' :: forall i p f s t a. (Indexable [i] p, Functor f) => Over (Indexed i) (Bazaar' (Indexed i) a) s t a a -> Over p f s t [a] [a]
itraverseOf :: (Indexed i a (f b) -> s -> f t) -> (i -> a -> f b) -> s -> f t
iunsafePartsOf :: (Indexable [i] p, Functor f) => Traversing (Indexed i) f s t a b -> Over p f s t [a] [b]
iunsafePartsOf' :: forall i s t a b. Over (Indexed i) (Bazaar (Indexed i) a b) s t a b -> IndexedLens [i] s t [a] [b]
loci :: forall a c s b f. Applicative f => (a -> f b) -> Bazaar (->) a c s -> f (Bazaar (->) b c s)
mapAccumLOf :: LensLike (State acc) s t a b -> (acc -> a -> (acc, b)) -> acc -> s -> (acc, t)
mapAccumROf :: LensLike (Backwards (State acc)) s t a b -> (acc -> a -> (acc, b)) -> acc -> s -> (acc, t)
mapMOf :: LensLike (WrappedMonad m) s t a b -> (a -> m b) -> s -> m t
partsOf :: Functor f => Traversing (->) f s t a a -> LensLike f s t [a] [a]
partsOf' :: ATraversal s t a a -> Lens s t [a] [a]
scanl1Of :: LensLike (State (Maybe a)) s t a a -> (a -> a -> a) -> s -> t
scanr1Of :: LensLike (Backwards (State (Maybe a))) s t a a -> (a -> a -> a) -> s -> t
sequenceAOf :: LensLike f s t (f b) b -> s -> f t
sequenceByOf :: Traversal s t (f b) b -> (forall x. () => x -> f x) -> (forall x y. () => f (x -> y) -> f x -> f y) -> s -> f t
sequenceOf :: LensLike (WrappedMonad m) s t (m b) b -> s -> m t
singular :: (HasCallStack, Conjoined p, Functor f) => Traversing p f s t a a -> Over p f s t a a
taking :: (Conjoined p, Applicative f) => Int -> Traversing p f s t a a -> Over p f s t a a
transposeOf :: LensLike ZipList s t [a] a -> s -> [t]
traversal :: ((a -> f b) -> s -> f t) -> LensLike f s t a b
traverseByOf :: Traversal s t a b -> (forall x. () => x -> f x) -> (forall x y. () => f (x -> y) -> f x -> f y) -> (a -> f b) -> s -> f t
traverseOf :: LensLike f s t a b -> (a -> f b) -> s -> f t
traversed :: forall (f :: Type -> Type) a b. Traversable f => IndexedTraversal Int (f a) (f b) a b
traversed1 :: forall (f :: Type -> Type) a b. Traversable1 f => IndexedTraversal1 Int (f a) (f b) a b
traversed64 :: forall (f :: Type -> Type) a b. Traversable f => IndexedTraversal Int64 (f a) (f b) a b
unsafePartsOf :: Functor f => Traversing (->) f s t a b -> LensLike f s t [a] [b]
unsafePartsOf' :: ATraversal s t a b -> Lens s t [a] [b]
unsafeSingular :: (HasCallStack, Conjoined p, Functor f) => Traversing p f s t a b -> Over p f s t a b
class Field1 s t a b | s -> a, t -> b, s b -> t, t a -> s
_1 :: Field1 s t a b => Lens s t a b
class Field10 s t a b | s -> a, t -> b, s b -> t, t a -> s
_10 :: Field10 s t a b => Lens s t a b
class Field11 s t a b | s -> a, t -> b, s b -> t, t a -> s
_11 :: Field11 s t a b => Lens s t a b
class Field12 s t a b | s -> a, t -> b, s b -> t, t a -> s
_12 :: Field12 s t a b => Lens s t a b
class Field13 s t a b | s -> a, t -> b, s b -> t, t a -> s
_13 :: Field13 s t a b => Lens s t a b
class Field14 s t a b | s -> a, t -> b, s b -> t, t a -> s
_14 :: Field14 s t a b => Lens s t a b
class Field15 s t a b | s -> a, t -> b, s b -> t, t a -> s
_15 :: Field15 s t a b => Lens s t a b
class Field16 s t a b | s -> a, t -> b, s b -> t, t a -> s
_16 :: Field16 s t a b => Lens s t a b
class Field17 s t a b | s -> a, t -> b, s b -> t, t a -> s
_17 :: Field17 s t a b => Lens s t a b
class Field18 s t a b | s -> a, t -> b, s b -> t, t a -> s
_18 :: Field18 s t a b => Lens s t a b
class Field19 s t a b | s -> a, t -> b, s b -> t, t a -> s
_19 :: Field19 s t a b => Lens s t a b
class Field2 s t a b | s -> a, t -> b, s b -> t, t a -> s
_2 :: Field2 s t a b => Lens s t a b
class Field3 s t a b | s -> a, t -> b, s b -> t, t a -> s
_3 :: Field3 s t a b => Lens s t a b
class Field4 s t a b | s -> a, t -> b, s b -> t, t a -> s
_4 :: Field4 s t a b => Lens s t a b
class Field5 s t a b | s -> a, t -> b, s b -> t, t a -> s
_5 :: Field5 s t a b => Lens s t a b
class Field6 s t a b | s -> a, t -> b, s b -> t, t a -> s
_6 :: Field6 s t a b => Lens s t a b
class Field7 s t a b | s -> a, t -> b, s b -> t, t a -> s
_7 :: Field7 s t a b => Lens s t a b
class Field8 s t a b | s -> a, t -> b, s b -> t, t a -> s
_8 :: Field8 s t a b => Lens s t a b
class Field9 s t a b | s -> a, t -> b, s b -> t, t a -> s
_9 :: Field9 s t a b => Lens s t a b
_1' :: Field1 s t a b => Lens s t a b
_10' :: Field10 s t a b => Lens s t a b
_11' :: Field11 s t a b => Lens s t a b
_12' :: Field12 s t a b => Lens s t a b
_13' :: Field13 s t a b => Lens s t a b
_14' :: Field14 s t a b => Lens s t a b
_15' :: Field15 s t a b => Lens s t a b
_16' :: Field16 s t a b => Lens s t a b
_17' :: Field17 s t a b => Lens s t a b
_18' :: Field18 s t a b => Lens s t a b
_19' :: Field19 s t a b => Lens s t a b
_2' :: Field2 s t a b => Lens s t a b
_3' :: Field3 s t a b => Lens s t a b
_4' :: Field4 s t a b => Lens s t a b
_5' :: Field5 s t a b => Lens s t a b
_6' :: Field6 s t a b => Lens s t a b
_7' :: Field7 s t a b => Lens s t a b
_8' :: Field8 s t a b => Lens s t a b
_9' :: Field9 s t a b => Lens s t a b
type AReview t b = Optic' Tagged :: Type -> Type -> Type Identity t b
type As (a :: k2) = Equality' a a
type Equality (s :: k1) (t :: k2) (a :: k1) (b :: k2) = forall k3 (p :: k1 -> k3 -> Type) (f :: k2 -> k3). () => p a f b -> p s f t
type Equality' (s :: k2) (a :: k2) = Equality s s a a
type Fold1 s a = forall (f :: Type -> Type). (Contravariant f, Apply f) => a -> f a -> s -> f s
type IndexPreservingFold s a = forall (p :: Type -> Type -> Type) (f :: Type -> Type). (Conjoined p, Contravariant f, Applicative f) => p a f a -> p s f s
type IndexPreservingFold1 s a = forall (p :: Type -> Type -> Type) (f :: Type -> Type). (Conjoined p, Contravariant f, Apply f) => p a f a -> p s f s
type IndexPreservingGetter s a = forall (p :: Type -> Type -> Type) (f :: Type -> Type). (Conjoined p, Contravariant f, Functor f) => p a f a -> p s f s
type IndexPreservingLens s t a b = forall (p :: Type -> Type -> Type) (f :: Type -> Type). (Conjoined p, Functor f) => p a f b -> p s f t
type IndexPreservingLens' s a = IndexPreservingLens s s a a
type IndexPreservingSetter s t a b = forall (p :: Type -> Type -> Type) (f :: Type -> Type). (Conjoined p, Settable f) => p a f b -> p s f t
type IndexPreservingSetter' s a = IndexPreservingSetter s s a a
type IndexPreservingTraversal s t a b = forall (p :: Type -> Type -> Type) (f :: Type -> Type). (Conjoined p, Applicative f) => p a f b -> p s f t
type IndexPreservingTraversal' s a = IndexPreservingTraversal s s a a
type IndexPreservingTraversal1 s t a b = forall (p :: Type -> Type -> Type) (f :: Type -> Type). (Conjoined p, Apply f) => p a f b -> p s f t
type IndexPreservingTraversal1' s a = IndexPreservingTraversal1 s s a a
type IndexedFold1 i s a = forall (p :: Type -> Type -> Type) (f :: Type -> Type). (Indexable i p, Contravariant f, Apply f) => p a f a -> s -> f s
type IndexedLens' i s a = IndexedLens i s s a a
type IndexedLensLike i (f :: k -> Type) s (t :: k) a (b :: k) = forall (p :: Type -> Type -> Type). Indexable i p => p a f b -> s -> f t
type IndexedLensLike' i (f :: Type -> Type) s a = IndexedLensLike i f s s a a
type IndexedSetter' i s a = IndexedSetter i s s a a
type IndexedTraversal' i s a = IndexedTraversal i s s a a
type IndexedTraversal1 i s t a b = forall (p :: Type -> Type -> Type) (f :: Type -> Type). (Indexable i p, Apply f) => p a f b -> s -> f t
type IndexedTraversal1' i s a = IndexedTraversal1 i s s a a
type Iso' s a = Iso s s a a
type LensLike (f :: k -> Type) s (t :: k) a (b :: k) = a -> f b -> s -> f t
type LensLike' (f :: Type -> Type) s a = LensLike f s s a a
type Optic (p :: k -> k1 -> Type) (f :: k2 -> k1) (s :: k) (t :: k2) (a :: k) (b :: k2) = p a f b -> p s f t
type Optic' (p :: k -> k1 -> Type) (f :: k -> k1) (s :: k) (a :: k) = Optic p f s s a a
type Optical (p :: k -> k1 -> Type) (q :: k2 -> k1 -> Type) (f :: k3 -> k1) (s :: k2) (t :: k3) (a :: k) (b :: k3) = p a f b -> q s f t
type Optical' (p :: k -> k1 -> Type) (q :: k -> k1 -> Type) (f :: k -> k1) (s :: k) (a :: k) = Optical p q f s s a a
type Over (p :: k -> Type -> Type) (f :: k1 -> Type) s (t :: k1) (a :: k) (b :: k1) = p a f b -> s -> f t
type Over' (p :: Type -> Type -> Type) (f :: Type -> Type) s a = Over p f s s a a
type Prism' s a = Prism s s a a
type Review t b = forall (p :: Type -> Type -> Type) (f :: Type -> Type). (Choice p, Bifunctor p, Settable f) => Optic' p f t b
type Setter' s a = Setter s s a a
type Simple (f :: k1 -> k1 -> k2 -> k2 -> k) (s :: k1) (a :: k2) = f s s a a
type Traversal' s a = Traversal s s a a
type Traversal1 s t a b = forall (f :: Type -> Type). Apply f => a -> f b -> s -> f t
type Traversal1' s a = Traversal1 s s a a
class Wrapped s => Rewrapped s t
class (Rewrapped s t, Rewrapped t s) => Rewrapping s t
class Wrapped s where {
    type Unwrapped s;
    type Unwrapped s = GUnwrapped Rep s;
}
_Wrapped' :: Wrapped s => Iso' s (Unwrapped s)
type family Unwrapped s
pattern Unwrapped :: Rewrapped t t => t -> Unwrapped t
pattern Wrapped :: Rewrapped s s => Unwrapped s -> s
_GWrapped' :: forall s (d :: Meta) (c :: Meta) (s' :: Meta) a. (Generic s, D1 d (C1 c (S1 s' (Rec0 a))) ~ Rep s, Unwrapped s ~ GUnwrapped (Rep s)) => Iso' s (Unwrapped s)
_Unwrapped :: Rewrapping s t => Iso (Unwrapped t) (Unwrapped s) t s
_Unwrapped' :: Wrapped s => Iso' (Unwrapped s) s
_Unwrapping :: Rewrapping s t => (Unwrapped s -> s) -> Iso (Unwrapped t) (Unwrapped s) t s
_Unwrapping' :: Wrapped s => (Unwrapped s -> s) -> Iso' (Unwrapped s) s
_Wrapped :: Rewrapping s t => Iso s t (Unwrapped s) (Unwrapped t)
_Wrapping :: Rewrapping s t => (Unwrapped s -> s) -> Iso s t (Unwrapped s) (Unwrapped t)
_Wrapping' :: Wrapped s => (Unwrapped s -> s) -> Iso' s (Unwrapped s)
ala :: (Functor f, Rewrapping s t) => (Unwrapped s -> s) -> ((Unwrapped t -> t) -> f s) -> f (Unwrapped s)
alaf :: (Functor f, Functor g, Rewrapping s t) => (Unwrapped s -> s) -> (f t -> g s) -> f (Unwrapped t) -> g (Unwrapped s)
op :: Wrapped s => (Unwrapped s -> s) -> s -> Unwrapped s
type family Magnified (m :: Type -> Type) :: Type -> Type -> Type
class (Magnified m ~ Magnified n, MonadReader b m, MonadReader a n) => Magnify (m :: Type -> Type) (n :: Type -> Type) b a | m -> b, n -> a, m a -> n, n b -> m
magnify :: Magnify m n b a => ((Functor (Magnified m c), Contravariant (Magnified m c)) => LensLike' (Magnified m c) a b) -> m c -> n c
class (MonadState s m, MonadState t n) => Zoom (m :: Type -> Type) (n :: Type -> Type) s t | m -> s, n -> t, m t -> n, n s -> m
zoom :: Zoom m n s t => LensLike' (Zoomed m c) t s -> m c -> n c
type family Zoomed (m :: Type -> Type) :: Type -> Type -> Type
(&) :: a -> (a -> b) -> b
(<&>) :: Functor f => f a -> (a -> b) -> f b
iall :: FoldableWithIndex i f => (i -> a -> Bool) -> f a -> Bool
iany :: FoldableWithIndex i f => (i -> a -> Bool) -> f a -> Bool
iconcatMap :: FoldableWithIndex i f => (i -> a -> [b]) -> f a -> [b]
ifind :: FoldableWithIndex i f => (i -> a -> Bool) -> f a -> Maybe (i, a)
ifoldlM :: (FoldableWithIndex i f, Monad m) => (i -> b -> a -> m b) -> b -> f a -> m b
ifoldrM :: (FoldableWithIndex i f, Monad m) => (i -> a -> b -> m b) -> b -> f a -> m b
iforM_ :: (FoldableWithIndex i t, Monad m) => t a -> (i -> a -> m b) -> m ()
ifor_ :: (FoldableWithIndex i t, Applicative f) => t a -> (i -> a -> f b) -> f ()
imapM_ :: (FoldableWithIndex i t, Monad m) => (i -> a -> m b) -> t a -> m ()
inone :: FoldableWithIndex i f => (i -> a -> Bool) -> f a -> Bool
itoList :: FoldableWithIndex i f => f a -> [(i, a)]
itraverse_ :: (FoldableWithIndex i t, Applicative f) => (i -> a -> f b) -> t a -> f ()
none :: Foldable f => (a -> Bool) -> f a -> Bool
ifor :: (TraversableWithIndex i t, Applicative f) => t a -> (i -> a -> f b) -> f (t b)
iforM :: (TraversableWithIndex i t, Monad m) => t a -> (i -> a -> m b) -> m (t b)
imapAccumL :: TraversableWithIndex i t => (i -> s -> a -> (s, b)) -> s -> t a -> (s, t b)
imapAccumR :: TraversableWithIndex i t => (i -> s -> a -> (s, b)) -> s -> t a -> (s, t b)
imapM :: (TraversableWithIndex i t, Monad m) => (i -> a -> m b) -> t a -> m (t b)
foldBy :: Foldable t => (a -> a -> a) -> a -> t a -> a
foldMapBy :: Foldable t => (r -> r -> r) -> r -> (a -> r) -> t a -> r
sequenceBy :: Traversable t => (forall x. () => x -> f x) -> (forall x y. () => f (x -> y) -> f x -> f y) -> t (f a) -> f (t a)
traverseBy :: Traversable t => (forall x. () => x -> f x) -> (forall x y. () => f (x -> y) -> f x -> f y) -> (a -> f b) -> t a -> f (t b)
class forall a. () => Functor p a => Bifunctor (p :: Type -> Type -> Type)
bimap :: Bifunctor p => (a -> b) -> (c -> d) -> p a c -> p b d
first :: Bifunctor p => (a -> b) -> p a c -> p b c
second :: Bifunctor p => (b -> c) -> p a b -> p a c
newtype Const a (b :: k)
Const :: a -> Const a (b :: k)
[getConst] :: Const a (b :: k) -> a
class Contravariant (f :: Type -> Type)
contramap :: Contravariant f => (a' -> a) -> f a -> f a'
(>$) :: Contravariant f => b -> f b -> f a
newtype Identity a
Identity :: a -> Identity a
[runIdentity] :: Identity a -> a
class (Functor t, Foldable t) => Traversable (t :: Type -> Type)
traverse :: (Traversable t, Applicative f) => (a -> f b) -> t a -> f (t b)
sequenceA :: (Traversable t, Applicative f) => t (f a) -> f (t a)
mapM :: (Traversable t, Monad m) => (a -> m b) -> t a -> m (t b)
sequence :: (Traversable t, Monad m) => t (m a) -> m (t a)
data (a :: k) :~: (b :: k)
[Refl] :: forall {k} (a :: k). a :~: a
class Foldable f => FoldableWithIndex i (f :: Type -> Type) | f -> i
ifoldMap :: (FoldableWithIndex i f, Monoid m) => (i -> a -> m) -> f a -> m
ifoldMap' :: (FoldableWithIndex i f, Monoid m) => (i -> a -> m) -> f a -> m
ifoldr :: FoldableWithIndex i f => (i -> a -> b -> b) -> b -> f a -> b
ifoldl :: FoldableWithIndex i f => (i -> b -> a -> b) -> b -> f a -> b
ifoldr' :: FoldableWithIndex i f => (i -> a -> b -> b) -> b -> f a -> b
ifoldl' :: FoldableWithIndex i f => (i -> b -> a -> b) -> b -> f a -> b
class Functor f => FunctorWithIndex i (f :: Type -> Type) | f -> i
imap :: FunctorWithIndex i f => (i -> a -> b) -> f a -> f b
class (FunctorWithIndex i t, FoldableWithIndex i t, Traversable t) => TraversableWithIndex i (t :: Type -> Type) | t -> i
itraverse :: (TraversableWithIndex i t, Applicative f) => (i -> a -> f b) -> t a -> f (t b)
class Profunctor p => Choice (p :: Type -> Type -> Type)
left' :: Choice p => p a b -> p (Either a c) (Either b c)
right' :: Choice p => p a b -> p (Either c a) (Either c b)
class Profunctor (p :: Type -> Type -> Type)
dimap :: Profunctor p => (a -> b) -> (c -> d) -> p b c -> p a d
lmap :: Profunctor p => (a -> b) -> p b c -> p a c
rmap :: Profunctor p => (b -> c) -> p a b -> p a c
class (Foldable1 t, Traversable t) => Traversable1 (t :: Type -> Type)
traverse1 :: (Traversable1 t, Apply f) => (a -> f b) -> t a -> f (t b)
data Bool
False :: Bool
True :: Bool
data Double
data Float
data Int
data Word
data Ordering
LT :: Ordering
EQ :: Ordering
GT :: Ordering
data Natural
data Integer
class Monad m => MonadCont (m :: Type -> Type)
callCC :: MonadCont m => ((a -> m b) -> m a) -> m a
label_ :: MonadCont m => m (m a)
cont :: ((a -> r) -> r) -> Cont r a
evalCont :: Cont r r -> r
evalContT :: Monad m => ContT r m r -> m r
mapCont :: (r -> r) -> Cont r a -> Cont r a
mapContT :: forall {k} m (r :: k) a. (m r -> m r) -> ContT r m a -> ContT r m a
runCont :: Cont r a -> (a -> r) -> r
withCont :: ((b -> r) -> a -> r) -> Cont r a -> Cont r b
withContT :: forall {k} b m (r :: k) a. ((b -> m r) -> a -> m r) -> ContT r m a -> ContT r m b
newtype ContT (r :: k) (m :: k -> Type) a
ContT :: ((a -> m r) -> m r) -> ContT (r :: k) (m :: k -> Type) a
[runContT] :: ContT (r :: k) (m :: k -> Type) a -> (a -> m r) -> m r
data ReleaseType
ReleaseEarly :: ReleaseType
ReleaseNormal :: ReleaseType
ReleaseExceptionWith :: SomeException -> ReleaseType
pattern ReleaseException :: ReleaseType
mkAcquire :: IO a -> (a -> IO ()) -> Acquire a
mkAcquireType :: IO a -> (a -> ReleaseType -> IO ()) -> Acquire a
with :: MonadUnliftIO m => Acquire a -> (a -> m b) -> m b
allocateAcquire :: MonadResource m => Acquire a -> m (ReleaseKey, a)
withAcquire :: MonadUnliftIO m => Acquire a -> (a -> m b) -> m b
data IORef a
class MonadIO m => MonadUnliftIO (m :: Type -> Type)
withRunInIO :: MonadUnliftIO m => ((forall a. () => m a -> IO a) -> IO b) -> m b
registerDelay :: MonadIO m => Int -> m (TVar Bool)
threadDelay :: MonadIO m => Int -> m ()
threadWaitRead :: MonadIO m => Fd -> m ()
threadWaitWrite :: MonadIO m => Fd -> m ()
data STM a
data TVar a
data ThreadId
atomically :: MonadIO m => STM a -> m a
myThreadId :: MonadIO m => m ThreadId
newTVar :: a -> STM (TVar a)
newTVarIO :: MonadIO m => a -> m (TVar a)
readTVar :: TVar a -> STM a
readTVarIO :: MonadIO m => TVar a -> m a
throwTo :: (Exception e, MonadIO m) => ThreadId -> e -> m ()
withMVar :: MonadUnliftIO m => MVar a -> (a -> m b) -> m b
writeTVar :: TVar a -> a -> STM ()
all :: Foldable t => (a -> Bool) -> t a -> Bool
any :: Foldable t => (a -> Bool) -> t a -> Bool
break :: (a -> Bool) -> [a] -> ([a], [a])
concat :: Foldable t => t [a] -> [a]
concatMap :: Foldable t => (a -> [b]) -> t a -> [b]
drop :: Int -> [a] -> [a]
dropWhile :: (a -> Bool) -> [a] -> [a]
filter :: (a -> Bool) -> [a] -> [a]
map :: (a -> b) -> [a] -> [b]
replicate :: Int -> a -> [a]
span :: (a -> Bool) -> [a] -> ([a], [a])
take :: Int -> [a] -> [a]
takeWhile :: (a -> Bool) -> [a] -> [a]
unwords :: [String] -> String
words :: String -> [String]
zip :: [a] -> [b] -> [(a, b)]
zipWith :: (a -> b -> c) -> [a] -> [b] -> [c]
decodeUtf8' :: ByteString -> Either UnicodeException Text
decodeUtf8With :: OnDecodeError -> ByteString -> Text
encodeUtf8 :: Text -> ByteString
lenientDecode :: OnDecodeError
type BDeque = Deque MVector
data Deque (v :: Type -> Type -> Type) s a
type SDeque = Deque MVector
type UDeque = Deque MVector
asBDeque :: BDeque s a -> BDeque s a
asSDeque :: SDeque s a -> SDeque s a
asUDeque :: UDeque s a -> UDeque s a
dequeToList :: forall (v :: Type -> Type -> Type) a m. (MVector v a, PrimMonad m) => Deque v (PrimState m) a -> m [a]
dequeToVector :: forall v' a (v :: Type -> Type -> Type) m. (Vector v' a, MVector v a, PrimMonad m) => Deque v (PrimState m) a -> m (v' a)
foldlDeque :: forall (v :: Type -> Type -> Type) a m acc. (MVector v a, PrimMonad m) => (acc -> a -> m acc) -> acc -> Deque v (PrimState m) a -> m acc
foldrDeque :: forall (v :: Type -> Type -> Type) a m acc. (MVector v a, PrimMonad m) => (a -> acc -> m acc) -> acc -> Deque v (PrimState m) a -> m acc
freezeDeque :: (Vector v a, PrimMonad m) => Deque (Mutable v) (PrimState m) a -> m (v a)
getDequeSize :: forall m (v :: Type -> Type -> Type) a. PrimMonad m => Deque v (PrimState m) a -> m Int
newDeque :: forall (v :: Type -> Type -> Type) a m. (MVector v a, PrimMonad m) => m (Deque v (PrimState m) a)
popBackDeque :: forall (v :: Type -> Type -> Type) a m. (MVector v a, PrimMonad m) => Deque v (PrimState m) a -> m (Maybe a)
popFrontDeque :: forall (v :: Type -> Type -> Type) a m. (MVector v a, PrimMonad m) => Deque v (PrimState m) a -> m (Maybe a)
pushBackDeque :: forall (v :: Type -> Type -> Type) a m. (MVector v a, PrimMonad m) => Deque v (PrimState m) a -> a -> m ()
pushFrontDeque :: forall (v :: Type -> Type -> Type) a m. (MVector v a, PrimMonad m) => Deque v (PrimState m) a -> a -> m ()
class Display a
display :: Display a => a -> Utf8Builder
textDisplay :: Display a => a -> Text
newtype Utf8Builder
Utf8Builder :: Builder -> Utf8Builder
[getUtf8Builder] :: Utf8Builder -> Builder
displayBytesUtf8 :: ByteString -> Utf8Builder
displayShow :: Show a => a -> Utf8Builder
utf8BuilderToLazyText :: Utf8Builder -> Text
utf8BuilderToText :: Utf8Builder -> Text
writeFileUtf8Builder :: MonadIO m => FilePath -> Utf8Builder -> m ()
exitFailure :: MonadIO m => m a
exitSuccess :: MonadIO m => m a
exitWith :: MonadIO m => ExitCode -> m a
asIO :: IO a -> IO a
foldMapM :: (Monad m, Monoid w, Foldable t) => (a -> m w) -> t a -> m w
forMaybeA :: Applicative f => [a] -> (a -> f (Maybe b)) -> f [b]
forMaybeM :: Monad m => [a] -> (a -> m (Maybe b)) -> m [b]
fromFirst :: a -> First a -> a
mapLeft :: (a1 -> a2) -> Either a1 b -> Either a2 b
mapMaybeA :: Applicative f => (a -> f (Maybe b)) -> [a] -> f [b]
mapMaybeM :: Monad m => (a -> m (Maybe b)) -> [a] -> m [b]
nubOrd :: Ord a => [a] -> [a]
unlessM :: Monad m => m Bool -> m () -> m ()
whenM :: Monad m => m Bool -> m () -> m ()
hPutBuilder :: MonadIO m => Handle -> Builder -> m ()
readFileBinary :: MonadIO m => FilePath -> m ByteString
readFileUtf8 :: MonadIO m => FilePath -> m Text
withLazyFile :: MonadUnliftIO m => FilePath -> (ByteString -> m a) -> m a
withLazyFileUtf8 :: MonadUnliftIO m => FilePath -> (Text -> m a) -> m a
writeFileBinary :: MonadIO m => FilePath -> ByteString -> m ()
writeFileUtf8 :: MonadIO m => FilePath -> Text -> m ()
data GLogFunc msg
class HasGLogFunc env where {
    type GMsg env;
}
gLogFuncL :: HasGLogFunc env => Lens' env (GLogFunc (GMsg env))
type family GMsg env
class HasLogFunc env
logFuncL :: HasLogFunc env => Lens' env LogFunc
class HasLogLevel msg
getLogLevel :: HasLogLevel msg => msg -> LogLevel
class HasLogSource msg
getLogSource :: HasLogSource msg => msg -> LogSource
data LogLevel
LevelDebug :: LogLevel
LevelInfo :: LogLevel
LevelWarn :: LogLevel
LevelError :: LogLevel
LevelOther :: !Text -> LogLevel
data LogFunc
data LogOptions
type LogSource = Text
contramapGLogFunc :: (a -> b) -> GLogFunc b -> GLogFunc a
contramapMaybeGLogFunc :: (a -> Maybe b) -> GLogFunc b -> GLogFunc a
displayCallStack :: CallStack -> Utf8Builder
gLogFuncClassic :: (HasLogLevel msg, HasLogSource msg, Display msg) => LogFunc -> GLogFunc msg
glog :: (MonadIO m, HasCallStack, HasGLogFunc env, MonadReader env m) => GMsg env -> m ()
logDebug :: (MonadIO m, MonadReader env m, HasLogFunc env, HasCallStack) => Utf8Builder -> m ()
logDebugS :: (MonadIO m, MonadReader env m, HasLogFunc env, HasCallStack) => LogSource -> Utf8Builder -> m ()
logError :: (MonadIO m, MonadReader env m, HasLogFunc env, HasCallStack) => Utf8Builder -> m ()
logErrorS :: (MonadIO m, MonadReader env m, HasLogFunc env, HasCallStack) => LogSource -> Utf8Builder -> m ()
logFuncAccentColorsL :: HasLogFunc env => SimpleGetter env (Int -> Utf8Builder)
logFuncLogLevelColorsL :: HasLogFunc env => SimpleGetter env (LogLevel -> Utf8Builder)
logFuncSecondaryColorL :: HasLogFunc env => SimpleGetter env Utf8Builder
logFuncUseColorL :: HasLogFunc env => SimpleGetter env Bool
logGeneric :: (MonadIO m, MonadReader env m, HasLogFunc env, HasCallStack) => LogSource -> LogLevel -> Utf8Builder -> m ()
logInfo :: (MonadIO m, MonadReader env m, HasLogFunc env, HasCallStack) => Utf8Builder -> m ()
logInfoS :: (MonadIO m, MonadReader env m, HasLogFunc env, HasCallStack) => LogSource -> Utf8Builder -> m ()
logOptionsHandle :: MonadIO m => Handle -> Bool -> m LogOptions
logOptionsMemory :: MonadIO m => m (IORef Builder, LogOptions)
logOther :: (MonadIO m, MonadReader env m, HasLogFunc env, HasCallStack) => Text -> Utf8Builder -> m ()
logOtherS :: (MonadIO m, MonadReader env m, HasLogFunc env, HasCallStack) => Text -> LogSource -> Utf8Builder -> m ()
logSticky :: (MonadIO m, HasCallStack, MonadReader env m, HasLogFunc env) => Utf8Builder -> m ()
logStickyDone :: (MonadIO m, HasCallStack, MonadReader env m, HasLogFunc env) => Utf8Builder -> m ()
logWarn :: (MonadIO m, MonadReader env m, HasLogFunc env, HasCallStack) => Utf8Builder -> m ()
logWarnS :: (MonadIO m, MonadReader env m, HasLogFunc env, HasCallStack) => LogSource -> Utf8Builder -> m ()
mkGLogFunc :: (CallStack -> msg -> IO ()) -> GLogFunc msg
mkLogFunc :: (CallStack -> LogSource -> LogLevel -> Utf8Builder -> IO ()) -> LogFunc
newLogFunc :: (MonadIO n, MonadIO m) => LogOptions -> n (LogFunc, m ())
noLogging :: (HasLogFunc env, MonadReader env m) => m a -> m a
setLogAccentColors :: (Int -> Utf8Builder) -> LogOptions -> LogOptions
setLogFormat :: (Utf8Builder -> Utf8Builder) -> LogOptions -> LogOptions
setLogLevelColors :: (LogLevel -> Utf8Builder) -> LogOptions -> LogOptions
setLogMinLevel :: LogLevel -> LogOptions -> LogOptions
setLogMinLevelIO :: IO LogLevel -> LogOptions -> LogOptions
setLogSecondaryColor :: Utf8Builder -> LogOptions -> LogOptions
setLogTerminal :: Bool -> LogOptions -> LogOptions
setLogUseColor :: Bool -> LogOptions -> LogOptions
setLogUseLoc :: Bool -> LogOptions -> LogOptions
setLogUseTime :: Bool -> LogOptions -> LogOptions
setLogVerboseFormat :: Bool -> LogOptions -> LogOptions
setLogVerboseFormatIO :: IO Bool -> LogOptions -> LogOptions
withLogFunc :: MonadUnliftIO m => LogOptions -> (LogFunc -> m a) -> m a
class HasStateRef s env | env -> s
stateRefL :: HasStateRef s env => Lens' env (SomeRef s)
class HasWriteRef w env | env -> w
writeRefL :: HasWriteRef w env => Lens' env (SomeRef w)
data SomeRef a
liftRIO :: (MonadIO m, MonadReader env m) => RIO env a -> m a
mapRIO :: (outer -> inner) -> RIO inner a -> RIO outer a
modifySomeRef :: MonadIO m => SomeRef a -> (a -> a) -> m ()
newSomeRef :: MonadIO m => a -> m (SomeRef a)
newUnboxedSomeRef :: (MonadIO m, Unbox a) => a -> m (SomeRef a)
readSomeRef :: MonadIO m => SomeRef a -> m a
runRIO :: MonadIO m => env -> RIO env a -> m a
writeSomeRef :: MonadIO m => SomeRef a -> a -> m ()
type GVector = Vector
type LByteString = ByteString
type LText = Text
type SVector = Vector
type UVector = Vector
fromStrictBytes :: ByteString -> LByteString
sappend :: Semigroup s => s -> s -> s
toStrictBytes :: LByteString -> ByteString
yieldThread :: MonadIO m => m ()
data SimpleApp
mkSimpleApp :: MonadIO m => LogFunc -> Maybe ProcessContext -> m SimpleApp
runSimpleApp :: MonadIO m => RIO SimpleApp a -> m a
decodeUtf8Lenient :: ByteString -> Text
tshow :: Show a => a -> Text
trace :: Text -> a -> a
traceDisplay :: Display a => a -> b -> b
traceDisplayEvent :: Display a => a -> b -> b
traceDisplayEventIO :: (Display a, MonadIO m) => a -> m ()
traceDisplayIO :: (Display a, MonadIO m) => a -> m ()
traceDisplayId :: Display a => a -> a
traceDisplayM :: (Display a, Applicative f) => a -> f ()
traceDisplayMarker :: Display a => a -> b -> b
traceDisplayMarkerIO :: (Display a, MonadIO m) => a -> m ()
traceDisplayStack :: Display a => a -> b -> b
traceEvent :: Text -> a -> a
traceEventIO :: MonadIO m => Text -> m ()
traceIO :: MonadIO m => Text -> m ()
traceId :: Text -> Text
traceM :: Applicative f => Text -> f ()
traceMarker :: Text -> a -> a
traceMarkerIO :: MonadIO m => Text -> m ()
traceShow :: Show a => a -> b -> b
traceShowEvent :: Show a => a -> b -> b
traceShowEventIO :: (Show a, MonadIO m) => a -> m ()
traceShowIO :: (Show a, MonadIO m) => a -> m ()
traceShowId :: Show a => a -> a
traceShowM :: (Show a, Applicative f) => a -> f ()
traceShowMarker :: Show a => a -> b -> b
traceShowMarkerIO :: (Show a, MonadIO m) => a -> m ()
traceShowStack :: Show a => a -> b -> b
traceStack :: Text -> a -> a
type IOURef = URef PrimState IO
data URef s a
modifyURef :: (PrimMonad m, Unbox a) => URef (PrimState m) a -> (a -> a) -> m ()
newURef :: (PrimMonad m, Unbox a) => a -> m (URef (PrimState m) a)
readURef :: (PrimMonad m, Unbox a) => URef (PrimState m) a -> m a
writeURef :: (PrimMonad m, Unbox a) => URef (PrimState m) a -> a -> m ()
pollSTM :: Async a -> STM (Maybe (Either SomeException a))
waitAnyCatchSTM :: [Async a] -> STM (Async a, Either SomeException a)
waitAnySTM :: [Async a] -> STM (Async a, a)
waitBothSTM :: Async a -> Async b -> STM (a, b)
waitCatchSTM :: Async a -> STM (Either SomeException a)
waitEitherCatchSTM :: Async a -> Async b -> STM (Either (Either SomeException a) (Either SomeException b))
waitEitherSTM :: Async a -> Async b -> STM (Either a b)
waitEitherSTM_ :: Async a -> Async b -> STM ()
waitSTM :: Async a -> STM a
optional :: Alternative f => f a -> f (Maybe a)
(>>>) :: forall {k} cat (a :: k) (b :: k) (c :: k). Category cat => cat a b -> cat b c -> cat a c
(<$!>) :: Monad m => (a -> b) -> m a -> m b
(<=<) :: Monad m => (b -> m c) -> (a -> m b) -> a -> m c
(>=>) :: Monad m => (a -> m b) -> (b -> m c) -> a -> m c
filterM :: Applicative m => (a -> m Bool) -> [a] -> m [a]
foldM :: (Foldable t, Monad m) => (b -> a -> m b) -> b -> t a -> m b
foldM_ :: (Foldable t, Monad m) => (b -> a -> m b) -> b -> t a -> m ()
forever :: Applicative f => f a -> f b
mfilter :: MonadPlus m => (a -> Bool) -> m a -> m a
replicateM_ :: Applicative m => Int -> m a -> m ()
unless :: Applicative f => Bool -> f () -> f ()
zipWithM :: Applicative m => (a -> b -> m c) -> [a] -> [b] -> m [c]
zipWithM_ :: Applicative m => (a -> b -> m c) -> [a] -> [b] -> m ()
biList :: Bifoldable t => t a a -> [a]
biall :: Bifoldable t => (a -> Bool) -> (b -> Bool) -> t a b -> Bool
biand :: Bifoldable t => t Bool Bool -> Bool
biany :: Bifoldable t => (a -> Bool) -> (b -> Bool) -> t a b -> Bool
biasum :: (Bifoldable t, Alternative f) => t (f a) (f a) -> f a
biconcat :: Bifoldable t => t [a] [a] -> [a]
biconcatMap :: Bifoldable t => (a -> [c]) -> (b -> [c]) -> t a b -> [c]
bielem :: (Bifoldable t, Eq a) => a -> t a a -> Bool
bifind :: Bifoldable t => (a -> Bool) -> t a a -> Maybe a
bifoldl' :: Bifoldable t => (a -> b -> a) -> (a -> c -> a) -> a -> t b c -> a
bifoldl1 :: Bifoldable t => (a -> a -> a) -> t a a -> a
bifoldlM :: (Bifoldable t, Monad m) => (a -> b -> m a) -> (a -> c -> m a) -> a -> t b c -> m a
bifoldr' :: Bifoldable t => (a -> c -> c) -> (b -> c -> c) -> c -> t a b -> c
bifoldr1 :: Bifoldable t => (a -> a -> a) -> t a a -> a
bifoldrM :: (Bifoldable t, Monad m) => (a -> c -> m c) -> (b -> c -> m c) -> c -> t a b -> m c
bifor_ :: (Bifoldable t, Applicative f) => t a b -> (a -> f c) -> (b -> f d) -> f ()
bilength :: Bifoldable t => t a b -> Int
bimaximum :: (Bifoldable t, Ord a) => t a a -> a
bimaximumBy :: Bifoldable t => (a -> a -> Ordering) -> t a a -> a
biminimum :: (Bifoldable t, Ord a) => t a a -> a
biminimumBy :: Bifoldable t => (a -> a -> Ordering) -> t a a -> a
binotElem :: (Bifoldable t, Eq a) => a -> t a a -> Bool
binull :: Bifoldable t => t a b -> Bool
bior :: Bifoldable t => t Bool Bool -> Bool
biproduct :: (Bifoldable t, Num a) => t a a -> a
bisequence_ :: (Bifoldable t, Applicative f) => t (f a) (f b) -> f ()
bisum :: (Bifoldable t, Num a) => t a a -> a
bitraverse_ :: (Bifoldable t, Applicative f) => (a -> f c) -> (b -> f d) -> t a b -> f ()
bifor :: (Bitraversable t, Applicative f) => t a b -> (a -> f c) -> (b -> f d) -> f (t c d)
bimapAccumL :: Bitraversable t => (a -> b -> (a, c)) -> (a -> d -> (a, e)) -> a -> t b d -> (a, t c e)
bimapAccumR :: Bitraversable t => (a -> b -> (a, c)) -> (a -> d -> (a, e)) -> a -> t b d -> (a, t c e)
bisequence :: (Bitraversable t, Applicative f) => t (f a) (f b) -> f (t a b)
either :: (a -> c) -> (b -> c) -> Either a b -> c
fromLeft :: a -> Either a b -> a
fromRight :: b -> Either a b -> b
isLeft :: Either a b -> Bool
isRight :: Either a b -> Bool
lefts :: [Either a b] -> [a]
partitionEithers :: [Either a b] -> ([a], [b])
rights :: [Either a b] -> [b]
and :: Foldable t => t Bool -> Bool
asum :: (Foldable t, Alternative f) => t (f a) -> f a
forM_ :: (Foldable t, Monad m) => t a -> (a -> m b) -> m ()
for_ :: (Foldable t, Applicative f) => t a -> (a -> f b) -> f ()
mapM_ :: (Foldable t, Monad m) => (a -> m b) -> t a -> m ()
msum :: (Foldable t, MonadPlus m) => t (m a) -> m a
notElem :: (Foldable t, Eq a) => a -> t a -> Bool
or :: Foldable t => t Bool -> Bool
sequenceA_ :: (Foldable t, Applicative f) => t (f a) -> f ()
sequence_ :: (Foldable t, Monad m) => t (m a) -> m ()
traverse_ :: (Foldable t, Applicative f) => (a -> f b) -> t a -> f ()
fix :: (a -> a) -> a
on :: (b -> b -> c) -> (a -> b) -> a -> a -> c
($>) :: Functor f => f a -> b -> f b
(<$>) :: Functor f => (a -> b) -> f a -> f b
catMaybes :: [Maybe a] -> [a]
fromMaybe :: a -> Maybe a -> a
isJust :: Maybe a -> Bool
isNothing :: Maybe a -> Bool
listToMaybe :: [a] -> Maybe a
mapMaybe :: (a -> Maybe b) -> [a] -> [b]
maybe :: b -> (a -> b) -> Maybe a -> b
maybeToList :: Maybe a -> [a]
comparing :: Ord a => (b -> a) -> b -> b -> Ordering
for :: (Traversable t, Applicative f) => t a -> (a -> f b) -> f (t b)
forM :: (Traversable t, Monad m) => t a -> (a -> m b) -> m (t b)
curry :: ((a, b) -> c) -> a -> b -> c
fst :: (a, b) -> a
snd :: (a, b) -> b
uncurry :: (a -> b -> c) -> (a, b) -> c
($!) :: (a -> b) -> a -> b
(=<<) :: Monad m => (a -> m b) -> m a -> m b
absurd :: Void -> a
asTypeOf :: a -> a -> a
const :: a -> b -> a
flip :: (a -> b -> c) -> b -> a -> c
id :: a -> a
liftA :: Applicative f => (a -> b) -> f a -> f b
liftA3 :: Applicative f => (a -> b -> c -> d) -> f a -> f b -> f c -> f d
liftM :: Monad m => (a1 -> r) -> m a1 -> m r
liftM2 :: Monad m => (a1 -> a2 -> r) -> m a1 -> m a2 -> m r
when :: Applicative f => Bool -> f () -> f ()
error :: HasCallStack => [Char] -> a
undefined :: HasCallStack => a
asyncExceptionFromException :: Exception e => SomeException -> Maybe e
asyncExceptionToException :: Exception e => e -> SomeException
stderr :: Handle
stdin :: Handle
stdout :: Handle
lookup :: Eq a => a -> [(a, b)] -> Maybe b
subtract :: Num a => a -> a -> a
(^) :: (Num a, Integral b) => a -> b -> a
(^^) :: (Fractional a, Integral b) => a -> b -> a
even :: Integral a => a -> Bool
gcd :: Integral a => a -> a -> a
lcm :: Integral a => a -> a -> a
odd :: Integral a => a -> Bool
runST :: (forall s. () => ST s a) -> a
byteSwap16 :: Word16 -> Word16
byteSwap32 :: Word32 -> Word32
byteSwap64 :: Word64 -> Word64
readMaybe :: Read a => String -> Maybe a
fromShort :: ShortByteString -> ByteString
toShort :: ByteString -> ShortByteString
($!!) :: NFData a => (a -> b) -> a -> b
force :: NFData a => a -> a
(&&) :: Bool -> Bool -> Bool
not :: Bool -> Bool
(||) :: Bool -> Bool -> Bool
asks :: MonadReader r m => (r -> a) -> m a
flushTBQueue :: TBQueue a -> STM [a]
isEmptyTBQueue :: TBQueue a -> STM Bool
isFullTBQueue :: TBQueue a -> STM Bool
lengthTBQueue :: TBQueue a -> STM Natural
newTBQueue :: Natural -> STM (TBQueue a)
peekTBQueue :: TBQueue a -> STM a
readTBQueue :: TBQueue a -> STM a
tryPeekTBQueue :: TBQueue a -> STM (Maybe a)
tryReadTBQueue :: TBQueue a -> STM (Maybe a)
unGetTBQueue :: TBQueue a -> a -> STM ()
writeTBQueue :: TBQueue a -> a -> STM ()
cloneTChan :: TChan a -> STM (TChan a)
dupTChan :: TChan a -> STM (TChan a)
isEmptyTChan :: TChan a -> STM Bool
newBroadcastTChan :: STM (TChan a)
newTChan :: STM (TChan a)
peekTChan :: TChan a -> STM a
readTChan :: TChan a -> STM a
tryPeekTChan :: TChan a -> STM (Maybe a)
tryReadTChan :: TChan a -> STM (Maybe a)
unGetTChan :: TChan a -> a -> STM ()
writeTChan :: TChan a -> a -> STM ()
isEmptyTMVar :: TMVar a -> STM Bool
newEmptyTMVar :: STM (TMVar a)
newTMVar :: a -> STM (TMVar a)
putTMVar :: TMVar a -> a -> STM ()
readTMVar :: TMVar a -> STM a
swapTMVar :: TMVar a -> a -> STM a
takeTMVar :: TMVar a -> STM a
tryPutTMVar :: TMVar a -> a -> STM Bool
tryReadTMVar :: TMVar a -> STM (Maybe a)
tryTakeTMVar :: TMVar a -> STM (Maybe a)
writeTMVar :: TMVar a -> a -> STM ()
isEmptyTQueue :: TQueue a -> STM Bool
newTQueue :: STM (TQueue a)
peekTQueue :: TQueue a -> STM a
readTQueue :: TQueue a -> STM a
tryPeekTQueue :: TQueue a -> STM (Maybe a)
tryReadTQueue :: TQueue a -> STM (Maybe a)
unGetTQueue :: TQueue a -> a -> STM ()
writeTQueue :: TQueue a -> a -> STM ()
modifyTVar :: TVar a -> (a -> a) -> STM ()
modifyTVar' :: TVar a -> (a -> a) -> STM ()
stateTVar :: TVar s -> (s -> (a, s)) -> STM a
swapTVar :: TVar a -> a -> STM a
encodeUtf8Builder :: Text -> Builder
runReader :: Reader r a -> r -> a
dupChan :: MonadIO m => Chan a -> m (Chan a)
getChanContents :: MonadIO m => Chan a -> m [a]
newChan :: MonadIO m => m (Chan a)
readChan :: MonadIO m => Chan a -> m a
writeChan :: MonadIO m => Chan a -> a -> m ()
writeList2Chan :: MonadIO m => Chan a -> [a] -> m ()
isCurrentThreadBound :: MonadIO m => m Bool
bracket :: MonadUnliftIO m => m a -> (a -> m b) -> (a -> m c) -> m c
bracketOnError :: MonadUnliftIO m => m a -> (a -> m b) -> (a -> m c) -> m c
bracketOnError_ :: MonadUnliftIO m => m a -> m b -> m c -> m c
bracket_ :: MonadUnliftIO m => m a -> m b -> m c -> m c
catch :: (MonadUnliftIO m, Exception e) => m a -> (e -> m a) -> m a
catchAny :: MonadUnliftIO m => m a -> (SomeException -> m a) -> m a
catchAnyDeep :: (NFData a, MonadUnliftIO m) => m a -> (SomeException -> m a) -> m a
catchDeep :: (MonadUnliftIO m, Exception e, NFData a) => m a -> (e -> m a) -> m a
catchJust :: (MonadUnliftIO m, Exception e) => (e -> Maybe b) -> m a -> (b -> m a) -> m a
catchSyncOrAsync :: (MonadUnliftIO m, Exception e) => m a -> (e -> m a) -> m a
catches :: MonadUnliftIO m => m a -> [Handler m a] -> m a
catchesDeep :: (MonadUnliftIO m, NFData a) => m a -> [Handler m a] -> m a
evaluate :: MonadIO m => a -> m a
evaluateDeep :: (MonadIO m, NFData a) => a -> m a
finally :: MonadUnliftIO m => m a -> m b -> m a
fromEither :: (Exception e, MonadIO m) => Either e a -> m a
fromEitherIO :: (Exception e, MonadIO m) => IO (Either e a) -> m a
fromEitherM :: (Exception e, MonadIO m) => m (Either e a) -> m a
fromExceptionUnwrap :: Exception e => SomeException -> Maybe e
handle :: (MonadUnliftIO m, Exception e) => (e -> m a) -> m a -> m a
handleAny :: MonadUnliftIO m => (SomeException -> m a) -> m a -> m a
handleAnyDeep :: (MonadUnliftIO m, NFData a) => (SomeException -> m a) -> m a -> m a
handleDeep :: (MonadUnliftIO m, Exception e, NFData a) => (e -> m a) -> m a -> m a
handleIO :: MonadUnliftIO m => (IOException -> m a) -> m a -> m a
handleJust :: (MonadUnliftIO m, Exception e) => (e -> Maybe b) -> (b -> m a) -> m a -> m a
handleSyncOrAsync :: (MonadUnliftIO m, Exception e) => (e -> m a) -> m a -> m a
impureThrow :: Exception e => e -> a
isAsyncException :: Exception e => e -> Bool
isSyncException :: Exception e => e -> Bool
mapExceptionM :: (Exception e1, Exception e2, MonadUnliftIO m) => (e1 -> e2) -> m a -> m a
mask :: MonadUnliftIO m => ((forall a. () => m a -> m a) -> m b) -> m b
mask_ :: MonadUnliftIO m => m a -> m a
onException :: MonadUnliftIO m => m a -> m b -> m a
pureTry :: a -> Either SomeException a
pureTryDeep :: NFData a => a -> Either SomeException a
stringException :: HasCallStack => String -> StringException
throwIO :: (MonadIO m, Exception e) => e -> m a
throwString :: (MonadIO m, HasCallStack) => String -> m a
toAsyncException :: Exception e => e -> SomeException
toSyncException :: Exception e => e -> SomeException
tryAny :: MonadUnliftIO m => m a -> m (Either SomeException a)
tryAnyDeep :: (MonadUnliftIO m, NFData a) => m a -> m (Either SomeException a)
tryDeep :: (MonadUnliftIO m, Exception e, NFData a) => m a -> m (Either e a)
tryIO :: MonadUnliftIO m => m a -> m (Either IOException a)
tryJust :: (MonadUnliftIO m, Exception e) => (e -> Maybe b) -> m a -> m (Either b a)
trySyncOrAsync :: (MonadUnliftIO m, Exception e) => m a -> m (Either e a)
uninterruptibleMask :: MonadUnliftIO m => ((forall a. () => m a -> m a) -> m b) -> m b
uninterruptibleMask_ :: MonadUnliftIO m => m a -> m a
withException :: (MonadUnliftIO m, Exception e) => m a -> (e -> m b) -> m a
getMonotonicTime :: MonadIO m => m Double
hClose :: MonadIO m => Handle -> m ()
hFileSize :: MonadIO m => Handle -> m Integer
hFlush :: MonadIO m => Handle -> m ()
hGetBuffering :: MonadIO m => Handle -> m BufferMode
hGetEcho :: MonadIO m => Handle -> m Bool
hIsClosed :: MonadIO m => Handle -> m Bool
hIsEOF :: MonadIO m => Handle -> m Bool
hIsOpen :: MonadIO m => Handle -> m Bool
hIsReadable :: MonadIO m => Handle -> m Bool
hIsSeekable :: MonadIO m => Handle -> m Bool
hIsTerminalDevice :: MonadIO m => Handle -> m Bool
hIsWritable :: MonadIO m => Handle -> m Bool
hReady :: MonadIO m => Handle -> m Bool
hSeek :: MonadIO m => Handle -> SeekMode -> Integer -> m ()
hSetBuffering :: MonadIO m => Handle -> BufferMode -> m ()
hSetEcho :: MonadIO m => Handle -> Bool -> m ()
hSetFileSize :: MonadIO m => Handle -> Integer -> m ()
hTell :: MonadIO m => Handle -> m Integer
hWaitForInput :: MonadIO m => Handle -> Int -> m Bool
openFile :: MonadIO m => FilePath -> IOMode -> m Handle
withBinaryFile :: MonadUnliftIO m => FilePath -> IOMode -> (Handle -> m a) -> m a
withFile :: MonadUnliftIO m => FilePath -> IOMode -> (Handle -> m a) -> m a
atomicModifyIORef :: MonadIO m => IORef a -> (a -> (a, b)) -> m b
atomicModifyIORef' :: MonadIO m => IORef a -> (a -> (a, b)) -> m b
atomicWriteIORef :: MonadIO m => IORef a -> a -> m ()
mkWeakIORef :: MonadUnliftIO m => IORef a -> m () -> m (Weak (IORef a))
modifyIORef :: MonadIO m => IORef a -> (a -> a) -> m ()
modifyIORef' :: MonadIO m => IORef a -> (a -> a) -> m ()
newIORef :: MonadIO m => a -> m (IORef a)
readIORef :: MonadIO m => IORef a -> m a
writeIORef :: MonadIO m => IORef a -> a -> m ()
asyncBound :: MonadUnliftIO m => m a -> m (Async a)
asyncOn :: MonadUnliftIO m => Int -> m a -> m (Async a)
asyncOnWithUnmask :: MonadUnliftIO m => Int -> ((forall b. () => m b -> m b) -> m a) -> m (Async a)
asyncWithUnmask :: MonadUnliftIO m => ((forall b. () => m b -> m b) -> m a) -> m (Async a)
cancel :: MonadIO m => Async a -> m ()
cancelWith :: (Exception e, MonadIO m) => Async a -> e -> m ()
conc :: m a -> Conc m a
concurrently :: MonadUnliftIO m => m a -> m b -> m (a, b)
concurrently_ :: MonadUnliftIO m => m a -> m b -> m ()
forConcurrently :: (MonadUnliftIO m, Traversable t) => t a -> (a -> m b) -> m (t b)
forConcurrently_ :: (MonadUnliftIO m, Foldable f) => f a -> (a -> m b) -> m ()
link :: MonadIO m => Async a -> m ()
link2 :: MonadIO m => Async a -> Async b -> m ()
mapConcurrently :: (MonadUnliftIO m, Traversable t) => (a -> m b) -> t a -> m (t b)
mapConcurrently_ :: (MonadUnliftIO m, Foldable f) => (a -> m b) -> f a -> m ()
poll :: MonadIO m => Async a -> m (Maybe (Either SomeException a))
pooledForConcurrently :: (MonadUnliftIO m, Traversable t) => t a -> (a -> m b) -> m (t b)
pooledForConcurrentlyN :: (MonadUnliftIO m, Traversable t) => Int -> t a -> (a -> m b) -> m (t b)
pooledForConcurrentlyN_ :: (MonadUnliftIO m, Foldable t) => Int -> t a -> (a -> m b) -> m ()
pooledForConcurrently_ :: (MonadUnliftIO m, Foldable f) => f a -> (a -> m b) -> m ()
pooledMapConcurrently :: (MonadUnliftIO m, Traversable t) => (a -> m b) -> t a -> m (t b)
pooledMapConcurrentlyN :: (MonadUnliftIO m, Traversable t) => Int -> (a -> m b) -> t a -> m (t b)
pooledMapConcurrentlyN_ :: (MonadUnliftIO m, Foldable f) => Int -> (a -> m b) -> f a -> m ()
pooledMapConcurrently_ :: (MonadUnliftIO m, Foldable f) => (a -> m b) -> f a -> m ()
pooledReplicateConcurrently :: MonadUnliftIO m => Int -> m a -> m [a]
pooledReplicateConcurrentlyN :: MonadUnliftIO m => Int -> Int -> m a -> m [a]
pooledReplicateConcurrentlyN_ :: MonadUnliftIO m => Int -> Int -> m a -> m ()
pooledReplicateConcurrently_ :: MonadUnliftIO m => Int -> m a -> m ()
race :: MonadUnliftIO m => m a -> m b -> m (Either a b)
race_ :: MonadUnliftIO m => m a -> m b -> m ()
replicateConcurrently :: MonadUnliftIO f => Int -> f a -> f [a]
replicateConcurrently_ :: (Applicative m, MonadUnliftIO m) => Int -> m a -> m ()
runConc :: MonadUnliftIO m => Conc m a -> m a
uninterruptibleCancel :: MonadIO m => Async a -> m ()
wait :: MonadIO m => Async a -> m a
waitAny :: MonadIO m => [Async a] -> m (Async a, a)
waitAnyCancel :: MonadIO m => [Async a] -> m (Async a, a)
waitAnyCatch :: MonadIO m => [Async a] -> m (Async a, Either SomeException a)
waitAnyCatchCancel :: MonadIO m => [Async a] -> m (Async a, Either SomeException a)
waitBoth :: MonadIO m => Async a -> Async b -> m (a, b)
waitCatch :: MonadIO m => Async a -> m (Either SomeException a)
waitEither :: MonadIO m => Async a -> Async b -> m (Either a b)
waitEitherCancel :: MonadIO m => Async a -> Async b -> m (Either a b)
waitEitherCatch :: MonadIO m => Async a -> Async b -> m (Either (Either SomeException a) (Either SomeException b))
waitEitherCatchCancel :: MonadIO m => Async a -> Async b -> m (Either (Either SomeException a) (Either SomeException b))
waitEither_ :: MonadIO m => Async a -> Async b -> m ()
withAsync :: MonadUnliftIO m => m a -> (Async a -> m b) -> m b
withAsyncBound :: MonadUnliftIO m => m a -> (Async a -> m b) -> m b
withAsyncOn :: MonadUnliftIO m => Int -> m a -> (Async a -> m b) -> m b
withAsyncOnWithUnmask :: MonadUnliftIO m => Int -> ((forall c. () => m c -> m c) -> m a) -> (Async a -> m b) -> m b
withAsyncWithUnmask :: MonadUnliftIO m => ((forall c. () => m c -> m c) -> m a) -> (Async a -> m b) -> m b
isEmptyMVar :: MonadIO m => MVar a -> m Bool
mkWeakMVar :: MonadUnliftIO m => MVar a -> m () -> m (Weak (MVar a))
modifyMVar :: MonadUnliftIO m => MVar a -> (a -> m (a, b)) -> m b
modifyMVarMasked :: MonadUnliftIO m => MVar a -> (a -> m (a, b)) -> m b
modifyMVarMasked_ :: MonadUnliftIO m => MVar a -> (a -> m a) -> m ()
modifyMVar_ :: MonadUnliftIO m => MVar a -> (a -> m a) -> m ()
newEmptyMVar :: MonadIO m => m (MVar a)
newMVar :: MonadIO m => a -> m (MVar a)
putMVar :: MonadIO m => MVar a -> a -> m ()
readMVar :: MonadIO m => MVar a -> m a
swapMVar :: MonadIO m => MVar a -> a -> m a
takeMVar :: MonadIO m => MVar a -> m a
tryPutMVar :: MonadIO m => MVar a -> a -> m Bool
tryReadMVar :: MonadIO m => MVar a -> m (Maybe a)
tryTakeMVar :: MonadIO m => MVar a -> m (Maybe a)
withMVarMasked :: MonadUnliftIO m => MVar a -> (a -> m b) -> m b
memoizeMVar :: MonadUnliftIO m => m a -> m (Memoized a)
memoizeRef :: MonadUnliftIO m => m a -> m (Memoized a)
runMemoized :: MonadIO m => Memoized a -> m a
newQSem :: MonadIO m => Int -> m QSem
signalQSem :: MonadIO m => QSem -> m ()
waitQSem :: MonadIO m => QSem -> m ()
withQSem :: MonadUnliftIO m => QSem -> m a -> m a
newQSemN :: MonadIO m => Int -> m QSemN
signalQSemN :: MonadIO m => QSemN -> Int -> m ()
waitQSemN :: MonadIO m => QSemN -> Int -> m ()
withQSemN :: MonadUnliftIO m => QSemN -> Int -> m a -> m a
checkSTM :: Bool -> STM ()
mkWeakTMVar :: MonadUnliftIO m => TMVar a -> m () -> m (Weak (TMVar a))
mkWeakTVar :: MonadUnliftIO m => TVar a -> m () -> m (Weak (TVar a))
newBroadcastTChanIO :: MonadIO m => m (TChan a)
newEmptyTMVarIO :: MonadIO m => m (TMVar a)
newTBQueueIO :: MonadIO m => Natural -> m (TBQueue a)
newTChanIO :: MonadIO m => m (TChan a)
newTMVarIO :: MonadIO m => a -> m (TMVar a)
newTQueueIO :: MonadIO m => m (TQueue a)
retrySTM :: STM a
withSystemTempDirectory :: MonadUnliftIO m => String -> (FilePath -> m a) -> m a
withSystemTempFile :: MonadUnliftIO m => String -> (FilePath -> Handle -> m a) -> m a
withTempDirectory :: MonadUnliftIO m => FilePath -> String -> (FilePath -> m a) -> m a
withTempFile :: MonadUnliftIO m => FilePath -> String -> (FilePath -> Handle -> m a) -> m a
askRunInIO :: MonadUnliftIO m => m (m a -> IO a)
askUnliftIO :: MonadUnliftIO m => m (UnliftIO m)
liftIOOp :: MonadUnliftIO m => (IO a -> IO b) -> m a -> m b
toIO :: MonadUnliftIO m => m a -> m (IO a)
withUnliftIO :: MonadUnliftIO m => (UnliftIO m -> IO a) -> m a
wrappedWithRunInIO :: MonadUnliftIO n => (n b -> m b) -> (forall a. () => m a -> n a) -> ((forall a. () => m a -> IO a) -> IO b) -> m b
data AsyncCancelled
AsyncCancelled :: AsyncCancelled
class Category a => Arrow (a :: Type -> Type -> Type)
(***) :: Arrow a => a b c -> a b' c' -> a (b, b') (c, c')
(&&&) :: Arrow a => a b c -> a b c' -> a b (c, c')
class Category (cat :: k -> k -> Type)
data Chan a
data QSem
data QSemN
class Monad m => MonadIO (m :: Type -> Type)
liftIO :: MonadIO m => IO a -> m a
class Bifoldable (p :: Type -> Type -> Type)
bifold :: (Bifoldable p, Monoid m) => p m m -> m
bifoldMap :: (Bifoldable p, Monoid m) => (a -> m) -> (b -> m) -> p a b -> m
bifoldr :: Bifoldable p => (a -> c -> c) -> (b -> c -> c) -> c -> p a b -> c
bifoldl :: Bifoldable p => (c -> a -> c) -> (c -> b -> c) -> c -> p a b -> c
class (Bifunctor t, Bifoldable t) => Bitraversable (t :: Type -> Type -> Type)
bitraverse :: (Bitraversable t, Applicative f) => (a -> f c) -> (b -> f d) -> t a b -> f (t c d)
newtype Down a
Down :: a -> Down a
[getDown] :: Down a -> a
data Proxy (t :: k)
Proxy :: Proxy (t :: k)
class Applicative f => Alternative (f :: Type -> Type)
(<|>) :: Alternative f => f a -> f a -> f a
class Functor (f :: Type -> Type)
fmap :: Functor f => (a -> b) -> f a -> f b
(<$) :: Functor f => a -> f b -> f a
class (Alternative m, Monad m) => MonadPlus (m :: Type -> Type)
mzero :: MonadPlus m => m a
mplus :: MonadPlus m => m a -> m a -> m a
class Bounded a
minBound :: Bounded a => a
maxBound :: Bounded a => a
class Enum a
fromEnum :: Enum a => a -> Int
data SomeException
SomeException :: e -> SomeException
class Fractional a => Floating a
pi :: Floating a => a
exp :: Floating a => a -> a
log :: Floating a => a -> a
sqrt :: Floating a => a -> a
(**) :: Floating a => a -> a -> a
logBase :: Floating a => a -> a -> a
sin :: Floating a => a -> a
cos :: Floating a => a -> a
tan :: Floating a => a -> a
asin :: Floating a => a -> a
acos :: Floating a => a -> a
atan :: Floating a => a -> a
sinh :: Floating a => a -> a
cosh :: Floating a => a -> a
tanh :: Floating a => a -> a
asinh :: Floating a => a -> a
acosh :: Floating a => a -> a
atanh :: Floating a => a -> a
class (RealFrac a, Floating a) => RealFloat a
floatRadix :: RealFloat a => a -> Integer
floatDigits :: RealFloat a => a -> Int
floatRange :: RealFloat a => a -> (Int, Int)
decodeFloat :: RealFloat a => a -> (Integer, Int)
encodeFloat :: RealFloat a => Integer -> Int -> a
exponent :: RealFloat a => a -> Int
significand :: RealFloat a => a -> a
scaleFloat :: RealFloat a => Int -> a -> a
isNaN :: RealFloat a => a -> Bool
isInfinite :: RealFloat a => a -> Bool
isDenormalized :: RealFloat a => a -> Bool
isNegativeZero :: RealFloat a => a -> Bool
isIEEE :: RealFloat a => a -> Bool
atan2 :: RealFloat a => a -> a -> a
type FilePath = String
data SeekMode
AbsoluteSeek :: SeekMode
RelativeSeek :: SeekMode
SeekFromEnd :: SeekMode
data ExitCode
ExitSuccess :: ExitCode
ExitFailure :: Int -> ExitCode
data IOException
data SomeAsyncException
SomeAsyncException :: e -> SomeAsyncException
data BufferMode
NoBuffering :: BufferMode
LineBuffering :: BufferMode
BlockBuffering :: Maybe Int -> BufferMode
data Handle
data IOMode
ReadMode :: IOMode
WriteMode :: IOMode
AppendMode :: IOMode
ReadWriteMode :: IOMode
data MVar a
class Num a => Fractional a
(/) :: Fractional a => a -> a -> a
recip :: Fractional a => a -> a
fromRational :: Fractional a => Rational -> a
class (Real a, Enum a) => Integral a
quot :: Integral a => a -> a -> a
rem :: Integral a => a -> a -> a
div :: Integral a => a -> a -> a
mod :: Integral a => a -> a -> a
quotRem :: Integral a => a -> a -> (a, a)
divMod :: Integral a => a -> a -> (a, a)
toInteger :: Integral a => a -> Integer
class (Real a, Fractional a) => RealFrac a
properFraction :: (RealFrac a, Integral b) => a -> (b, a)
truncate :: (RealFrac a, Integral b) => a -> b
round :: (RealFrac a, Integral b) => a -> b
ceiling :: (RealFrac a, Integral b) => a -> b
floor :: (RealFrac a, Integral b) => a -> b
data ST s a
class Show a
show :: Show a => a -> String
type HasCallStack = ?callStack :: CallStack
data Builder
data ShortByteString
data IntMap a
data IntSet
data Map k a
class NFData a
rnf :: NFData a => a -> ()
class Monad m => MonadThrow (m :: Type -> Type)
throwM :: (MonadThrow m, HasCallStack, Exception e) => e -> m a
class Eq a
(==) :: Eq a => a -> a -> Bool
(/=) :: Eq a => a -> a -> Bool
class Eq a => Ord a
compare :: Ord a => a -> a -> Ordering
(<) :: Ord a => a -> a -> Bool
(<=) :: Ord a => a -> a -> Bool
(>) :: Ord a => a -> a -> Bool
(>=) :: Ord a => a -> a -> Bool
max :: Ord a => a -> a -> a
min :: Ord a => a -> a -> a
class Eq a => Hashable a
class Monad m => MonadReader r (m :: Type -> Type) | m -> r
ask :: MonadReader r m => m r
local :: MonadReader r m => (r -> r) -> m a -> m a
type family PrimState (m :: Type -> Type)
data AsyncExceptionWrapper
AsyncExceptionWrapper :: e -> AsyncExceptionWrapper
data SyncExceptionWrapper
SyncExceptionWrapper :: e -> SyncExceptionWrapper
data TBQueue a
data TChan a
data TMVar a
data TQueue a
data UnicodeException
DecodeError :: String -> Maybe Word8 -> UnicodeException
EncodeError :: String -> Maybe Char -> UnicodeException
class forall (m :: Type -> Type). Monad m => Monad t m => MonadTrans (t :: Type -> Type -> Type -> Type)
lift :: (MonadTrans t, Monad m) => m a -> t m a
type Reader r = ReaderT r Identity
newtype ReaderT r (m :: Type -> Type) a
ReaderT :: (r -> m a) -> ReaderT r (m :: Type -> Type) a
[runReaderT] :: ReaderT r (m :: Type -> Type) a -> r -> m a
data StringException
StringException :: String -> CallStack -> StringException
data ConcException
EmptyWithNoAlternative :: ConcException
newtype Concurrently (m :: Type -> Type) a
Concurrently :: m a -> Concurrently (m :: Type -> Type) a
[runConcurrently] :: Concurrently (m :: Type -> Type) a -> m a
data Memoized a
data Vector a
class (Vector Vector a, MVector MVector a) => Unbox a
guard :: Alternative f => Bool -> f ()
data Either a b
Left :: a -> Either a b
Right :: b -> Either a b
data Void
($) :: (a -> b) -> a -> b
assert :: Bool -> a -> a
otherwise :: Bool
(++) :: [a] -> [a] -> [a]
join :: Monad m => m (m a) -> m a
class Applicative m => Monad (m :: Type -> Type)
(>>=) :: Monad m => m a -> (a -> m b) -> m b
(>>) :: Monad m => m a -> m b -> m b
return :: Monad m => a -> m a
class Semigroup a => Monoid a
mempty :: Monoid a => a
mappend :: Monoid a => a -> a -> a
mconcat :: Monoid a => [a] -> a
class Semigroup a
(<>) :: Semigroup a => a -> a -> a
realToFrac :: (Real a, Fractional b) => a -> b
fromIntegral :: (Integral a, Num b) => a -> b
class (Num a, Ord a) => Real a
toRational :: Real a => a -> Rational
type Rational = Ratio Integer
data Word64
data Word32
data Word16
data Word8
data CallStack
seq :: a -> b -> b
class Monad m => MonadFail (m :: Type -> Type)
fail :: MonadFail m => String -> m a
class IsString a
fromString :: IsString a => String -> a
class Typeable (a :: k)
class Generic a
data Int16
data Int32
data Int64
data Int8
class Read a

module KMonad.Prelude.Definitions

module KMonad.Prelude


-- | A collection of general parsing definitions
module KMonad.Parsing

-- | Parsec type specified down to Void Text
type Parser a = Parsec Void Text a
type ParserT (m :: Type -> Type) a = ParsecT Void Text m a

-- | Parsec parse errors under Void Text with an Exception instance
newtype ParseError
ParseError :: ParseErrorBundle Text Void -> ParseError
[_parseError] :: ParseError -> ParseErrorBundle Text Void

-- | Full space consumption
sc :: Parser ()

-- | Horizontal space consumption
hsc :: Parser ()

-- | Full space lexeme
lex :: Parser a -> Parser a

-- | Horizontal space lexeme
hlex :: Parser a -> Parser a
class (Stream s, MonadPlus m) => MonadParsec e s (m :: Type -> Type) | m -> e s
parseError :: MonadParsec e s m => ParseError s e -> m a
label :: MonadParsec e s m => String -> m a -> m a
hidden :: MonadParsec e s m => m a -> m a
try :: MonadParsec e s m => m a -> m a
lookAhead :: MonadParsec e s m => m a -> m a
notFollowedBy :: MonadParsec e s m => m a -> m ()
withRecovery :: MonadParsec e s m => (ParseError s e -> m a) -> m a -> m a
observing :: MonadParsec e s m => m a -> m (Either (ParseError s e) a)
eof :: MonadParsec e s m => m ()
token :: MonadParsec e s m => (Token s -> Maybe a) -> Set (ErrorItem (Token s)) -> m a
tokens :: MonadParsec e s m => (Tokens s -> Tokens s -> Bool) -> Tokens s -> m (Tokens s)
takeWhileP :: MonadParsec e s m => Maybe String -> (Token s -> Bool) -> m (Tokens s)
takeWhile1P :: MonadParsec e s m => Maybe String -> (Token s -> Bool) -> m (Tokens s)
takeP :: MonadParsec e s m => Maybe String -> Int -> m (Tokens s)
getParserState :: MonadParsec e s m => m (State s e)
updateParserState :: MonadParsec e s m => (State s e -> State s e) -> m ()
mkParsec :: MonadParsec e s m => (State s e -> Reply e s a) -> m a
data State s e
State :: s -> {-# UNPACK #-} !Int -> PosState s -> [ParseError s e] -> State s e
[stateInput] :: State s e -> s
[stateOffset] :: State s e -> {-# UNPACK #-} !Int
[statePosState] :: State s e -> PosState s
[stateParseErrors] :: State s e -> [ParseError s e]
some :: MonadPlus m => m a -> m [a]
many :: MonadPlus m => m a -> m [a]
noneOf :: (Foldable f, MonadParsec e s m) => f (Token s) -> m (Token s)
empty :: Alternative f => f a
(<|>) :: Alternative f => f a -> f a -> f a
optional :: Alternative f => f a -> f (Maybe a)
class (Ord Token s, Ord Tokens s) => Stream s where {
    type Token s;
    type Tokens s;
}
tokenToChunk :: Stream s => Proxy s -> Token s -> Tokens s
tokensToChunk :: Stream s => Proxy s -> [Token s] -> Tokens s
chunkToTokens :: Stream s => Proxy s -> Tokens s -> [Token s]
chunkLength :: Stream s => Proxy s -> Tokens s -> Int
chunkEmpty :: Stream s => Proxy s -> Tokens s -> Bool
take1_ :: Stream s => s -> Maybe (Token s, s)
takeN_ :: Stream s => Int -> s -> Maybe (Tokens s, s)
takeWhile_ :: Stream s => (Token s -> Bool) -> s -> (Tokens s, s)
count :: Monad m => Int -> m a -> m [a]
chunk :: MonadParsec e s m => Tokens s -> m (Tokens s)
match :: MonadParsec e s m => m a -> m (Tokens s, a)
failure :: MonadParsec e s m => Maybe (ErrorItem (Token s)) -> Set (ErrorItem (Token s)) -> m a
choice :: (Foldable f, Alternative m) => f (m a) -> m a
type Parsec e s = ParsecT e s Identity
data ParsecT e s (m :: Type -> Type) a
data ParseErrorBundle s e
ParseErrorBundle :: NonEmpty (ParseError s e) -> PosState s -> ParseErrorBundle s e
[bundleErrors] :: ParseErrorBundle s e -> NonEmpty (ParseError s e)
[bundlePosState] :: ParseErrorBundle s e -> PosState s
errorBundlePretty :: (VisualStream s, TraversableStream s, ShowErrorComponent e) => ParseErrorBundle s e -> String
data ErrorItem t
Tokens :: NonEmpty t -> ErrorItem t
Label :: NonEmpty Char -> ErrorItem t
EndOfInput :: ErrorItem t
data ErrorFancy e
ErrorFail :: String -> ErrorFancy e
ErrorIndentation :: Ordering -> Pos -> Pos -> ErrorFancy e
ErrorCustom :: e -> ErrorFancy e
pattern FancyError :: () => Int -> Set (ErrorFancy e) -> ParseError s e
pattern TrivialError :: () => Int -> Maybe (ErrorItem (Token s)) -> Set (ErrorItem (Token s)) -> ParseError s e
class Ord a => ShowErrorComponent a
showErrorComponent :: ShowErrorComponent a => a -> String
errorComponentLen :: ShowErrorComponent a => a -> Int
type family Tokens s
attachSourcePos :: (Traversable t, TraversableStream s) => (a -> Int) -> t a -> PosState s -> (t (a, SourcePos), PosState s)
errorOffset :: ParseError s e -> Int
mapParseError :: Ord e' => (e -> e') -> ParseError s e -> ParseError s e'
parseErrorPretty :: (VisualStream s, ShowErrorComponent e) => ParseError s e -> String
parseErrorTextPretty :: (VisualStream s, ShowErrorComponent e) => ParseError s e -> String
setErrorOffset :: Int -> ParseError s e -> ParseError s e
showErrorItem :: VisualStream s => Proxy s -> ErrorItem (Token s) -> String
newtype InvalidPosException
InvalidPosException :: Int -> InvalidPosException
data Pos
data SourcePos
SourcePos :: FilePath -> !Pos -> !Pos -> SourcePos
[sourceName] :: SourcePos -> FilePath
[sourceLine] :: SourcePos -> !Pos
[sourceColumn] :: SourcePos -> !Pos
defaultTabWidth :: Pos
initialPos :: FilePath -> SourcePos
mkPos :: Int -> Pos
pos1 :: Pos
sourcePosPretty :: SourcePos -> String
unPos :: Pos -> Int
data PosState s
PosState :: s -> !Int -> !SourcePos -> Pos -> String -> PosState s
[pstateInput] :: PosState s -> s
[pstateOffset] :: PosState s -> !Int
[pstateSourcePos] :: PosState s -> !SourcePos
[pstateTabWidth] :: PosState s -> Pos
[pstateLinePrefix] :: PosState s -> String
newtype NoShareInput a
NoShareInput :: a -> NoShareInput a
[unNoShareInput] :: NoShareInput a -> a
newtype ShareInput a
ShareInput :: a -> ShareInput a
[unShareInput] :: ShareInput a -> a
type family Token s
class Stream s => TraversableStream s
reachOffset :: TraversableStream s => Int -> PosState s -> (Maybe String, PosState s)
reachOffsetNoLine :: TraversableStream s => Int -> PosState s -> PosState s
class Stream s => VisualStream s
showTokens :: VisualStream s => Proxy s -> NonEmpty (Token s) -> String
tokensLength :: VisualStream s => Proxy s -> NonEmpty (Token s) -> Int
(<?>) :: MonadParsec e s m => m a -> String -> m a
runParserT' :: Monad m => ParsecT e s m a -> State s e -> m (State s e, Either (ParseErrorBundle s e) a)
anySingle :: MonadParsec e s m => m (Token s)
anySingleBut :: MonadParsec e s m => Token s -> m (Token s)
atEnd :: MonadParsec e s m => m Bool
customFailure :: MonadParsec e s m => e -> m a
fancyFailure :: MonadParsec e s m => Set (ErrorFancy e) -> m a
getInput :: MonadParsec e s m => m s
getOffset :: MonadParsec e s m => m Int
getSourcePos :: (TraversableStream s, MonadParsec e s m) => m SourcePos
oneOf :: (Foldable f, MonadParsec e s m) => f (Token s) -> m (Token s)
parse :: Parsec e s a -> String -> s -> Either (ParseErrorBundle s e) a
parseMaybe :: (Ord e, Stream s) => Parsec e s a -> s -> Maybe a
parseTest :: (ShowErrorComponent e, Show a, VisualStream s, TraversableStream s) => Parsec e s a -> s -> IO ()
region :: MonadParsec e s m => (ParseError s e -> ParseError s e) -> m a -> m a
registerFailure :: MonadParsec e s m => Maybe (ErrorItem (Token s)) -> Set (ErrorItem (Token s)) -> m ()
registerFancyFailure :: MonadParsec e s m => Set (ErrorFancy e) -> m ()
registerParseError :: MonadParsec e s m => ParseError s e -> m ()
runParser :: Parsec e s a -> String -> s -> Either (ParseErrorBundle s e) a
runParser' :: Parsec e s a -> State s e -> (State s e, Either (ParseErrorBundle s e) a)
runParserT :: Monad m => ParsecT e s m a -> String -> s -> m (Either (ParseErrorBundle s e) a)
satisfy :: MonadParsec e s m => (Token s -> Bool) -> m (Token s)
setInput :: MonadParsec e s m => s -> m ()
setOffset :: MonadParsec e s m => Int -> m ()
setParserState :: MonadParsec e s m => State s e -> m ()
single :: MonadParsec e s m => Token s -> m (Token s)
takeRest :: MonadParsec e s m => m (Tokens s)
unexpected :: MonadParsec e s m => ErrorItem (Token s) -> m a
between :: Applicative m => m open -> m close -> m a -> m a
eitherP :: Alternative m => m a -> m b -> m (Either a b)
option :: Alternative m => a -> m a -> m a
count' :: MonadPlus m => Int -> Int -> m a -> m [a]
endBy :: MonadPlus m => m a -> m sep -> m [a]
endBy1 :: MonadPlus m => m a -> m sep -> m [a]
manyTill :: MonadPlus m => m a -> m end -> m [a]
manyTill_ :: MonadPlus m => m a -> m end -> m ([a], end)
sepBy :: MonadPlus m => m a -> m sep -> m [a]
sepBy1 :: MonadPlus m => m a -> m sep -> m [a]
sepEndBy :: MonadPlus m => m a -> m sep -> m [a]
sepEndBy1 :: MonadPlus m => m a -> m sep -> m [a]
skipCount :: Monad m => Int -> m a -> m ()
skipMany :: MonadPlus m => m a -> m ()
skipManyTill :: MonadPlus m => m a -> m end -> m end
skipSome :: MonadPlus m => m a -> m ()
skipSomeTill :: MonadPlus m => m a -> m end -> m end
someTill :: MonadPlus m => m a -> m end -> m [a]
someTill_ :: MonadPlus m => m a -> m end -> m ([a], end)
space1 :: (MonadParsec e s m, Token s ~ Char) => m ()
string :: MonadParsec e s m => Tokens s -> m (Tokens s)
string' :: (MonadParsec e s m, FoldCase (Tokens s)) => Tokens s -> m (Tokens s)
alphaNumChar :: (MonadParsec e s m, Token s ~ Char) => m (Token s)
asciiChar :: (MonadParsec e s m, Token s ~ Char) => m (Token s)
binDigitChar :: (MonadParsec e s m, Token s ~ Char) => m (Token s)
categoryName :: GeneralCategory -> String
char :: (MonadParsec e s m, Token s ~ Char) => Token s -> m (Token s)
char' :: (MonadParsec e s m, Token s ~ Char) => Token s -> m (Token s)
charCategory :: (MonadParsec e s m, Token s ~ Char) => GeneralCategory -> m (Token s)
controlChar :: (MonadParsec e s m, Token s ~ Char) => m (Token s)
crlf :: (MonadParsec e s m, Token s ~ Char) => m (Tokens s)
digitChar :: (MonadParsec e s m, Token s ~ Char) => m (Token s)
eol :: (MonadParsec e s m, Token s ~ Char) => m (Tokens s)
hexDigitChar :: (MonadParsec e s m, Token s ~ Char) => m (Token s)
hspace :: (MonadParsec e s m, Token s ~ Char) => m ()
hspace1 :: (MonadParsec e s m, Token s ~ Char) => m ()
latin1Char :: (MonadParsec e s m, Token s ~ Char) => m (Token s)
letterChar :: (MonadParsec e s m, Token s ~ Char) => m (Token s)
lowerChar :: (MonadParsec e s m, Token s ~ Char) => m (Token s)
markChar :: (MonadParsec e s m, Token s ~ Char) => m (Token s)
newline :: (MonadParsec e s m, Token s ~ Char) => m (Token s)
numberChar :: (MonadParsec e s m, Token s ~ Char) => m (Token s)
octDigitChar :: (MonadParsec e s m, Token s ~ Char) => m (Token s)
printChar :: (MonadParsec e s m, Token s ~ Char) => m (Token s)
punctuationChar :: (MonadParsec e s m, Token s ~ Char) => m (Token s)
separatorChar :: (MonadParsec e s m, Token s ~ Char) => m (Token s)
space :: (MonadParsec e s m, Token s ~ Char) => m ()
spaceChar :: (MonadParsec e s m, Token s ~ Char) => m (Token s)
symbolChar :: (MonadParsec e s m, Token s ~ Char) => m (Token s)
tab :: (MonadParsec e s m, Token s ~ Char) => m (Token s)
upperChar :: (MonadParsec e s m, Token s ~ Char) => m (Token s)
instance GHC.Classes.Eq KMonad.Parsing.ParseError
instance GHC.Exception.Type.Exception KMonad.Parsing.ParseError
instance GHC.Show.Show KMonad.Parsing.ParseError


-- | This module contains only a Haskellified list of (nearly) all X11
--   compose-key sequences. For each entry we have the sequence of keys
--   that defines it, the UTF-8 character that it represents, and the X11
--   name for this sequence/character.
module KMonad.Keyboard.ComposeSeq

-- | A collection of all supported compose-key sequences (nearly all X11
--   compose-key sequences). Each tuple consists of: 1. A string that, when
--   parsed to a tap-macro, will emit the sequence. 2. The UTF-8 character
--   that it represents 3. A descriptive-name
ssComposed :: [(Text, Char, Text)]

module KMonad.Gesture
data Toggle a
On :: a -> Toggle a
Off :: a -> Toggle a

-- | A sequence of toggle-changes guaranteed to be valid
newtype Gesture a
Gesture :: Seq (Toggle a) -> Gesture a
[_gesture] :: Gesture a -> Seq (Toggle a)

-- | All the ways a '[Toggle a]' can be an invalid <a>Gesture</a>
data GestureError a

-- | An Off not preceded by an On
OffWithoutOn :: a -> GestureError a

-- | An On not succeeded by an Off
OnWithoutOff :: a -> GestureError a

-- | A lens into the i
tag :: forall a f. Functor f => (a -> f a) -> Toggle a -> f (Toggle a)

-- | A fold of all the unique elements in a gesture
tags :: Ord a => Fold (Gesture a) a

-- | Create a tapping gesture
tap :: a -> Gesture a

-- | Wrap a gesture in a toggle iff the id does not already occur
around :: Ord a => a -> Gesture a -> Either (GestureError a) (Gesture a)

-- | Create a gesture from a list of toggles
fromList :: Ord a => [Toggle a] -> Either (GestureError a) (Gesture a)
type Gest = Seq Toggle Text
data GestureReadError
GestureParseError :: ParseError -> GestureReadError
GestureValidateError :: GestureError Text -> GestureReadError

-- | Parse a Gesture straight from Text
prsGesture :: Text -> Either GestureReadError (Gesture Text)

-- | Characters that may not occur in tag-names
reserved :: [Char]

-- | Parse a series of valid characters as a tag
tag_ :: Parser Text

-- | Parse a "S-" sequence as 1 tag around another
around_ :: Parser Gest

-- | Parse a ")-X" as an OFF-toggle
closeTag :: Parser Gest

-- | Parse a "X-(" as an ON-toggle
openTag :: Parser Gest

-- | Parse only a tag as a tap of that element
tap_ :: Parser Gest

-- | Parse a [] delimited series as a nested gesture
subg :: Parser Gest

-- | Parse a full gesture
gest :: Parser Gest
instance GHC.Classes.Eq a => GHC.Classes.Eq (KMonad.Gesture.Gesture a)
instance GHC.Classes.Eq a => GHC.Classes.Eq (KMonad.Gesture.GestureError a)
instance GHC.Classes.Eq KMonad.Gesture.GestureReadError
instance GHC.Classes.Eq a => GHC.Classes.Eq (KMonad.Gesture.Toggle a)
instance GHC.Exception.Type.Exception KMonad.Gesture.GestureReadError
instance GHC.Base.Functor KMonad.Gesture.Gesture
instance GHC.Base.Functor KMonad.Gesture.Toggle
instance GHC.Base.Monoid (KMonad.Gesture.Gesture a)
instance GHC.Base.Semigroup (KMonad.Gesture.Gesture a)
instance GHC.Show.Show a => GHC.Show.Show (KMonad.Gesture.Gesture a)
instance GHC.Show.Show a => GHC.Show.Show (KMonad.Gesture.GestureError a)
instance GHC.Show.Show KMonad.Gesture.GestureReadError
instance GHC.Show.Show a => GHC.Show.Show (KMonad.Gesture.Toggle a)


module KMonad.Args.TH

-- | Get the git hash of the current commit at compile time.
gitHash :: Q Exp


-- | Contains code for making it slighly easier to work with time, errors,
--   and Acquire datatypes.
module KMonad.Util

-- | Newtype wrapper around <a>Int</a> to add type safety to our time
--   values
data Milliseconds
unMS :: Milliseconds -> Int

-- | Calculate how much time has elapsed between 2 time points
tDiff :: SystemTime -> SystemTime -> Milliseconds

-- | A helper function that helps to throw errors when a return code is -1.
--   Easiest when used as infix like this:
--   
--   <pre>
--   someFFIcall `onErr` MyCallFailedError someData
--   </pre>
onErr :: (MonadUnliftIO m, Exception e) => m Int -> e -> m ()

-- | Embed the action of using an <a>Acquire</a> in a continuation monad
using :: Acquire a -> ContT r (RIO e) a

-- | Log an error message and then rethrow the error
--   
--   Particularly useful as a suffix using <a>catch</a>. i.e.
--   
--   <pre>
--   doSomething `catch` logRethrow "I caught something"
--   </pre>
logRethrow :: HasLogFunc e => Text -> SomeException -> RIO e a

-- | Launch a process that repeats an action indefinitely. If an error ever
--   occurs, print it and rethrow it. Ensure the process is cleaned up upon
--   error and/or shutdown.
withLaunch :: HasLogFunc e => Text -> RIO e a -> (Async a -> RIO e b) -> RIO e b

-- | Like withLaunch, but without ever needing access to the async process
withLaunch_ :: HasLogFunc e => Text -> RIO e a -> RIO e b -> RIO e b

-- | Like <a>withLaunch</a>, but in the ContT monad
launch :: HasLogFunc e => Text -> RIO e a -> ContT r (RIO e) (Async a)

-- | Like <a>withLaunch_</a>, but in the ContT monad
launch_ :: HasLogFunc e => Text -> RIO e a -> ContT r (RIO e) ()
instance Data.Data.Data KMonad.Util.Milliseconds
instance RIO.Prelude.Display.Display KMonad.Util.Milliseconds
instance GHC.Enum.Enum KMonad.Util.Milliseconds
instance GHC.Classes.Eq KMonad.Util.Milliseconds
instance GHC.Generics.Generic KMonad.Util.Milliseconds
instance GHC.Real.Integral KMonad.Util.Milliseconds
instance GHC.Num.Num KMonad.Util.Milliseconds
instance GHC.Classes.Ord KMonad.Util.Milliseconds
instance GHC.Read.Read KMonad.Util.Milliseconds
instance GHC.Real.Real KMonad.Util.Milliseconds
instance GHC.Show.Show KMonad.Util.Milliseconds


-- | A <a>LayerStack</a> is a set of different mappings between keys and
--   values, and provides functionality for keeping track of a <a>stack</a>
--   of these mappings. Lookup in a <a>LayerStack</a> happens by checking
--   the front-most mapping on the stack, and if that fails, descending
--   deeper.
--   
--   A <a>LayerStack</a> has 3 type parameters, in the documentation we
--   will refer to those as: - l: The layer key, which is the identifier
--   for the different layers - k: The item key, which is the per-layer
--   identifier for different items - a: The item (value), which is the
--   value stored for k in a particular layer
--   
--   <a>LayerStack</a> is used to implement the basic keymap logic in
--   KMonad, where the configuration for a keyboard is essentially a set of
--   layers. Each layer maps keycodes to buttons, and the entire layers can
--   be overlayed on top of eachother.
module KMonad.Util.LayerStack

-- | A <a>Layer</a> is one of the maps contained inside a <a>LayerStack</a>
data Layer k a

-- | Create a new <a>Layer</a> from a <a>Foldable</a> of key-value pairs
mkLayer :: (Foldable t, CanKey k) => t (k, a) -> Layer k a

-- | A <a>LayerStack</a> is a named collection of maps and a sequence of
--   maps to use for lookup.
data LayerStack l k a

-- | Create a new <a>LayerStack</a> from a foldable of foldables.
mkLayerStack :: (Foldable t1, Foldable t2, CanKey k, CanKey l) => t1 (l, t2 (k, a)) -> LayerStack l k a
items :: forall l k1 a1 k2 a2 f. Functor f => (HashMap (l, k1) a1 -> f (HashMap (l, k2) a2)) -> LayerStack l k1 a1 -> f (LayerStack l k2 a2)
maps :: forall l k a f. Functor f => (HashSet l -> f (HashSet l)) -> LayerStack l k a -> f (LayerStack l k a)
stack :: forall l k a f. Functor f => ([l] -> f [l]) -> LayerStack l k a -> f (LayerStack l k a)

-- | Return a fold of all the items currently mapped to the item-key
--   
--   This can be used with <a>toListOf</a> to get an overview of all the
--   items currently mapped to an item-key, or more usefully, with
--   <a>firstOf</a> to simply try a lookup like this: `stack^? atKey KeyA`
atKey :: (CanKey l, CanKey k) => k -> Fold (LayerStack l k a) a

-- | Try to look up a key in a specific layer, regardless of the stack
inLayer :: (CanKey l, CanKey k) => l -> k -> Fold (LayerStack l k a) a

-- | Add a layer to the front of the stack and return the new
--   <a>LayerStack</a>.
--   
--   If the <a>Layer</a> does not exist, return a <a>LayerStackError</a>.
--   If the <a>Layer</a> is already on the stack, bring it to the front.
pushLayer :: (CanKey l, CanKey k) => l -> LayerStack l k a -> Either (LayerStackError l) (LayerStack l k a)

-- | Remove a layer from the stack. If the layer index does not exist on
--   the stack, return a <a>LayerNotOnStack</a>, if the layer index does
--   not exist at all in the <a>LayerStack</a>, return a
--   <a>LayerDoesNotExist</a>.
popLayer :: (CanKey l, CanKey k) => l -> LayerStack l k a -> Either (LayerStackError l) (LayerStack l k a)

-- | The things that can go wrong with a <tt>LayerStack</tt>
data LayerStackError l

-- | Requested use of a non-existing layer
LayerDoesNotExist :: l -> LayerStackError l

-- | Requested use of a non-stack layer
LayerNotOnStack :: l -> LayerStackError l
class AsLayerStackError r l | r -> l
_LayerStackError :: AsLayerStackError r l => Prism' r (LayerStackError l)
_LayerDoesNotExist :: AsLayerStackError r l => Prism' r l
_LayerNotOnStack :: AsLayerStackError r l => Prism' r l
instance KMonad.Util.LayerStack.AsLayerStackError (KMonad.Util.LayerStack.LayerStackError l) l
instance (GHC.Classes.Eq k, GHC.Classes.Eq a) => GHC.Classes.Eq (KMonad.Util.LayerStack.Layer k a)
instance (GHC.Classes.Eq l, GHC.Classes.Eq k, GHC.Classes.Eq a) => GHC.Classes.Eq (KMonad.Util.LayerStack.LayerStack l k a)
instance (Data.Typeable.Internal.Typeable l, GHC.Show.Show l) => GHC.Exception.Type.Exception (KMonad.Util.LayerStack.LayerStackError l)
instance Data.Foldable.Foldable (KMonad.Util.LayerStack.Layer k)
instance GHC.Base.Functor (KMonad.Util.LayerStack.Layer k)
instance GHC.Base.Functor (KMonad.Util.LayerStack.LayerStack l k)
instance (GHC.Classes.Ord k, GHC.Classes.Ord a) => GHC.Classes.Ord (KMonad.Util.LayerStack.Layer k a)
instance (GHC.Show.Show k, GHC.Show.Show a) => GHC.Show.Show (KMonad.Util.LayerStack.Layer k a)
instance (GHC.Show.Show l, GHC.Show.Show k, GHC.Show.Show a) => GHC.Show.Show (KMonad.Util.LayerStack.LayerStack l k a)
instance GHC.Show.Show l => GHC.Show.Show (KMonad.Util.LayerStack.LayerStackError l)
instance Data.Traversable.Traversable (KMonad.Util.LayerStack.Layer k)


-- | This datastructure represents a `k -&gt; Set v` mapping: that is to
--   say, each key can have multiple values (but no duplicates).
--   Additionally, we provide some operations to reverse this mapping.
--   
--   In KMonad we use this exclusively to easily define multiple names for
--   the same <a>Keycode</a> in a reversible manner.
module KMonad.Util.MultiMap

-- | The <a>MultiMap</a>, which describes a one to many (unique) mapping
data MultiMap k v

-- | Create a new multimap from a foldable of (k, foldable v) pairs.
mkMultiMap :: (Foldable t1, Foldable t2, CanMM k v) => t1 (k, t2 v) -> MultiMap k v

-- | Create a new multimap from a foldable of (k, v) pairs
fromSingletons :: (Foldable t, CanMM k v) => t (k, v) -> MultiMap k v

-- | A fold over all the (k, v) pairs in a <a>MultiMap</a>
itemed :: CanMM k v => Fold (MultiMap k v) (k, v)

-- | Reverse a MultiMap. Note: this is not necessarily a lossless
--   conversion.
reverse :: (CanMM k v, CanMM v k) => MultiMap k v -> MultiMap v k
instance KMonad.Util.MultiMap.CanMM k v => Control.Lens.At.At (KMonad.Util.MultiMap.MultiMap k v)
instance KMonad.Util.MultiMap.CanMM k v => Control.Lens.At.Ixed (KMonad.Util.MultiMap.MultiMap k v)
instance KMonad.Util.MultiMap.CanMM k v => GHC.Base.Monoid (KMonad.Util.MultiMap.MultiMap k v)
instance KMonad.Util.MultiMap.CanMM k v => GHC.Base.Semigroup (KMonad.Util.MultiMap.MultiMap k v)
instance (GHC.Show.Show k, GHC.Show.Show v) => GHC.Show.Show (KMonad.Util.MultiMap.MultiMap k v)


-- | <a>Keycode</a>s are represented as a large enum lining up the keycodes
--   defined in the Linux headers.
module KMonad.Keyboard.Keycode

-- | The <a>Keycode</a> datatype, as an <a>Enum</a> of all the values a
--   <a>Keycode</a> can take.
data Keycode
KeyReserved :: Keycode
KeyEsc :: Keycode
Key1 :: Keycode
Key2 :: Keycode
Key3 :: Keycode
Key4 :: Keycode
Key5 :: Keycode
Key6 :: Keycode
Key7 :: Keycode
Key8 :: Keycode
Key9 :: Keycode
Key0 :: Keycode
KeyMinus :: Keycode
KeyEqual :: Keycode
KeyBackspace :: Keycode
KeyTab :: Keycode
KeyQ :: Keycode
KeyW :: Keycode
KeyE :: Keycode
KeyR :: Keycode
KeyT :: Keycode
KeyY :: Keycode
KeyU :: Keycode
KeyI :: Keycode
KeyO :: Keycode
KeyP :: Keycode
KeyLeftBrace :: Keycode
KeyRightBrace :: Keycode
KeyEnter :: Keycode
KeyLeftCtrl :: Keycode
KeyA :: Keycode
KeyS :: Keycode
KeyD :: Keycode
KeyF :: Keycode
KeyG :: Keycode
KeyH :: Keycode
KeyJ :: Keycode
KeyK :: Keycode
KeyL :: Keycode
KeySemicolon :: Keycode
KeyApostrophe :: Keycode
KeyGrave :: Keycode
KeyLeftShift :: Keycode
KeyBackslash :: Keycode
KeyZ :: Keycode
KeyX :: Keycode
KeyC :: Keycode
KeyV :: Keycode
KeyB :: Keycode
KeyN :: Keycode
KeyM :: Keycode
KeyComma :: Keycode
KeyDot :: Keycode
KeySlash :: Keycode
KeyRightShift :: Keycode
KeyKpAsterisk :: Keycode
KeyLeftAlt :: Keycode
KeySpace :: Keycode
KeyCapsLock :: Keycode
KeyF1 :: Keycode
KeyF2 :: Keycode
KeyF3 :: Keycode
KeyF4 :: Keycode
KeyF5 :: Keycode
KeyF6 :: Keycode
KeyF7 :: Keycode
KeyF8 :: Keycode
KeyF9 :: Keycode
KeyF10 :: Keycode
KeyNumLock :: Keycode
KeyScrollLock :: Keycode
KeyKp7 :: Keycode
KeyKp8 :: Keycode
KeyKp9 :: Keycode
KeyKpMinus :: Keycode
KeyKp4 :: Keycode
KeyKp5 :: Keycode
KeyKp6 :: Keycode
KeyKpPlus :: Keycode
KeyKp1 :: Keycode
KeyKp2 :: Keycode
KeyKp3 :: Keycode
KeyKp0 :: Keycode
KeyKpDot :: Keycode
Missing84 :: Keycode
KeyZenkakuHankaku :: Keycode
Key102nd :: Keycode
KeyF11 :: Keycode
KeyF12 :: Keycode
KeyRo :: Keycode
KeyKatakana :: Keycode
KeyHiragana :: Keycode
KeyHenkan :: Keycode
KeyKatakanaHiragana :: Keycode
KeyMuhenkan :: Keycode
KeyKpjpcomma :: Keycode
KeyKpEnter :: Keycode
KeyRightCtrl :: Keycode
KeyKpSlash :: Keycode
KeySysRq :: Keycode
KeyRightAlt :: Keycode
KeyLinefeed :: Keycode
KeyHome :: Keycode
KeyUp :: Keycode
KeyPageUp :: Keycode
KeyLeft :: Keycode
KeyRight :: Keycode
KeyEnd :: Keycode
KeyDown :: Keycode
KeyPageDown :: Keycode
KeyInsert :: Keycode
KeyDelete :: Keycode
KeyMacro :: Keycode
KeyMute :: Keycode
KeyVolumeDown :: Keycode
KeyVolumeUp :: Keycode
KeyPower :: Keycode
KeyKpEqual :: Keycode
KeyKpPlusMinus :: Keycode
KeyPause :: Keycode
KeyScale :: Keycode
KeyKpComma :: Keycode
KeyHangeul :: Keycode
KeyHanja :: Keycode
KeyYen :: Keycode
KeyLeftMeta :: Keycode
KeyRightMeta :: Keycode
KeyCompose :: Keycode
KeyStop :: Keycode
KeyAgain :: Keycode
KeyProps :: Keycode
KeyUndo :: Keycode
KeyFront :: Keycode
KeyCopy :: Keycode
KeyOpen :: Keycode
KeyPaste :: Keycode
KeyFind :: Keycode
KeyCut :: Keycode
KeyHelp :: Keycode
KeyMenu :: Keycode
KeyCalc :: Keycode
KeySetup :: Keycode
KeySleep :: Keycode
KeyWakeUp :: Keycode
KeyFile :: Keycode
KeySendFile :: Keycode
KeyDeleteFile :: Keycode
KeyXfer :: Keycode
KeyProg1 :: Keycode
KeyProg2 :: Keycode
KeyWww :: Keycode
KeyMsDos :: Keycode
KeyCoffee :: Keycode
KeyDirection :: Keycode
KeyCycleWindows :: Keycode
KeyMail :: Keycode
KeyBookmarks :: Keycode
KeyComputer :: Keycode
KeyBack :: Keycode
KeyForward :: Keycode
KeyCloseCd :: Keycode
KeyEjectCd :: Keycode
KeyEjectCloseCd :: Keycode
KeyNextSong :: Keycode
KeyPlayPause :: Keycode
KeyPreviousSong :: Keycode
KeyStopCd :: Keycode
KeyRecord :: Keycode
KeyRewind :: Keycode
KeyPhone :: Keycode
KeyIso :: Keycode
KeyConfig :: Keycode
KeyHomepage :: Keycode
KeyRefresh :: Keycode
KeyExit :: Keycode
KeyMove :: Keycode
KeyEdit :: Keycode
KeyScrollUp :: Keycode
KeyScrollDown :: Keycode
KeyKpLeftParen :: Keycode
KeyKpRightParen :: Keycode
KeyNew :: Keycode
KeyRedo :: Keycode
KeyF13 :: Keycode
KeyF14 :: Keycode
KeyF15 :: Keycode
KeyF16 :: Keycode
KeyF17 :: Keycode
KeyF18 :: Keycode
KeyF19 :: Keycode
KeyF20 :: Keycode
KeyF21 :: Keycode
KeyF22 :: Keycode
KeyF23 :: Keycode
KeyF24 :: Keycode
Missing195 :: Keycode
Missing196 :: Keycode
Missing197 :: Keycode
Missing198 :: Keycode
Missing199 :: Keycode
KeyPlayCd :: Keycode
KeyPauseCd :: Keycode
KeyProg3 :: Keycode
KeyProg4 :: Keycode
KeyDashboard :: Keycode
KeySuspend :: Keycode
KeyClose :: Keycode
KeyPlay :: Keycode
KeyFastForward :: Keycode
KeyBassBoost :: Keycode
KeyPrint :: Keycode
KeyHp :: Keycode
KeyCamera :: Keycode
KeySound :: Keycode
KeyQuestion :: Keycode
KeyEmail :: Keycode
KeyChat :: Keycode
KeySearch :: Keycode
KeyConnect :: Keycode
KeyFinance :: Keycode
KeySport :: Keycode
KeyShop :: Keycode
KeyAlterase :: Keycode
KeyCancel :: Keycode
KeyBrightnessDown :: Keycode
KeyBrightnessUp :: Keycode
KeyMedia :: Keycode
KeySwitchVideoMode :: Keycode
KeyKbdIllumToggle :: Keycode
KeyKbdIllumDown :: Keycode
KeyKbdIllumUp :: Keycode
KeySend :: Keycode
KeyReply :: Keycode
KeyForwardMail :: Keycode
KeySave :: Keycode
KeyDocuments :: Keycode
KeyBattery :: Keycode
KeyBluetooth :: Keycode
KeyWlan :: Keycode
KeyUwb :: Keycode
KeyUnknown :: Keycode
KeyVideoNext :: Keycode
KeyVideoPrev :: Keycode
KeyBrightnessCycle :: Keycode
KeyBrightnessZero :: Keycode
KeyDisplayOff :: Keycode
KeyWimax :: Keycode
KeyRfkill :: Keycode
KeyMicmute :: Keycode
Missing249 :: Keycode
Missing250 :: Keycode
Missing251 :: Keycode
Missing252 :: Keycode
Missing253 :: Keycode
Missing254 :: Keycode
Missing255 :: Keycode
Btn0 :: Keycode
Btn1 :: Keycode
Btn2 :: Keycode
Btn3 :: Keycode
Btn4 :: Keycode
Btn5 :: Keycode
Btn6 :: Keycode
Btn7 :: Keycode
Btn8 :: Keycode
Btn9 :: Keycode
Missing0x10a :: Keycode
Missing0x10b :: Keycode
Missing0x10c :: Keycode
Missing0x10d :: Keycode
Missing0x10e :: Keycode
Missing0x10f :: Keycode
BtnLeft :: Keycode
BtnRight :: Keycode
BtnMiddle :: Keycode
BtnSide :: Keycode
BtnExtra :: Keycode
BtnForward :: Keycode
BtnBack :: Keycode
BtnTask :: Keycode
Missing0x118 :: Keycode
Missing0x119 :: Keycode
Missing0x11a :: Keycode
Missing0x11b :: Keycode
Missing0x11c :: Keycode
Missing0x11d :: Keycode
Missing0x11e :: Keycode
Missing0x11f :: Keycode
BtnJoystick :: Keycode
BtnThumb :: Keycode
BtnThumb2 :: Keycode
BtnTop :: Keycode
BtnTop2 :: Keycode
BtnPinkie :: Keycode
BtnBase :: Keycode
BtnBase2 :: Keycode
BtnBase3 :: Keycode
BtnBase4 :: Keycode
BtnBase5 :: Keycode
BtnBase6 :: Keycode
Missing0x12c :: Keycode
Missing0x12d :: Keycode
Missing0x12e :: Keycode
BtnDead :: Keycode
BtnGamepad :: Keycode
BtnB :: Keycode
BtnC :: Keycode
BtnX :: Keycode
BtnY :: Keycode
BtnZ :: Keycode
BtnTL :: Keycode
BtnTR :: Keycode
BtnTL2 :: Keycode
BtnTR2 :: Keycode
BtnSelect :: Keycode
BtnStart :: Keycode
BtnMode :: Keycode
BtnThumbL :: Keycode
BtnThumbR :: Keycode
Missing0x13f :: Keycode
BtnDigi :: Keycode
BtnToolRubber :: Keycode
BtnToolBrush :: Keycode
BtnToolPencil :: Keycode
BtnToolAirbrush :: Keycode
BtnToolFinger :: Keycode
BtnToolMouse :: Keycode
BtnToolLens :: Keycode
BtnToolQuinttap :: Keycode
BtnStylus3 :: Keycode
BtnTouch :: Keycode
BtnStylus :: Keycode
BtnStylus2 :: Keycode
BtnToolDoubletap :: Keycode
BtnToolTripletap :: Keycode
BtnToolQuadtap :: Keycode
BtnGearDown :: Keycode
BtnGearUp :: Keycode
Missing0x152 :: Keycode
Missing0x153 :: Keycode
Missing0x154 :: Keycode
Missing0x155 :: Keycode
Missing0x156 :: Keycode
Missing0x157 :: Keycode
Missing0x158 :: Keycode
Missing0x159 :: Keycode
Missing0x15a :: Keycode
Missing0x15b :: Keycode
Missing0x15c :: Keycode
Missing0x15d :: Keycode
Missing0x15e :: Keycode
Missing0x15f :: Keycode
KeyOk :: Keycode
KeySelect :: Keycode
KeyGoTo :: Keycode
KeyClear :: Keycode
KeyPower2 :: Keycode
KeyOption :: Keycode
KeyInfo :: Keycode
KeyTime :: Keycode
KeyVendor :: Keycode
KeyArchive :: Keycode
KeyProgram :: Keycode
KeyChannel :: Keycode
KeyFavorites :: Keycode
KeyEpg :: Keycode
KeyPvr :: Keycode
KeyMhp :: Keycode
KeyLanguage :: Keycode
KeyTitle :: Keycode
KeySubtitle :: Keycode
KeyAngle :: Keycode
KeyZoom :: Keycode
KeyMode :: Keycode
KeyKeyboard :: Keycode
KeyScreen :: Keycode
KeyPc :: Keycode
KeyTv :: Keycode
KeyTv2 :: Keycode
KeyVcr :: Keycode
KeyVcr2 :: Keycode
KeySat :: Keycode
KeySat2 :: Keycode
KeyCd :: Keycode
KeyTape :: Keycode
KeyRadio :: Keycode
KeyTuner :: Keycode
KeyPlayer :: Keycode
KeyText :: Keycode
KeyDvd :: Keycode
KeyAux :: Keycode
KeyMp3 :: Keycode
KeyAudio :: Keycode
KeyVideo :: Keycode
KeyDirectory :: Keycode
KeyList :: Keycode
KeyMemo :: Keycode
KeyCalendar :: Keycode
KeyRed :: Keycode
KeyGreen :: Keycode
KeyYellow :: Keycode
KeyBlue :: Keycode
KeyChannelUp :: Keycode
KeyChannelDown :: Keycode
KeyFirst :: Keycode
KeyLast :: Keycode
KeyAb :: Keycode
KeyNextTask :: Keycode
KeyRestart :: Keycode
KeySlow :: Keycode
KeyShuffle :: Keycode
KeyBreak :: Keycode
KeyPreviousTask :: Keycode
KeyDigits :: Keycode
KeyTeen :: Keycode
KeyTwen :: Keycode
KeyVideoPhone :: Keycode
KeyGames :: Keycode
KeyZoomIn :: Keycode
KeyZoomOut :: Keycode
KeyZoomReset :: Keycode
KeyWordProcessor :: Keycode
KeyEditor :: Keycode
KeySpreadSheet :: Keycode
KeyGraphicsEditor :: Keycode
KeyPresentation :: Keycode
KeyDatabase :: Keycode
KeyNews :: Keycode
KeyVoicemail :: Keycode
KeyAddressBook :: Keycode
KeyMessenger :: Keycode
KeyBrightnessToggle :: Keycode
KeySpellCheck :: Keycode
KeyLogoff :: Keycode
KeyDollar :: Keycode
KeyEuro :: Keycode
KeyFrameBack :: Keycode
KeyFrameForward :: Keycode
KeyContextMenu :: Keycode
KeyMediaRepeat :: Keycode
Key10channelsUp :: Keycode
Key10channelsDown :: Keycode
KeyImages :: Keycode
Missing0x1bb :: Keycode
KeyNotificationCenter :: Keycode
KeyPickupPhone :: Keycode
KeyHangupPhone :: Keycode
Missing0x1bf :: Keycode
KeyDelEol :: Keycode
KeyDelEos :: Keycode
KeyInsLine :: Keycode
KeyDelLine :: Keycode
Missing0x1c4 :: Keycode
Missing0x1c5 :: Keycode
Missing0x1c6 :: Keycode
Missing0x1c7 :: Keycode
Missing0x1c8 :: Keycode
Missing0x1c9 :: Keycode
Missing0x1ca :: Keycode
Missing0x1cb :: Keycode
Missing0x1cc :: Keycode
Missing0x1cd :: Keycode
Missing0x1ce :: Keycode
Missing0x1cf :: Keycode
KeyFn :: Keycode
KeyFnEsc :: Keycode
KeyFnF1 :: Keycode
KeyFnF2 :: Keycode
KeyFnF3 :: Keycode
KeyFnF4 :: Keycode
KeyFnF5 :: Keycode
KeyFnF6 :: Keycode
KeyFnF7 :: Keycode
KeyFnF8 :: Keycode
KeyFnF9 :: Keycode
KeyFnF10 :: Keycode
KeyFnF11 :: Keycode
KeyFnF12 :: Keycode
KeyFn1 :: Keycode
KeyFn2 :: Keycode
KeyFnD :: Keycode
KeyFnE :: Keycode
KeyFnF :: Keycode
KeyFnS :: Keycode
KeyFnB :: Keycode
KeyFnRightShift :: Keycode
Missing0x1e6 :: Keycode
Missing0x1e7 :: Keycode
Missing0x1e8 :: Keycode
Missing0x1e9 :: Keycode
Missing0x1ea :: Keycode
Missing0x1eb :: Keycode
Missing0x1ec :: Keycode
Missing0x1ed :: Keycode
Missing0x1ee :: Keycode
Missing0x1ef :: Keycode
Missing0x1f0 :: Keycode
KeyBrlDot1 :: Keycode
KeyBrlDot2 :: Keycode
KeyBrlDot3 :: Keycode
KeyBrlDot4 :: Keycode
KeyBrlDot5 :: Keycode
KeyBrlDot6 :: Keycode
KeyBrlDot7 :: Keycode
KeyBrlDot8 :: Keycode
KeyBrlDot9 :: Keycode
KeyBrlDot10 :: Keycode
Missing0x1fb :: Keycode
Missing0x1fc :: Keycode
Missing0x1fd :: Keycode
Missing0x1fe :: Keycode
Missing0x1ff :: Keycode
KeyNumeric0 :: Keycode
KeyNumeric1 :: Keycode
KeyNumeric2 :: Keycode
KeyNumeric3 :: Keycode
KeyNumeric4 :: Keycode
KeyNumeric5 :: Keycode
KeyNumeric6 :: Keycode
KeyNumeric7 :: Keycode
KeyNumeric8 :: Keycode
KeyNumeric9 :: Keycode
KeyNumericStar :: Keycode
KeyNumericPound :: Keycode
KeyNumericA :: Keycode
KeyNumericB :: Keycode
KeyNumericC :: Keycode
KeyNumericD :: Keycode
KeyCameraFocus :: Keycode
KeyWpsButton :: Keycode
KeyTouchpadToggle :: Keycode
KeyTouchpadOn :: Keycode
KeyTouchpadOff :: Keycode
KeyCameraZoomIn :: Keycode
KeyCameraZoomOut :: Keycode
KeyCameraUp :: Keycode
KeyCameraDown :: Keycode
KeyCameraLeft :: Keycode
KeyCameraRight :: Keycode
KeyAttendantOn :: Keycode
KeyAttendantOff :: Keycode
KeyAttendantToggle :: Keycode
KeyLightsToggle :: Keycode
Missing0x21f :: Keycode
BtnDpadUp :: Keycode
BtnDpadDown :: Keycode
BtnDpadLeft :: Keycode
BtnDpadRight :: Keycode
Missing0x224 :: Keycode
Missing0x225 :: Keycode
Missing0x226 :: Keycode
Missing0x227 :: Keycode
Missing0x228 :: Keycode
Missing0x229 :: Keycode
Missing0x22a :: Keycode
Missing0x22b :: Keycode
Missing0x22c :: Keycode
Missing0x22d :: Keycode
Missing0x22e :: Keycode
Missing0x22f :: Keycode
KeyAlsToggle :: Keycode
KeyRotateLockToggle :: Keycode
KeyRefreshRateToggle :: Keycode
Missing0x233 :: Keycode
Missing0x234 :: Keycode
Missing0x235 :: Keycode
Missing0x236 :: Keycode
Missing0x237 :: Keycode
Missing0x238 :: Keycode
Missing0x239 :: Keycode
Missing0x23a :: Keycode
Missing0x23b :: Keycode
Missing0x23c :: Keycode
Missing0x23d :: Keycode
Missing0x23e :: Keycode
Missing0x23f :: Keycode
KeyButtonconfig :: Keycode
KeyTaskmanager :: Keycode
KeyJournal :: Keycode
KeyControlPanel :: Keycode
KeyAppSelect :: Keycode
KeyScreenSaver :: Keycode
KeyVoicecommand :: Keycode
KeyAssistant :: Keycode
KeyKbdLayoutNext :: Keycode
KeyEmojiPicker :: Keycode
KeyDictate :: Keycode
KeyCameraAccessEnable :: Keycode
KeyCameraAccessDisable :: Keycode
KeyCameraAccessToggle :: Keycode
KeyAccessibility :: Keycode
KeyDoNotDisturb :: Keycode
KeyBrightnessMin :: Keycode
KeyBrightnessMax :: Keycode
Missing0x252 :: Keycode
Missing0x253 :: Keycode
Missing0x254 :: Keycode
Missing0x255 :: Keycode
Missing0x256 :: Keycode
Missing0x257 :: Keycode
Missing0x258 :: Keycode
Missing0x259 :: Keycode
Missing0x25a :: Keycode
Missing0x25b :: Keycode
Missing0x25c :: Keycode
Missing0x25d :: Keycode
Missing0x25e :: Keycode
Missing0x25f :: Keycode
KeyKbdInputAssistPrev :: Keycode
KeyKbdInputAssistNext :: Keycode
KeyKbdInputAssistPrevgroup :: Keycode
KeyKbdInputAssistNextgroup :: Keycode
KeyKbdInputAssistAccept :: Keycode
KeyKbdInputAssistCancel :: Keycode
KeyRightUp :: Keycode
KeyRightDown :: Keycode
KeyLeftUp :: Keycode
KeyLeftDown :: Keycode
KeyRootMenu :: Keycode
KeyMediaTopMenu :: Keycode
KeyNumeric11 :: Keycode
KeyNumeric12 :: Keycode
KeyAudioDesc :: Keycode
Key3dMode :: Keycode
KeyNextFavorite :: Keycode
KeyStopRecord :: Keycode
KeyPauseRecord :: Keycode
KeyVod :: Keycode
KeyUnmute :: Keycode
KeyFastreverse :: Keycode
KeySlowreverse :: Keycode
KeyData :: Keycode
KeyOnScreenKeyboard :: Keycode
KeyPrivacyScreenToggle :: Keycode
KeySelectiveScreenshot :: Keycode
KeyNextElement :: Keycode
KeyPreviousElement :: Keycode
KeyAutopilotEngageToggle :: Keycode
KeyMarkWaypoint :: Keycode
KeySos :: Keycode
KeyNavChart :: Keycode
KeyFishingChart :: Keycode
KeySingleRangeRadar :: Keycode
KeyDualRangeRadar :: Keycode
KeyRadarOverlay :: Keycode
KeyTraditionalSonar :: Keycode
KeyClearvuSonar :: Keycode
KeySidevuSonar :: Keycode
KeyNavInfo :: Keycode
KeyBrightnessMenu :: Keycode
Missing0x28a :: Keycode
Missing0x28b :: Keycode
Missing0x28c :: Keycode
Missing0x28d :: Keycode
Missing0x28e :: Keycode
Missing0x28f :: Keycode
KeyMacro1 :: Keycode
KeyMacro2 :: Keycode
KeyMacro3 :: Keycode
KeyMacro4 :: Keycode
KeyMacro5 :: Keycode
KeyMacro6 :: Keycode
KeyMacro7 :: Keycode
KeyMacro8 :: Keycode
KeyMacro9 :: Keycode
KeyMacro10 :: Keycode
KeyMacro11 :: Keycode
KeyMacro12 :: Keycode
KeyMacro13 :: Keycode
KeyMacro14 :: Keycode
KeyMacro15 :: Keycode
KeyMacro16 :: Keycode
KeyMacro17 :: Keycode
KeyMacro18 :: Keycode
KeyMacro19 :: Keycode
KeyMacro20 :: Keycode
KeyMacro21 :: Keycode
KeyMacro22 :: Keycode
KeyMacro23 :: Keycode
KeyMacro24 :: Keycode
KeyMacro25 :: Keycode
KeyMacro26 :: Keycode
KeyMacro27 :: Keycode
KeyMacro28 :: Keycode
KeyMacro29 :: Keycode
KeyMacro30 :: Keycode
Missing0x2ae :: Keycode
Missing0x2af :: Keycode
KeyMacroRecordStart :: Keycode
KeyMacroRecordStop :: Keycode
KeyMacroPresetCycle :: Keycode
KeyMacroPreset1 :: Keycode
KeyMacroPreset2 :: Keycode
KeyMacroPreset3 :: Keycode
Missing0x2b6 :: Keycode
Missing0x2b7 :: Keycode
KeyKbdLcdMenu1 :: Keycode
KeyKbdLcdMenu2 :: Keycode
KeyKbdLcdMenu3 :: Keycode
KeyKbdLcdMenu4 :: Keycode
KeyKbdLcdMenu5 :: Keycode
Missing0x2bd :: Keycode
Missing0x2be :: Keycode
Missing0x2bf :: Keycode
BtnTriggerHappy :: Keycode
BtnTriggerHappy2 :: Keycode
BtnTriggerHappy3 :: Keycode
BtnTriggerHappy4 :: Keycode
BtnTriggerHappy5 :: Keycode
BtnTriggerHappy6 :: Keycode
BtnTriggerHappy7 :: Keycode
BtnTriggerHappy8 :: Keycode
BtnTriggerHappy9 :: Keycode
BtnTriggerHappy10 :: Keycode
BtnTriggerHappy11 :: Keycode
BtnTriggerHappy12 :: Keycode
BtnTriggerHappy13 :: Keycode
BtnTriggerHappy14 :: Keycode
BtnTriggerHappy15 :: Keycode
BtnTriggerHappy16 :: Keycode
BtnTriggerHappy17 :: Keycode
BtnTriggerHappy18 :: Keycode
BtnTriggerHappy19 :: Keycode
BtnTriggerHappy20 :: Keycode
BtnTriggerHappy21 :: Keycode
BtnTriggerHappy22 :: Keycode
BtnTriggerHappy23 :: Keycode
BtnTriggerHappy24 :: Keycode
BtnTriggerHappy25 :: Keycode
BtnTriggerHappy26 :: Keycode
BtnTriggerHappy27 :: Keycode
BtnTriggerHappy28 :: Keycode
BtnTriggerHappy29 :: Keycode
BtnTriggerHappy30 :: Keycode
BtnTriggerHappy31 :: Keycode
BtnTriggerHappy32 :: Keycode
BtnTriggerHappy33 :: Keycode
BtnTriggerHappy34 :: Keycode
BtnTriggerHappy35 :: Keycode
BtnTriggerHappy36 :: Keycode
BtnTriggerHappy37 :: Keycode
BtnTriggerHappy38 :: Keycode
BtnTriggerHappy39 :: Keycode
BtnTriggerHappy40 :: Keycode
Missing0x2e8 :: Keycode
Missing0x2e9 :: Keycode
Missing0x2ea :: Keycode
Missing0x2eb :: Keycode
Missing0x2ec :: Keycode
Missing0x2ed :: Keycode
Missing0x2ee :: Keycode
Missing0x2ef :: Keycode
Missing0x2f0 :: Keycode
Missing0x2f1 :: Keycode
Missing0x2f2 :: Keycode
Missing0x2f3 :: Keycode
Missing0x2f4 :: Keycode
Missing0x2f5 :: Keycode
Missing0x2f6 :: Keycode
Missing0x2f7 :: Keycode
Missing0x2f8 :: Keycode
Missing0x2f9 :: Keycode
Missing0x2fa :: Keycode
Missing0x2fb :: Keycode
Missing0x2fc :: Keycode
Missing0x2fd :: Keycode
Missing0x2fe :: Keycode
KeyLaunchpad :: Keycode
KeyMissionCtrl :: Keycode
KeySpotlight :: Keycode
KeyDictation :: Keycode

-- | A collection of <a>Keycode</a> to <a>Text</a> mappings
keyNames :: MultiMap Keycode Text
instance GHC.Enum.Bounded KMonad.Keyboard.Keycode.Keycode
instance Data.Data.Data KMonad.Keyboard.Keycode.Keycode
instance RIO.Prelude.Display.Display KMonad.Keyboard.Keycode.Keycode
instance GHC.Enum.Enum KMonad.Keyboard.Keycode.Keycode
instance GHC.Classes.Eq KMonad.Keyboard.Keycode.Keycode
instance GHC.Generics.Generic KMonad.Keyboard.Keycode.Keycode
instance Data.Hashable.Class.Hashable KMonad.Keyboard.Keycode.Keycode
instance GHC.Classes.Ord KMonad.Keyboard.Keycode.Keycode
instance GHC.Show.Show KMonad.Keyboard.Keycode.Keycode

module KMonad.Keyboard.Types

-- | KMonad recognizes 2 different types of actions: presses and releases.
--   Note that we do not handle repeat events at all.
data Switch
Press :: Switch
Release :: Switch

-- | An <a>KeyEvent</a> is a <a>Switch</a> on a particular <a>Keycode</a>
data KeyEvent

-- | Create a new <a>KeyEvent</a> from a <a>Switch</a> and a <a>Keycode</a>
mkKeyEvent :: Switch -> Keycode -> KeyEvent
class HasKeyEvent c
keyEvent :: HasKeyEvent c => Lens' c KeyEvent
keycode :: HasKeyEvent c => Lens' c Keycode
switch :: HasKeyEvent c => Lens' c Switch

-- | Predicate on KeyEvent's
type KeyPred = KeyEvent -> Bool

-- | Layers are identified by a tag that is simply a <a>Text</a> value.
type LayerTag = Text

-- | <a>LMap</a>s are mappings from <a>LayerTag</a>d maps from
--   <a>Keycode</a> to things.
type LMap a = LayerStack LayerTag Keycode a
instance RIO.Prelude.Display.Display KMonad.Keyboard.Types.KeyEvent
instance GHC.Enum.Enum KMonad.Keyboard.Types.Switch
instance GHC.Classes.Eq KMonad.Keyboard.Types.KeyEvent
instance GHC.Classes.Eq KMonad.Keyboard.Types.Switch
instance GHC.Generics.Generic KMonad.Keyboard.Types.KeyEvent
instance GHC.Generics.Generic KMonad.Keyboard.Types.Switch
instance KMonad.Keyboard.Types.HasKeyEvent KMonad.Keyboard.Types.KeyEvent
instance Data.Hashable.Class.Hashable KMonad.Keyboard.Types.KeyEvent
instance Data.Hashable.Class.Hashable KMonad.Keyboard.Types.Switch
instance GHC.Classes.Ord KMonad.Keyboard.Types.KeyEvent
instance GHC.Classes.Ord KMonad.Keyboard.Types.Switch
instance GHC.Show.Show KMonad.Keyboard.Types.KeyEvent
instance GHC.Show.Show KMonad.Keyboard.Types.Switch


module KMonad.Keyboard.IO

-- | A <a>KeySink</a> sends key actions to the OS
data KeySink

-- | Create a new <a>KeySink</a>
mkKeySink :: HasLogFunc e => RIO e snk -> (snk -> RIO e ()) -> (snk -> KeyEvent -> RIO e ()) -> RIO e (Acquire KeySink)

-- | Emit a key to the OS
emitKey :: HasLogFunc e => KeySink -> KeyEvent -> RIO e ()

-- | A <a>KeySource</a> is an action that awaits <a>KeyEvent</a>s from the
--   OS
data KeySource

-- | Create a new KeySource
mkKeySource :: HasLogFunc e => RIO e src -> (src -> RIO e ()) -> (src -> RIO e KeyEvent) -> RIO e (Acquire KeySource)

-- | Wait for the next key from the OS
awaitKey :: HasLogFunc e => KeySource -> RIO e KeyEvent

module KMonad.Keyboard.Ops
switch :: HasKeyEvent c => Lens' c Switch
keycode :: HasKeyEvent c => Lens' c Keycode

-- | Create a new <a>KeyEvent</a> from a <a>Switch</a> and a <a>Keycode</a>
mkKeyEvent :: Switch -> Keycode -> KeyEvent

-- | Create a <a>KeyEvent</a> that represents pressing a key
mkPress :: Keycode -> KeyEvent

-- | Create a <a>KeyEvent</a> that represents releaseing a key
mkRelease :: Keycode -> KeyEvent

-- | Return whether the provided KeyEvent is a Press
isPress :: KeyPred

-- | Return whether the provided KeyEvent is a Release
isRelease :: KeyPred

-- | Return whether the provided KeyEvent matches a particular Keycode
isKeycode :: Keycode -> KeyPred

-- | Return whether the provided KeyEvent matches the press of the Keycode
isPressOf :: Keycode -> KeyPred

-- | Returth whether the provided KeyEvent matches the release of the
--   Keycode
isReleaseOf :: Keycode -> KeyPred


-- | Interface to the Keyboard module
module KMonad.Keyboard


-- | For certain KMonad operations we need to be able to pause and resume
--   processing of events. This component provides the ability to
--   temporarily pause processing, and then resume processing and return
--   all events that were caught while paused.
module KMonad.Model.Sluice

-- | The <a>Sluice</a> environment.
--   
--   NOTE: <a>Sluice</a> has no internal multithreading, i.e. its
--   <tt>pull</tt> action will never be interrupted, therefore we can
--   simply use <a>IORef</a> and sidestep all the STM complications.
data Sluice

-- | Create a new <a>Sluice</a> environment, but do so in a ContT context
mkSluice :: MonadUnliftIO m => m KeyEvent -> ContT r m Sluice

-- | Increase the block-count by 1
block :: HasLogFunc e => Sluice -> RIO e ()

-- | Set the Sluice to unblocked mode, return a list of all the stored
--   events that should be rerun, in the correct order (head was first-in,
--   etc).
--   
--   NOTE: After successfully unblocking the <a>Sluice</a> will be empty,
--   it is the caller's responsibility to insert the returned events at an
--   appropriate location in the <a>App</a>.
--   
--   We do this in KMonad by writing the events into the <a>Dispatch</a>s
--   rerun buffer. (this happens in the <a>KMonad.App</a> module.)
unblock :: HasLogFunc e => Sluice -> RIO e [KeyEvent]

-- | Keep trying to read from the Sluice until an event passes through
pull :: HasLogFunc e => Sluice -> RIO e KeyEvent

module KMonad.Model.Dispatch

-- | The <a>Dispatch</a> environment
data Dispatch

-- | Create a new <a>Dispatch</a> environment in a <a>ContT</a> environment
mkDispatch :: MonadUnliftIO m => m KeyEvent -> ContT r m Dispatch

-- | Return the next event, this will return either (in order of
--   precedence): 1. The next item to be rerun 2. A new item read from the
--   OS 3. Pausing until either 1. or 2. triggers
pull :: HasLogFunc e => Dispatch -> RIO e KeyEvent

-- | Add a list of elements to be rerun.
rerun :: HasLogFunc e => Dispatch -> [KeyEvent] -> RIO e ()


-- | KMonad is implemented as an engine that is capable of running
--   <a>MonadK</a> actions. The logic of various different buttons and
--   keyboard operations are expressed in this <a>MonadK</a>. This module
--   defines the basic types and operations that make up <a>MonadK</a>. The
--   implementation of how KMonad implements <a>MonadK</a> can be found in
--   the <a>KMonad.App</a> module.
--   
--   NOTE: All of this is a bit muddled, and redoing the way hooks are
--   handled, and the basic structuring of MonadK and MonadKIO are liable
--   to change soon.
module KMonad.Model.Action

-- | Predicate on KeyEvent's
type KeyPred = KeyEvent -> Bool

-- | Boolean isomorph signalling whether an event should be caught or not.
data Catch
Catch :: Catch
NoCatch :: Catch

-- | The packet used to trigger a KeyFun, containing info about the event
--   and how long since the Hook was registered.
data Trigger
Trigger :: Milliseconds -> KeyEvent -> Trigger

-- | Time elapsed since hook was registered
[_elapsed] :: Trigger -> Milliseconds

-- | The key event triggering this call
[_event] :: Trigger -> KeyEvent

-- | A <a>Timeout</a> value describes how long to wait and what to do upon
--   timeout
data Timeout (m :: Type -> Type)
Timeout :: Milliseconds -> m () -> Timeout (m :: Type -> Type)

-- | Delay before timeout action is triggered
[_delay] :: Timeout (m :: Type -> Type) -> Milliseconds

-- | Action to perform upon timeout
[_action] :: Timeout (m :: Type -> Type) -> m ()

-- | ADT signalling where to install a hook
data HookLocation

-- | Install the hook immediately after receiving a <a>KeyEvent</a>
InputHook :: HookLocation

-- | Install the hook just before emitting a <a>KeyEvent</a>
OutputHook :: HookLocation

-- | The content for 1 key hook
data Hook (m :: Type -> Type)
Hook :: Maybe (Timeout m) -> (Trigger -> m Catch) -> Hook (m :: Type -> Type)

-- | Optional timeout machinery
[_hTimeout] :: Hook (m :: Type -> Type) -> Maybe (Timeout m)

-- | The function to call on the next <a>KeyEvent</a>
[_keyH] :: Hook (m :: Type -> Type) -> Trigger -> m Catch
class HasHook c (m :: Type -> Type) | c -> m
hook :: HasHook c m => Lens' c (Hook m)
hTimeout :: HasHook c m => Lens' c (Maybe (Timeout m))
keyH :: HasHook c m => Lens' c (Trigger -> m Catch)
class HasTimeout c (m :: Type -> Type) | c -> m
timeout :: HasTimeout c m => Lens' c (Timeout m)
action :: HasTimeout c m => Lens' c (m ())
delay :: HasTimeout c m => Lens' c Milliseconds
class HasTrigger c
trigger :: HasTrigger c => Lens' c Trigger
elapsed :: HasTrigger c => Lens' c Milliseconds
event :: HasTrigger c => Lens' c KeyEvent

-- | <a>LayerOp</a> describes all the different layer-manipulations that
--   KMonad supports.
data LayerOp

-- | Add a layer to the top of the stack
PushLayer :: LayerTag -> LayerOp

-- | Remove the first occurence of a layer
PopLayer :: LayerTag -> LayerOp

-- | Change the base-layer
SetBaseLayer :: LayerTag -> LayerOp

-- | <a>MonadK</a> contains all the operations used to constitute button
--   actions. It encapsulates all the side-effects required to get
--   everything running.
class Monad m => MonadKIO (m :: Type -> Type)

-- | Emit a KeyEvent to the OS
emit :: MonadKIO m => KeyEvent -> m ()

-- | Pause the current thread for n milliseconds
pause :: MonadKIO m => Milliseconds -> m ()

-- | Pause or unpause event processing
hold :: MonadKIO m => Bool -> m ()

-- | Register a callback hook
register :: MonadKIO m => HookLocation -> Hook m -> m ()

-- | Run a layer-stack manipulation
layerOp :: MonadKIO m => LayerOp -> m ()

-- | Insert an event in the input queue
inject :: MonadKIO m => KeyEvent -> m ()

-- | Run a shell-command
shellCmd :: MonadKIO m => Text -> m ()

-- | <a>MonadKIO</a> contains the additional bindings that get added when
--   we are currently processing a button.
class MonadKIO m => MonadK (m :: Type -> Type)

-- | Access the keycode to which the current button is bound
myBinding :: MonadK m => m Keycode

-- | Type alias for `any monad that can perform MonadK actions`
type AnyK a = forall (m :: Type -> Type). MonadK m => m a

-- | A newtype wrapper used to construct <a>MonadK</a> actions
newtype Action
Action :: AnyK () -> Action
[runAction] :: Action -> AnyK ()

-- | Create a KeyEvent matching pressing or releasing of the current
--   button.
my :: MonadK m => Switch -> m KeyEvent

-- | Create a KeyPred that matches the Press or Release of the current
--   button.
matchMy :: MonadK m => Switch -> m KeyPred

-- | Perform an action after a period of time has elapsed
--   
--   This is essentially just a way to perform async actions using the
--   KMonad hook system.
after :: MonadK m => Milliseconds -> m () -> m ()

-- | Perform an action immediately after the current action is finished.
--   NOTE: there is no guarantee that another event doesn't outrace this,
--   only that it will happen as soon as the CPU gets to it.
whenDone :: MonadK m => m () -> m ()

-- | Wait for an event to match a predicate and then execute an action
await :: MonadKIO m => KeyPred -> (KeyEvent -> m Catch) -> m ()

-- | Execute an action on the detection of the Switch of the active button.
awaitMy :: MonadK m => Switch -> m Catch -> m ()

-- | Register a hook with a timeout
tHookF :: MonadK m => HookLocation -> Milliseconds -> m () -> (Trigger -> m Catch) -> m ()

-- | Register a simple hook without a timeout
hookF :: MonadKIO m => HookLocation -> (KeyEvent -> m Catch) -> m ()

-- | Try to call a function on a succesful match of a predicate within a
--   certain time period. On a timeout, perform an action.
within :: MonadK m => Milliseconds -> m KeyPred -> m () -> (Trigger -> m Catch) -> m ()

-- | Like <a>within</a>, but acquires a hold when starting, and releases
--   when done
withinHeld :: MonadK m => Milliseconds -> m KeyPred -> m () -> (Trigger -> m Catch) -> m ()
instance GHC.Classes.Eq KMonad.Model.Action.Catch
instance GHC.Classes.Eq KMonad.Model.Action.HookLocation
instance KMonad.Model.Action.HasHook (KMonad.Model.Action.Hook m) m
instance KMonad.Model.Action.HasTimeout (KMonad.Model.Action.Timeout m) m
instance KMonad.Model.Action.HasTrigger KMonad.Model.Action.Trigger
instance GHC.Base.Monoid KMonad.Model.Action.Catch
instance GHC.Base.Semigroup KMonad.Model.Action.Catch
instance GHC.Show.Show KMonad.Model.Action.Catch
instance GHC.Show.Show KMonad.Model.Action.HookLocation


-- | Part of the KMonad deferred-decision mechanics are implemented using
--   hooks, which will call predicates and actions on future keypresses
--   and/or timer events. The <a>Hooks</a> component is the concrete
--   implementation of this functionality.
--   
--   In the sequencing of components, this happens second, right after the
--   <a>Dispatch</a> component.
module KMonad.Model.Hooks

-- | The <a>Hooks</a> environment that is required for keeping track of all
--   the different targets and callbacks.
data Hooks

-- | Create a new <a>Hooks</a> environment, but as a <a>ContT</a> monad to
--   avoid nesting
mkHooks :: MonadUnliftIO m => m KeyEvent -> ContT r m Hooks

-- | Keep stepping until we succesfully get an unhandled <a>KeyEvent</a>
pull :: HasLogFunc e => Hooks -> RIO e KeyEvent

-- | Insert a hook, along with the current time, into the store
register :: HasLogFunc e => Hooks -> Hook (RIO e) -> RIO e ()
instance KMonad.Model.Action.HasHook KMonad.Model.Hooks.Entry GHC.Types.IO


-- | A button contains 2 actions, one to perform on press, and another to
--   perform on release. This module contains that definition, and some
--   helper code that helps combine buttons. It is here that most of the
--   complicated` buttons are implemented (like TapHold).
module KMonad.Model.Button

-- | A <a>Button</a> consists of three <a>MonadK</a> actions, one to take
--   when a press is registered from the OS, and another when a release is
--   registered. With a third when both should happen in sequence. This
--   will only be used by other button such as `tap-macro`. Use
--   <tt>mkButton</tt> instead of this constructor.
data Button
class HasButton c
button :: HasButton c => Lens' c Button
pressAction :: HasButton c => Lens' c Action
releaseAction :: HasButton c => Lens' c Action
tapAction :: HasButton c => Lens' c Action

-- | Create a new button with only a <a>Press</a> action
onPress :: AnyK () -> Button
onRelease :: AnyK () -> Button
onTap :: AnyK () -> Button

-- | Create a <a>Button</a> out of a press and release action
--   
--   NOTE: Since <a>AnyK</a> is an existentially qualified <a>MonadK</a>,
--   the monadic actions specified must be runnable by all implementations
--   of <a>MonadK</a>, and therefore can only rely on functionality from
--   <a>MonadK</a>. I.e. the actions must be pure <a>MonadK</a>.
mkButton :: AnyK () -> AnyK () -> Button

-- | Create a new button from 2 buttons, an inner and an outer. When the
--   new button is pressed, first the outer is pressed, then the inner. On
--   release, the inner is released first, and then the outer.
around :: Button -> Button -> Button

-- | Create a new button that performs both a press and release of the
--   input button on just a press or release
tapOn :: Switch -> Button -> Button

-- | A button that emits a Press of a keycode when pressed, and a release
--   when released.
emitB :: Keycode -> Button

-- | A button that emits only a Press of a keycode.
pressOnly :: Keycode -> Button

-- | A button that emits only a Release of a keycode.
releaseOnly :: Keycode -> Button

-- | Create a new button that first presses a <a>Keycode</a> before running
--   an inner button, releasing the <a>Keycode</a> again after the inner
--   <a>Button</a> is released.
modded :: Keycode -> Button -> Button

-- | Create a button that toggles a layer on and off
layerToggle :: LayerTag -> Button

-- | Create a button that switches the base-layer on a press
layerSwitch :: LayerTag -> Button

-- | Create a button that adds a layer on a press
layerAdd :: LayerTag -> Button

-- | Create a button that removes the top instance of a layer on a press
layerRem :: LayerTag -> Button

-- | Create a button that does nothing (but captures the input)
pass :: Button

-- | Create a button that executes a shell command on press and possibly on
--   release
cmdButton :: Text -> Maybe Text -> Button

-- | A variant of <a>around</a>, which releases its outer button when
--   another key is pressed.
aroundOnly :: Button -> Button -> Button

-- | A variant of `around-only` that represses its outer button when all
--   other keys after it have been released.
aroundWhenAlone :: Button -> Button -> Button

-- | A <a>Button</a> that, once pressed, will surround the next button with
--   another.
--   
--   Think of this as, essentially, a tappable mod. For example, an
--   'aroundNext KeyCtrl' would, once tapped, then make the next keypress
--   C-<a>whatever</a>.
aroundNext :: Button -> Button

-- | A <a>Button</a> that, once pressed, will surround the next button
--   within some timeout with another.
--   
--   If some other key is not pressed within an interval another button
--   will be triggered as a tap.
aroundNextTimeout :: Milliseconds -> Button -> Button -> Button

-- | A <a>Button</a> that, once pressed, will surround the next button with
--   another.
--   
--   Think of this as, essentially, a tappable mod. For example, an
--   'aroundNext KeyCtrl' would, once tapped, then make the next keypress
--   C-<a>whatever</a>.
--   
--   This differs from <a>aroundNext</a> in that it explicitly releases the
--   modifier immediately after the first event, where
--   <tt>aroundSingle</tt> waits around for the original key that was
--   modified to be released itself.
aroundNextSingle :: Button -> Button

-- | Surround some future button with a before and after tap
beforeAfterNext :: Button -> Button -> Button

-- | Switch to a layer for a period of time, then automatically switch back
layerDelay :: Milliseconds -> LayerTag -> Button

-- | Switch to a layer for the next button-press and switch back
--   automaically.
--   
--   NOTE: liable to change, this is essentially just <a>aroundNext</a> and
--   <a>layerToggle</a> combined.
layerNext :: LayerTag -> Button

-- | Create a <a>Button</a> that performs a tap of one button if it is
--   released within an interval. If the interval is exceeded, press the
--   other button (and release it when a release is detected).
tapHold :: Milliseconds -> Button -> Button -> Button

-- | Create a <a>Button</a> that contains a number of delays and
--   <a>Button</a>s. As long as the next press is registered before the
--   timeout, the multiTap descends into its list. The moment a delay is
--   exceeded or immediately upon reaching the last button, that button is
--   pressed.
multiTap :: Button -> [(Milliseconds, Button)] -> Button

-- | Create a <a>Button</a> that performs a tap of 1 button if the next
--   event is its own release, or else switches to holding some other
--   button if the next event is a different keypress.
tapNext :: Button -> Button -> Button

-- | Like <a>tapNext</a>, except that after some interval it switches
--   anyways
tapHoldNext :: Milliseconds -> Button -> Button -> Maybe Button -> Button

-- | Create a tap-hold style button that makes its decision based on the
--   next detected release in the following manner: 1. It is the release of
--   this button: We are tapping 2. It is of some other button that was
--   pressed *before* this one, ignore. 3. It is of some other button that
--   was pressed *after* this one, we hold.
--   
--   It does all of this while holding processing of other buttons, so time
--   will get rolled back like a TapHold button.
tapNextRelease :: Button -> Button -> Button

-- | Create a tap-hold style button that makes its decision based on the
--   next detected release in the following manner: 1. It is the release of
--   this button: We are tapping 2. It is of some other button that was
--   pressed *before* this one, ignore. 3. It is of some other button that
--   was pressed *after* this one, we hold.
--   
--   If we encounter the timeout before any other release, we switch to the
--   specified timeout button, or to the hold button if none is specified.
--   
--   It does all of this while holding processing of other buttons, so time
--   will get rolled back like a TapHold button.
tapHoldNextRelease :: Milliseconds -> Button -> Button -> Maybe Button -> Button

-- | Create a button just like tap-release, but also trigger a hold on
--   presses: 1. It is the release of this button: We are tapping 2. It is
--   the press of some other button, we hold 3. It is the release of some
--   other button, ignore.
tapNextPress :: Button -> Button -> Button

-- | This button is to 'tap-next-press' what 'tap-hold-next' is to
--   'tap-next'
tapHoldNextPress :: Milliseconds -> Button -> Button -> Maybe Button -> Button

-- | Create a <a>Button</a> that performs a series of taps on press. Note
--   that the last button is only released when the tapMacro itself is
--   released.
tapMacro :: [Button] -> Button

-- | Create a <a>Button</a> that performs a series of taps on press, except
--   for the last Button, which is tapped on release.
tapMacroRelease :: [Button] -> Button

-- | Create a button that functions as a different button everything it is
--   pushed
--   
--   I.e: first it acts as the first button, then as the second, then as
--   the third, and when finished rotates back to being the first button.
steppedButton :: [Button] -> Button

-- | Make a button into a sticky-key, i.e. a key that acts like it is
--   pressed for the button after it if that button was pressed in the
--   given timeframe.
stickyKey :: Milliseconds -> Button -> Button
instance KMonad.Model.Button.HasButton KMonad.Model.Button.Button


-- | When running KMonad, we need to keep track the last switchstate of a
--   <a>Button</a>, because we only allowing switching, (we have to filter
--   out repeated <a>Press</a> or <a>Release</a> events). Additionally, we
--   keep track of what <a>Keycode</a> a button is bound to, to provide the
--   <a>myBinding</a> functionality from <a>MonadK</a>.
module KMonad.Model.BEnv

-- | The configuration of a <a>Button</a> with some additional state to
--   keep track of the last <a>Switch</a>
data BEnv
BEnv :: !Button -> !Keycode -> !MVar Switch -> BEnv

-- | The configuration for this button
[_beButton] :: BEnv -> !Button

-- | The <a>Keycode</a> to which this button is bound
[_binding] :: BEnv -> !Keycode

-- | State to keep track of last manipulation
[_lastSwitch] :: BEnv -> !MVar Switch
class HasBEnv c
bEnv :: HasBEnv c => Lens' c BEnv
beButton :: HasBEnv c => Lens' c Button
binding :: HasBEnv c => Lens' c Keycode
lastSwitch :: HasBEnv c => Lens' c (MVar Switch)

-- | Initialize a <a>BEnv</a>, note that a key is always initialized in an
--   unpressed state.
initBEnv :: MonadIO m => Button -> Keycode -> m BEnv

-- | Try to switch a <a>BEnv</a>. This only does something if the
--   <a>Switch</a> is different from the <a>lastSwitch</a> field. I.e.
--   pressing a pressed button or releasing a released button does nothing.
runBEnv :: MonadUnliftIO m => BEnv -> Switch -> m (Maybe Action)
instance KMonad.Model.BEnv.HasBEnv KMonad.Model.BEnv.BEnv
instance KMonad.Model.Button.HasButton KMonad.Model.BEnv.BEnv


-- | In KMonad we handle all releases (and some other actions) via callback
--   mechanisms. It is the button-presses that get handled through a
--   keymap. It is the <a>Keymap</a> component that manages the keymap
--   state and ensures that incoming events are mapped to
module KMonad.Model.Keymap

-- | The <a>Keymap</a> environment containing the current keymap
--   
--   NOTE: Since the <a>Keymap</a> will never have to deal with anything
--   asynchronously we can simply use <a>IORef</a>s here.
data Keymap

-- | Create a <a>Keymap</a> but do so in the context of a <a>ContT</a>
--   monad to ease nesting.
mkKeymap :: forall (m :: Type -> Type) r. MonadUnliftIO m => LayerTag -> LMap Button -> ContT r m Keymap

-- | Perform operations on the layer-stack
layerOp :: HasLogFunc e => Keymap -> LayerOp -> RIO e ()

-- | Lookup the <a>BEnv</a> currently mapped to the key press.
lookupKey :: MonadIO m => Keymap -> Keycode -> m (Maybe BEnv)
instance KMonad.Model.Keymap.HasKeymap KMonad.Model.Keymap.Keymap

module KMonad.Model


-- | Windows in general. There is some translation happening in the c-code.
module KMonad.Keyboard.IO.Windows.Types

-- | Everything that can go wrong with Windows Key-IO
data WinError

-- | Error translating to <a>WinKeycode</a>
NoWinKeycodeTo :: Keycode -> WinError

-- | Error translating from <a>WinKeycode</a>
NoWinKeycodeFrom :: WinKeycode -> WinError

-- | <a>WinKeyEvent</a> is the C-representation of a a <a>KeyEvent</a> for
--   our Windows API.
--   
--   It contains a <a>Word8</a> signifying whether the event was a Press
--   (0) or Release (1), and a <a>Word32</a> (Windows <tt>DWORD</tt>)
--   signifying the *Windows keycode*.
--   
--   NOTE: Windows and Linux keycodes do not line up. Internally we use
--   Linux Keycodes for everything, we translate at the KeyIO stage (here).
data WinKeyEvent
mkWinKeyEvent :: WinSwitch -> WinKeycode -> WinKeyEvent

-- | Convert a <a>KeyEvent</a> to a <a>WinKeyEvent</a>
--   
--   NOTE: Windows keycodes are different, and I am not confident I have
--   full coverage, therefore this conversion is not total. We are going to
--   leave this error-handling in until we are sure this is covered well.
--   Once it lines up perfectly, this is essentially an Iso.
toWinKeyEvent :: KeyEvent -> Either WinError WinKeyEvent

-- | Convert a <a>WinKeyEvent</a> to a <a>KeyEvent</a>
--   
--   NOTE: Same limitations as <a>toWinKeyEvent</a> apply
fromWinKeyEvent :: WinKeyEvent -> Either WinError KeyEvent

-- | A table of which virtual-key code from Windows correspond to which
--   KMonad KeyCode. This table may have the same virtual-key code from
--   Windows multiple times and also may have the same KMonad KeyCode
--   multiple times.
--   
--   It is essentially a merge of <a>winCodeToKeyCode</a> and
--   <a>keyCodeToWinCode</a>.
winCodeKeyCodeMapping :: [(WinKeycode, Keycode)]
instance GHC.Classes.Eq KMonad.Keyboard.IO.Windows.Types.WinKeyEvent
instance GHC.Exception.Type.Exception KMonad.Keyboard.IO.Windows.Types.WinError
instance GHC.Classes.Ord KMonad.Keyboard.IO.Windows.Types.WinKeyEvent
instance GHC.Show.Show KMonad.Keyboard.IO.Windows.Types.WinError
instance GHC.Show.Show KMonad.Keyboard.IO.Windows.Types.WinKeyEvent
instance Foreign.Storable.Storable KMonad.Keyboard.IO.Windows.Types.WinKeyEvent

module KMonad.Keyboard.IO.Mac.Types

-- | Everything that can go wrong with Mac Key-IO
data MacError

-- | Error translating to <a>MacKeycode</a>
NoMacKeycodeTo :: Keycode -> MacError

-- | Error translating from <a>MacKeycode</a>
NoMacKeycodeFrom :: MacKeycode -> MacError

-- | Error interpreting <a>MacSwitch</a>
BadMacSwitch :: MacSwitch -> MacError

-- | <a>MacKeyEvent</a> is the C-representation of a a <a>KeyEvent</a> for
--   our Mac API.
--   
--   It contains a <a>Word8</a> signifying whether the event was a Press
--   (0) or Release (1), and a <a>Word32</a> (uint32_t) signifying the Mac
--   keycode (the upper 16 bits represent the IOKit usage page, and the
--   lower 16 bits represent the IOKit usage).
--   
--   NOTE: Mac and Linux keycodes do not line up. Internally we use Linux
--   Keycodes for everything, we translate at the KeyIO stage (here).
data MacKeyEvent

-- | Convert a <a>KeyEvent</a> to a <a>MacKeyEvent</a>
--   
--   NOTE: Mac keycodes are different, and I am not confident I have full
--   coverage, therefore this conversion is not total. We are going to
--   leave this error-handling in until we are sure this is covered well.
--   Once it lines up perfectly, this is essentially an Iso.
toMacKeyEvent :: KeyEvent -> Either MacError MacKeyEvent

-- | Convert a <a>MacKeyEvent</a> to a <a>KeyEvent</a>
--   
--   NOTE: Same limitations as <a>toMacKeyEvent</a> apply
fromMacKeyEvent :: MacKeyEvent -> Maybe (Either [MacError] KeyEvent)
kcMapRaw :: [(MacKeycode, Keycode)]
instance GHC.Classes.Eq KMonad.Keyboard.IO.Mac.Types.MacKeyEvent
instance GHC.Exception.Type.Exception [KMonad.Keyboard.IO.Mac.Types.MacError]
instance GHC.Exception.Type.Exception KMonad.Keyboard.IO.Mac.Types.MacError
instance GHC.Classes.Ord KMonad.Keyboard.IO.Mac.Types.MacKeyEvent
instance GHC.Show.Show KMonad.Keyboard.IO.Mac.Types.MacError
instance GHC.Show.Show KMonad.Keyboard.IO.Mac.Types.MacKeyEvent
instance Foreign.Storable.Storable KMonad.Keyboard.IO.Mac.Types.MacKeyEvent


module KMonad.Keyboard.IO.Linux.Types

-- | The LinuxKeyEvent datatype
newtype LinuxKeyEvent
LinuxKeyEvent :: (CInt, CInt, CInt, CInt, CInt) -> LinuxKeyEvent

-- | A smart constructor that casts from any integral
linuxKeyEvent :: (Integral a, Integral b, Integral c, Integral d, Integral e) => (a, b, c, d, e) -> LinuxKeyEvent

-- | Constructor for linux sync events. Whenever you write an event to
--   linux, you need to emit a <a>sync</a> to signal to linux that it
--   should sync all queued updates.
sync :: SystemTime -> LinuxKeyEvent

-- | Translate KMonad <a>KeyEvent</a> along with a <a>SystemTime</a> to
--   <a>LinuxKeyEvent</a>s for writing.
toLinuxKeyEvent :: KeyEvent -> SystemTime -> LinuxKeyEvent

-- | Translate a <a>LinuxKeyEvent</a> to a KMonad <a>KeyEvent</a>
fromLinuxKeyEvent :: LinuxKeyEvent -> Maybe KeyEvent
instance RIO.Prelude.Display.Display KMonad.Keyboard.IO.Linux.Types.LinuxKeyEvent
instance GHC.Show.Show KMonad.Keyboard.IO.Linux.Types.LinuxKeyEvent


module KMonad.Keyboard.IO.Linux.UinputSink

-- | UinputSink is an MVar to a filehandle
data UinputSink

-- | Configuration of the Uinput keyboard to instantiate
data UinputCfg
UinputCfg :: !CInt -> !CInt -> !CInt -> !String -> !Maybe String -> UinputCfg
[_vendorCode] :: UinputCfg -> !CInt
[_productCode] :: UinputCfg -> !CInt
[_productVersion] :: UinputCfg -> !CInt
[_keyboardName] :: UinputCfg -> !String
[_postInit] :: UinputCfg -> !Maybe String
keyboardName :: HasUinputCfg c => Lens' c String
vendorCode :: HasUinputCfg c => Lens' c CInt
productCode :: HasUinputCfg c => Lens' c CInt
productVersion :: HasUinputCfg c => Lens' c CInt
postInit :: HasUinputCfg c => Lens' c (Maybe String)

-- | Return a new uinput <a>KeySink</a> with extra options
uinputSink :: HasLogFunc e => UinputCfg -> RIO e (Acquire KeySink)

-- | Default Uinput configuration
defUinputCfg :: UinputCfg
instance KMonad.Keyboard.IO.Linux.UinputSink.AsUinputSinkError KMonad.Keyboard.IO.Linux.UinputSink.UinputSinkError
instance GHC.Classes.Eq KMonad.Keyboard.IO.Linux.UinputSink.UinputCfg
instance GHC.Exception.Type.Exception KMonad.Keyboard.IO.Linux.UinputSink.UinputSinkError
instance KMonad.Keyboard.IO.Linux.UinputSink.HasUinputCfg KMonad.Keyboard.IO.Linux.UinputSink.UinputCfg
instance GHC.Show.Show KMonad.Keyboard.IO.Linux.UinputSink.UinputCfg
instance GHC.Show.Show KMonad.Keyboard.IO.Linux.UinputSink.UinputSinkError


module KMonad.Keyboard.IO.Linux.DeviceSource

-- | Open a device file
deviceSource :: HasLogFunc e => KeyEventParser -> FilePath -> RIO e (Acquire KeySource)

-- | Open a device file on a standard linux 64 bit architecture
deviceSource64 :: HasLogFunc e => FilePath -> RIO e (Acquire KeySource)

-- | A <a>KeyEventParser</a> describes how to read and parse
--   <a>LinuxKeyEvent</a>s from the binary data-stream provided by the
--   device-file.
data KeyEventParser

-- | The KeyEventParser that works on my 64-bit Linux environment
decode64 :: ByteString -> Either String LinuxKeyEvent
instance KMonad.Keyboard.IO.Linux.DeviceSource.AsDeviceSourceError KMonad.Keyboard.IO.Linux.DeviceSource.DeviceSourceError
instance GHC.Exception.Type.Exception KMonad.Keyboard.IO.Linux.DeviceSource.DeviceSourceError
instance KMonad.Keyboard.IO.Linux.DeviceSource.HasDeviceFile KMonad.Keyboard.IO.Linux.DeviceSource.DeviceFile
instance KMonad.Keyboard.IO.Linux.DeviceSource.HasDeviceSourceCfg KMonad.Keyboard.IO.Linux.DeviceSource.DeviceFile
instance KMonad.Keyboard.IO.Linux.DeviceSource.HasDeviceSourceCfg KMonad.Keyboard.IO.Linux.DeviceSource.DeviceSourceCfg
instance KMonad.Keyboard.IO.Linux.DeviceSource.HasKeyEventParser KMonad.Keyboard.IO.Linux.DeviceSource.DeviceFile
instance KMonad.Keyboard.IO.Linux.DeviceSource.HasKeyEventParser KMonad.Keyboard.IO.Linux.DeviceSource.KeyEventParser
instance GHC.Show.Show KMonad.Keyboard.IO.Linux.DeviceSource.DeviceSourceError


module KMonad.Args.Types

-- | The <a>CfgToken</a> contains all the data needed to construct an
--   <a>AppCfg</a>.
data CfgToken
CfgToken :: (LogFunc -> IO (Acquire KeySource)) -> (LogFunc -> IO (Acquire KeySink)) -> LMap Button -> LayerTag -> Bool -> Bool -> Maybe Int -> CfgToken

-- | How to grab the source keyboard
[_src] :: CfgToken -> LogFunc -> IO (Acquire KeySource)

-- | How to construct the out keybboard
[_snk] :: CfgToken -> LogFunc -> IO (Acquire KeySink)

-- | An <a>LMap</a> of <a>Button</a> actions
[_km] :: CfgToken -> LMap Button

-- | Name of initial layer
[_fstL] :: CfgToken -> LayerTag

-- | How to deal with unhandled events
[_flt] :: CfgToken -> Bool

-- | Whether to allow shell commands
[_allow] :: CfgToken -> Bool

-- | Output delay between keys
[_ksd] :: CfgToken -> Maybe Int

-- | Button ADT
data DefButton

-- | Reference a named button
KRef :: Text -> DefButton

-- | Emit a keycode
KEmit :: Keycode -> DefButton

-- | Emit only the press of a keycode
KPressOnly :: Keycode -> DefButton

-- | Emit only the release of a keycode
KReleaseOnly :: Keycode -> DefButton

-- | Toggle to a layer when held
KLayerToggle :: Text -> DefButton

-- | Switch base-layer when pressed
KLayerSwitch :: Text -> DefButton

-- | Add a layer when pressed
KLayerAdd :: Text -> DefButton

-- | Remove top instance of a layer when pressed
KLayerRem :: Text -> DefButton

-- | Do 2 things based on behavior
KTapNext :: DefButton -> DefButton -> DefButton

-- | Do 2 things based on behavior and delay
KTapHold :: Int -> DefButton -> DefButton -> DefButton

-- | Mixture between KTapNext and KTapHold
KTapHoldNext :: Int -> DefButton -> DefButton -> Maybe DefButton -> DefButton

-- | Do 2 things based on behavior
KTapNextRelease :: DefButton -> DefButton -> DefButton

-- | Like KTapNextRelease but with a timeout
KTapHoldNextRelease :: Int -> DefButton -> DefButton -> Maybe DefButton -> DefButton

-- | Like KTapNextRelease but also hold on presses
KTapNextPress :: DefButton -> DefButton -> DefButton

-- | Like KTapNextPress but with a timeout
KTapHoldNextPress :: Int -> DefButton -> DefButton -> Maybe DefButton -> DefButton

-- | Surround a future button
KAroundNext :: DefButton -> DefButton

-- | Surround a future button
KAroundNextSingle :: DefButton -> DefButton

-- | Do things depending on tap-count
KMultiTap :: [(Int, DefButton)] -> DefButton -> DefButton

-- | Do different things, one-by-one
KStepped :: [DefButton] -> DefButton

-- | Wrap 1 button around another
KAround :: DefButton -> DefButton -> DefButton

-- | Wrap 1 button only around another
KAroundOnly :: DefButton -> DefButton -> DefButton

-- | Wrap 1 button around another when it's "alone"
KAroundWhenAlone :: DefButton -> DefButton -> DefButton

-- | Wrap 1 button around another
KAroundImplicit :: DefButton -> DefButton -> DefButton
KAroundNextTimeout :: Int -> DefButton -> DefButton -> DefButton

-- | Sequence of buttons to tap, possible delay between each press
KTapMacro :: [DefButton] -> Maybe Int -> DefButton

-- | Sequence of buttons to tap, tap last on release, possible delay
--   between each press
KTapMacroRelease :: [DefButton] -> Maybe Int -> DefButton

-- | Compose-key sequence
KComposeSeq :: [DefButton] -> DefButton

-- | Pause for a period of time
KPause :: Milliseconds -> DefButton

-- | Switch to a layer for a period of time
KLayerDelay :: Int -> LayerTag -> DefButton

-- | Perform next button in different layer
KLayerNext :: LayerTag -> DefButton

-- | Execute a shell command on press, as well as possibly on release
KCommand :: Text -> Maybe Text -> DefButton

-- | Act as if a button is pressed for a period of time
KStickyKey :: Int -> DefButton -> DefButton

-- | Surround a future button in a before and after tap
KBeforeAfterNext :: DefButton -> DefButton -> DefButton

-- | Transparent button that does nothing
KTrans :: DefButton

-- | Button that catches event
KBlock :: DefButton

-- | Possible values for implicit around
data ImplArnd
IADisabled :: ImplArnd
IAAround :: ImplArnd
IAAroundOnly :: ImplArnd
IAAroundWhenAlone :: ImplArnd

-- | All possible single settings
data DefSetting
SIToken :: IToken -> DefSetting
SOToken :: OToken -> DefSetting
SCmpSeq :: DefButton -> DefSetting
SFallThrough :: Bool -> DefSetting
SAllowCmd :: Bool -> DefSetting
SCmpSeqDelay :: Int -> DefSetting
SKeySeqDelay :: Int -> DefSetting
SImplArnd :: ImplArnd -> DefSetting

-- | A list of different <a>DefSetting</a> values
type DefSettings = [DefSetting]

-- | A mapping from names to button tokens
type DefAlias = [(Text, DefButton)]
data DefLayerSetting
LSrcName :: Text -> DefLayerSetting
LImplArnd :: ImplArnd -> DefLayerSetting
LButton :: DefButton -> DefLayerSetting

-- | A layer of buttons
data DefLayer
DefLayer :: Text -> [DefLayerSetting] -> DefLayer
[_layerName] :: DefLayer -> Text
[_layerSettings] :: DefLayer -> [DefLayerSetting]

-- | A list of keycodes describing the ordering used by all other layers |
--   which is associated with a name.
data DefSrc
DefSrc :: Maybe Text -> [Keycode] -> DefSrc

-- | A unique name used to refer to this layer.
[_srcName] :: DefSrc -> Maybe Text

-- | Layer settings containing also the buttons.
[_keycodes] :: DefSrc -> [Keycode]

-- | Any statement in a config-file must parse to a <a>KExpr</a>
data KExpr
KDefCfg :: DefSettings -> KExpr
KDefSrc :: DefSrc -> KExpr
KDefLayer :: DefLayer -> KExpr
KDefAlias :: DefAlias -> KExpr

-- | All different input-tokens KMonad can take
data IToken
KDeviceSource :: FilePath -> IToken
KLowLevelHookSource :: IToken
KIOKitSource :: Maybe Text -> IToken

-- | All different output-tokens KMonad can take
data OToken
KUinputSink :: Text -> Maybe Text -> OToken
KSendEventSink :: Maybe (Int, Int) -> OToken
KKextSink :: OToken
class AsKExpr r
_KExpr :: AsKExpr r => Prism' r KExpr
_KDefCfg :: AsKExpr r => Prism' r DefSettings
_KDefSrc :: AsKExpr r => Prism' r DefSrc
_KDefLayer :: AsKExpr r => Prism' r DefLayer
_KDefAlias :: AsKExpr r => Prism' r DefAlias
class AsDefSetting r
_DefSetting :: AsDefSetting r => Prism' r DefSetting
_SIToken :: AsDefSetting r => Prism' r IToken
_SOToken :: AsDefSetting r => Prism' r OToken
_SCmpSeq :: AsDefSetting r => Prism' r DefButton
_SFallThrough :: AsDefSetting r => Prism' r Bool
_SAllowCmd :: AsDefSetting r => Prism' r Bool
_SCmpSeqDelay :: AsDefSetting r => Prism' r Int
_SKeySeqDelay :: AsDefSetting r => Prism' r Int
_SImplArnd :: AsDefSetting r => Prism' r ImplArnd
class HasDefSrc c
defSrc :: HasDefSrc c => Lens' c DefSrc
keycodes :: HasDefSrc c => Lens' c [Keycode]
srcName :: HasDefSrc c => Lens' c (Maybe Text)
class AsDefLayerSetting r
_DefLayerSetting :: AsDefLayerSetting r => Prism' r DefLayerSetting
_LSrcName :: AsDefLayerSetting r => Prism' r Text
_LImplArnd :: AsDefLayerSetting r => Prism' r ImplArnd
_LButton :: AsDefLayerSetting r => Prism' r DefButton
instance KMonad.Args.Types.AsDefLayerSetting KMonad.Args.Types.DefLayerSetting
instance KMonad.Args.Types.AsDefSetting KMonad.Args.Types.DefSetting
instance KMonad.Args.Types.AsKExpr KMonad.Args.Types.KExpr
instance Data.Data.Data KMonad.Args.Types.DefButton
instance GHC.Classes.Eq KMonad.Args.Types.DefButton
instance GHC.Classes.Eq KMonad.Args.Types.DefLayer
instance GHC.Classes.Eq KMonad.Args.Types.DefLayerSetting
instance GHC.Classes.Eq KMonad.Args.Types.DefSetting
instance GHC.Classes.Eq KMonad.Args.Types.DefSrc
instance GHC.Classes.Eq KMonad.Args.Types.ImplArnd
instance GHC.Classes.Eq KMonad.Args.Types.KExpr
instance KMonad.Args.Types.HasCfgToken KMonad.Args.Types.CfgToken
instance KMonad.Args.Types.HasDefSrc KMonad.Args.Types.DefSrc
instance Control.Lens.Plated.Plated KMonad.Args.Types.DefButton
instance GHC.Show.Show KMonad.Args.Types.DefButton
instance GHC.Show.Show KMonad.Args.Types.DefLayer
instance GHC.Show.Show KMonad.Args.Types.DefLayerSetting
instance GHC.Show.Show KMonad.Args.Types.DefSetting
instance GHC.Show.Show KMonad.Args.Types.DefSrc
instance GHC.Show.Show KMonad.Args.Types.IToken
instance GHC.Show.Show KMonad.Args.Types.ImplArnd
instance GHC.Show.Show KMonad.Args.Types.KExpr
instance GHC.Show.Show KMonad.Args.Types.OToken


-- | We perform configuration parsing in 2 steps: - 1. We turn the
--   text-file into a token representation - 2. We check the tokens and
--   turn them into an AppCfg
--   
--   This module covers step 2.
--   
--   NOTE: This is where we make a distinction between operating systems.
module KMonad.Args.Joiner

-- | Turn a list of KExpr into a CfgToken, throwing errors when
--   encountered.
--   
--   NOTE: We start joinConfig with the default JCfg, but joinConfig might
--   locally override settings by things it reads from the config itself.
joinConfigIO :: HasLogFunc e => [KExpr] -> RIO e CfgToken

-- | Update the JCfg and then run the entire joining process
joinConfig :: J CfgToken
instance GHC.Base.Applicative KMonad.Args.Joiner.J
instance GHC.Exception.Type.Exception KMonad.Args.Joiner.JoinError
instance GHC.Base.Functor KMonad.Args.Joiner.J
instance Control.Monad.Error.Class.MonadError KMonad.Args.Joiner.JoinError KMonad.Args.Joiner.J
instance GHC.Base.Monad KMonad.Args.Joiner.J
instance Control.Monad.Reader.Class.MonadReader KMonad.Args.Joiner.JCfg KMonad.Args.Joiner.J
instance GHC.Show.Show KMonad.Args.Joiner.JoinError

module KMonad.App.Types

-- | Record of all the configuration options required to run KMonad's core
--   App loop.
data AppCfg
AppCfg :: Acquire KeySink -> Acquire KeySource -> LMap Button -> LayerTag -> Bool -> Bool -> Milliseconds -> Maybe Milliseconds -> AppCfg

-- | How to open a <a>KeySink</a>
[_keySinkDev] :: AppCfg -> Acquire KeySink

-- | How to open a <a>KeySource</a>
[_keySourceDev] :: AppCfg -> Acquire KeySource

-- | The map defining the <a>Button</a> layout
[_keymapCfg] :: AppCfg -> LMap Button

-- | Active layer when KMonad starts
[_firstLayer] :: AppCfg -> LayerTag

-- | Whether uncaught events should be emitted or not
[_fallThrough] :: AppCfg -> Bool

-- | Whether shell-commands are allowed
[_allowCmd] :: AppCfg -> Bool

-- | How long to wait before acquiring the input keyboard
[_startDelay] :: AppCfg -> Milliseconds

-- | How long to wait after each key event outputted
[_keyOutDelay] :: AppCfg -> Maybe Milliseconds

-- | Environment of a running KMonad app-loop
data AppEnv
AppEnv :: AppCfg -> LogFunc -> KeySink -> KeySource -> Dispatch -> Hooks -> Sluice -> Keymap -> Hooks -> TMVar KeyEvent -> AppEnv
[_keAppCfg] :: AppEnv -> AppCfg
[_keLogFunc] :: AppEnv -> LogFunc
[_keySink] :: AppEnv -> KeySink
[_keySource] :: AppEnv -> KeySource
[_dispatch] :: AppEnv -> Dispatch
[_inHooks] :: AppEnv -> Hooks
[_sluice] :: AppEnv -> Sluice
[_keymap] :: AppEnv -> Keymap
[_outHooks] :: AppEnv -> Hooks
[_outVar] :: AppEnv -> TMVar KeyEvent

-- | The complete environment capable of satisfying <a>MonadK</a>
data KEnv
KEnv :: AppEnv -> BEnv -> KEnv

-- | The app environment containing all the components
[_kAppEnv] :: KEnv -> AppEnv

-- | The environment describing the currently active button
[_kBEnv] :: KEnv -> BEnv
class HasAppCfg c
appCfg :: HasAppCfg c => Lens' c AppCfg
allowCmd :: HasAppCfg c => Lens' c Bool
fallThrough :: HasAppCfg c => Lens' c Bool
firstLayer :: HasAppCfg c => Lens' c LayerTag
keyOutDelay :: HasAppCfg c => Lens' c (Maybe Milliseconds)
keySinkDev :: HasAppCfg c => Lens' c (Acquire KeySink)
keySourceDev :: HasAppCfg c => Lens' c (Acquire KeySource)
keymapCfg :: HasAppCfg c => Lens' c (LMap Button)
startDelay :: HasAppCfg c => Lens' c Milliseconds
class HasAppEnv c
appEnv :: HasAppEnv c => Lens' c AppEnv
dispatch :: HasAppEnv c => Lens' c Dispatch
inHooks :: HasAppEnv c => Lens' c Hooks
keAppCfg :: HasAppEnv c => Lens' c AppCfg
keLogFunc :: HasAppEnv c => Lens' c LogFunc
keySink :: HasAppEnv c => Lens' c KeySink
keySource :: HasAppEnv c => Lens' c KeySource
keymap :: HasAppEnv c => Lens' c Keymap
outHooks :: HasAppEnv c => Lens' c Hooks
outVar :: HasAppEnv c => Lens' c (TMVar KeyEvent)
sluice :: HasAppEnv c => Lens' c Sluice
class HasKEnv c
kEnv :: HasKEnv c => Lens' c KEnv
kAppEnv :: HasKEnv c => Lens' c AppEnv
kBEnv :: HasKEnv c => Lens' c BEnv
instance KMonad.App.Types.HasAppCfg KMonad.App.Types.AppCfg
instance KMonad.App.Types.HasAppCfg KMonad.App.Types.AppEnv
instance KMonad.App.Types.HasAppCfg KMonad.App.Types.KEnv
instance KMonad.App.Types.HasAppEnv KMonad.App.Types.AppEnv
instance KMonad.App.Types.HasAppEnv KMonad.App.Types.KEnv
instance KMonad.Model.BEnv.HasBEnv KMonad.App.Types.KEnv
instance KMonad.App.Types.HasKEnv KMonad.App.Types.KEnv
instance RIO.Prelude.Logger.HasLogFunc KMonad.App.Types.AppEnv
instance RIO.Prelude.Logger.HasLogFunc KMonad.App.Types.KEnv
instance (KMonad.App.Types.HasAppEnv e, KMonad.App.Types.HasAppCfg e, RIO.Prelude.Logger.HasLogFunc e) => KMonad.Model.Action.MonadKIO (RIO.Prelude.RIO.RIO e)
instance KMonad.Model.Action.MonadK (RIO.Prelude.RIO.RIO KMonad.App.Types.KEnv)


-- | We perform configuration parsing in 2 steps: - 1. We turn the
--   text-file into a token representation - 2. We check the tokens and
--   turn them into an AppCfg
--   
--   This module covers step 1.
module KMonad.Args.Parser

-- | Try to parse a list of <a>KExpr</a> from <a>Text</a>
parseTokens :: Text -> Either ParseError [KExpr]

-- | Load a set of tokens from file, throw an error on parse-fail
loadTokens :: FilePath -> RIO e [KExpr]

-- | Consume 1 symbol
symbol :: Text -> Parser ()

-- | Parse an integer
numP :: Parser Int

-- | Output tokens to parse; the format is <tt>(keyword, how to parse the
--   token)</tt>
otokens :: [(Text, Parser OToken)]

-- | Input tokens to parse; the format is <tt>(keyword, how to parse the
--   token)</tt>
itokens :: [(Text, Parser IToken)]

-- | Parse any button
buttonP :: Parser DefButton
implArndButtons :: [(Text, ImplArnd, DefButton -> DefButton -> DefButton)]

-- | Parsers for buttons that have a keyword at the start; the format is
--   <tt>(keyword, how to parse the token)</tt>
keywordButtons :: [(Text, Parser DefButton)]

-- | Parsers for buttons that do <b>not</b> have a keyword at the start
noKeywordButtons :: [Parser DefButton]

module Paths_kmonad
version :: Version
getBinDir :: IO FilePath
getLibDir :: IO FilePath
getDynLibDir :: IO FilePath
getDataDir :: IO FilePath
getLibexecDir :: IO FilePath
getDataFileName :: FilePath -> IO FilePath
getSysconfDir :: IO FilePath


module KMonad.Args.Cmd

-- | Record describing the instruction to KMonad
data Cmd
Cmd :: FilePath -> Bool -> LogLevel -> Milliseconds -> DefSetting -> DefSetting -> Maybe DefSetting -> Maybe DefSetting -> Maybe DefSetting -> Maybe DefSetting -> Maybe DefSetting -> Maybe DefSetting -> Cmd

-- | Which file to read the config from
[_cfgFile] :: Cmd -> FilePath

-- | Flag to indicate we are only test-parsing
[_dryRun] :: Cmd -> Bool

-- | Level of logging to use
[_logLvl] :: Cmd -> LogLevel

-- | How long to wait before acquiring the input keyboard
[_strtDel] :: Cmd -> Milliseconds

-- | Allow execution of arbitrary shell-commands?
[_cmdAllow] :: Cmd -> DefSetting

-- | Re-emit unhandled events?
[_fallThrgh] :: Cmd -> DefSetting

-- | Key to use for compose-key sequences
[_cmpSeq] :: Cmd -> Maybe DefSetting

-- | Specify compose sequence key delays
[_cmpSeqDelay] :: Cmd -> Maybe DefSetting

-- | Specify key event output delays
[_keySeqDelay] :: Cmd -> Maybe DefSetting

-- | How to handle implicit <tt>around</tt>s
[_implArnd] :: Cmd -> Maybe DefSetting

-- | How to emit the output
[_oToken] :: Cmd -> Maybe DefSetting

-- | How to capture the input
[_iToken] :: Cmd -> Maybe DefSetting
class HasCmd c
cmd :: HasCmd c => Lens' c Cmd
cfgFile :: HasCmd c => Lens' c FilePath
cmdAllow :: HasCmd c => Lens' c DefSetting
cmpSeq :: HasCmd c => Lens' c (Maybe DefSetting)
cmpSeqDelay :: HasCmd c => Lens' c (Maybe DefSetting)
dryRun :: HasCmd c => Lens' c Bool
fallThrgh :: HasCmd c => Lens' c DefSetting
iToken :: HasCmd c => Lens' c (Maybe DefSetting)
implArnd :: HasCmd c => Lens' c (Maybe DefSetting)
keySeqDelay :: HasCmd c => Lens' c (Maybe DefSetting)
logLvl :: HasCmd c => Lens' c LogLevel
oToken :: HasCmd c => Lens' c (Maybe DefSetting)
strtDel :: HasCmd c => Lens' c Milliseconds

-- | Parse <a>Cmd</a> from the evocation of this program
getCmd :: IO Cmd
instance KMonad.Args.Cmd.HasCmd KMonad.Args.Cmd.Cmd
instance GHC.Show.Show KMonad.Args.Cmd.Cmd


module KMonad.Args

-- | Parse <a>Cmd</a> from the evocation of this program
getCmd :: IO Cmd

-- | Parse a configuration file into a <a>AppCfg</a> record
loadConfig :: HasLogFunc e => Cmd -> RIO e AppCfg

-- | Record describing the instruction to KMonad
data Cmd
class HasCmd c
cmd :: HasCmd c => Lens' c Cmd
cfgFile :: HasCmd c => Lens' c FilePath
cmdAllow :: HasCmd c => Lens' c DefSetting
cmpSeq :: HasCmd c => Lens' c (Maybe DefSetting)
cmpSeqDelay :: HasCmd c => Lens' c (Maybe DefSetting)
dryRun :: HasCmd c => Lens' c Bool
fallThrgh :: HasCmd c => Lens' c DefSetting
iToken :: HasCmd c => Lens' c (Maybe DefSetting)
implArnd :: HasCmd c => Lens' c (Maybe DefSetting)
keySeqDelay :: HasCmd c => Lens' c (Maybe DefSetting)
logLvl :: HasCmd c => Lens' c LogLevel
oToken :: HasCmd c => Lens' c (Maybe DefSetting)
strtDel :: HasCmd c => Lens' c Milliseconds


module KMonad.App.Main

-- | The first command in KMonad
--   
--   Get the invocation from the command-line, then do something with it.
main :: IO ()


module KMonad.App

-- | The first command in KMonad
--   
--   Get the invocation from the command-line, then do something with it.
main :: IO ()
