| Safe Haskell | Safe-Inferred |
|---|---|
| Language | GHC2021 |
Randomization
Synopsis
- newtype Randomization m = Randomization {
- getRandomBytes :: Natural -> m ByteString
- deterministicallyRandom :: DeterministicRandomization -> IO (Randomization IO)
- newtype DeterministicRandomization = DeterministicRandomization {}
- hoistRandomization :: (forall a. m a -> m' a) -> Randomization m -> Randomization m'
- defaultRandomization :: IO (Randomization IO)
Documentation
newtype Randomization m Source #
General means of obtaining randomness
Constructors
| Randomization | |
Fields
| |
deterministicallyRandom :: DeterministicRandomization -> IO (Randomization IO) Source #
Convert from a deterministic generator to an effectful one
newtype DeterministicRandomization Source #
A deterministic random generator
Constructors
| DeterministicRandomization | |
Fields
| |
hoistRandomization :: (forall a. m a -> m' a) -> Randomization m -> Randomization m' Source #
defaultRandomization :: IO (Randomization IO) Source #
Cryptographically secure deterministic randomization seeded from
system entropy using ChaChaDRG from the crypton package