Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix outdated documentation for wrappedWithRunInIO #72

Merged
merged 2 commits into from
Apr 22, 2021
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion unliftio-core/src/Control/Monad/IO/Unlift.hs
Original file line number Diff line number Diff line change
Expand Up @@ -131,12 +131,13 @@ underlying transformer.

> newtype AppT m a = AppT { unAppT :: ReaderT Int (ResourceT m) a }
> deriving (Functor, Applicative, Monad, MonadIO)
> -- Unfortunately, deriving MonadUnliftIO does not work.
>
> -- Same as `deriving newtype (MonadUnliftIO)`
> instance MonadUnliftIO m => MonadUnliftIO (AppT m) where
> withRunInIO = wrappedWithRunInIO AppT unAppT
-}
{-# INLINE wrappedWithRunInIO #-}
{-# DEPRECATED wrappedWithRunInIO "You can derive MonadUnliftIO for newtypes in unliftio-core 0.2.0.0 and later" #-}
evanrelf marked this conversation as resolved.
Show resolved Hide resolved
wrappedWithRunInIO :: MonadUnliftIO n
=> (n b -> m b)
-- ^ The wrapper, for instance @IdentityT@.
Expand Down