The kind of effects.
Moduleeffectful-core-2.3.0.1Haskell2010
Effectful.Internal.Effect
Type-safe indexing for Effectful.Internal.Monad.Env.
This module is intended for internal use only, and may change without warning in subsequent releases.
- 2 types
- 4 classes
- Packageeffectful-core-2.3.0.1
- Exports7
- LanguageHaskell2010
- LicenceBSD-3-Clause
- SourceEffect.hs
A constraint that requires that a particular effect e is a member of the
type-level list es. This is used to parameterize an Eff
computation over an arbitrary list of effects, so long as e is somewhere
in the list.
For example, a computation that only needs access to a mutable value of type Integer would have the following type:
State Integer :> es => Eff es ()
Methods
reifyIndex :: IntGet the position of
eines.Note: GHC is kind enough to cache these values as they're top level CAFs, so the lookup is amortized
O(1)without any language level tricks.
Instances3:>
TypeError (('TextDefined in effectful-core-2.3.0.1 · Effectful.Internal.Effect"There is no handler for '"
':<>: 'ShowType e) ':<>: 'Text"' in the context"
) => e :> '[]e :> (e ': es)Defined in effectful-core-2.3.0.1 · Effectful.Internal.Effecte :> es => e :> (x ': es)Defined in effectful-core-2.3.0.1 · Effectful.Internal.Effect
Deprecated. Usage of (:>>) slows down GHC too much, so it will be removed in 3.0.0.0. See https://github.com/haskell-effectful/effectful/issues/52#issuecomment-1269155485 for more information.
Provide evidence that xs is a subset of es.
Methods
subsetFullyKnown :: BoolreifyIndices :: [Int]
Instances3Subset
(KnownPrefix es, IsUnknownSuffixOf xs es) => Subset xs esDefined in effectful-core-2.3.0.1 · Effectful.Internal.EffectKnownPrefix es => Subset '[] esDefined in effectful-core-2.3.0.1 · Effectful.Internal.Effect(e :> es, Subset xs es) => Subset (e ': xs) esDefined in effectful-core-2.3.0.1 · Effectful.Internal.Effect
Calculate length of a statically known prefix of es.
Methods
prefixLength :: Int
Instances2KnownPrefix
KnownPrefix esDefined in effectful-core-2.3.0.1 · Effectful.Internal.EffectKnownPrefix es => KnownPrefix (e ': es)Defined in effectful-core-2.3.0.1 · Effectful.Internal.Effect
Require that xs is the unknown suffix of es.
Instances2IsUnknownSuffixOf
xs ~ es => IsUnknownSuffixOf xs esDefined in effectful-core-2.3.0.1 · Effectful.Internal.EffectIsUnknownSuffixOf xs es => IsUnknownSuffixOf xs (e ': es)Defined in effectful-core-2.3.0.1 · Effectful.Internal.Effect
Re-exports
1 declarationThe kind of types with lifted values. For example Int :: Type.