1
1
mirror of https://github.com/github/semantic.git synced 2024-12-24 07:25:44 +03:00
This commit is contained in:
Patrick Thomson 2018-10-16 17:18:59 -04:00
parent 37522ddc35
commit fb1806f3e9

View File

@ -30,6 +30,7 @@ runResource :: (Member (Lift IO) effects, PureEffects effects)
-> Eff (Resource ': effects) a
-> Eff effects a
runResource handler = interpret (\(Resource fore aft go)
-> liftIO (Exc.bracket (handler (runResource handler fore))
-> liftIO (Exc.bracket
(handler (runResource handler fore))
(handler . runResource handler . aft)
(handler . runResource handler . go)
(handler . runResource handler . go)))