I think that allowing the user to wrap an IO action in EIO can lead to confusing type errors. I propose that we instead introduce some functions such as these:
unsafeLiftIO :: IO a -> EIO '[] a
unsafeLiftIO = EIO
tryLiftIO :: (Exception e) => IO a -> EIO '[] (Either e a)
tryLiftIO = EIO . try
I think that allowing the user to wrap an IO action in
EIO
can lead to confusing type errors. I propose that we instead introduce some functions such as these: