Skip to content

Commit

Permalink
runBluefin and runPureBluefin
Browse files Browse the repository at this point in the history
  • Loading branch information
tomjaguarpaw committed Sep 8, 2024
1 parent f0fec4e commit 97cd74b
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions bluefin-internal/src/Bluefin/Internal/Effectful.hs
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,17 @@ runPureEffectful ::
Eff es r
runPureEffectful k = pure (Effectful.runPureEff (unsafeToEffectful k))

runBluefin ::
Effectful.IOE Effectful.:> effes =>
(forall e es. IOE e -> Effectful.Eff (Bluefin (e :& es) : effes) r) ->
Effectful.Eff effes r
runBluefin m = unsafeInterpretBluefin (m MkIOE)

runPureBluefin ::
(forall es. Effectful.Eff (Bluefin es : effes) r) ->
Effectful.Eff effes r
runPureBluefin = unsafeInterpretBluefin

example ::
( St.State Int Effectful.:> es,
Er.Error String Effectful.:> es,
Expand Down

0 comments on commit 97cd74b

Please sign in to comment.