regions-0.11: Provides the region monad for safely opening and working with scarce resources.

MaintainerBas van Dijk <>






Local regions

unsafeStripLocal :: RegionT (Local s) pr α -> RegionT s pr αSource

Convert a Local region to a regular region.

This function is unsafe because it allows you to use a LocalRegion-tagged handle outside its Local region.

MonadTransControl & MonadControlIO

unsafeLiftControl :: Monad pr => (Run (RegionT s) -> pr α) -> RegionT s pr αSource

unsafeControlIO :: RegionControlIO m => (RunInBase m IO -> IO (m α)) -> m αSource

unsafeLiftIOOp :: RegionControlIO m => ((α -> IO (m β)) -> IO (m γ)) -> (α -> m β) -> m γSource

unsafeLiftIOOp_ :: RegionControlIO m => (IO (m α) -> IO (m β)) -> m α -> m βSource