Verified Commit 27f5acc9 authored by Justin Andresen's avatar Justin Andresen
Browse files

Rename `printLog` to `printMyLog`

parent c450b7e9
......@@ -40,6 +40,6 @@ logMyState = interpose @(MyState s) \case
myLog s'
myPut s'
printLog :: LastMember IO effs => Eff (MyLog ': effs) a -> Eff effs a
printLog = interpretM \case
printMyLog :: LastMember IO effs => Eff (MyLog ': effs) a -> Eff effs a
printMyLog = interpretM \case
MyLog msg -> putStrLn ("Info: " ++ show msg)
......@@ -35,4 +35,4 @@ runMyProg = run . runMyState myInitialState $ myProg
logMyProg :: IO (Bool, Int)
logMyProg =
runM . printLog . runMyState myInitialState . logMyState @Int $ myProg
runM . printMyLog . runMyState myInitialState . logMyState @Int $ myProg
......@@ -36,6 +36,6 @@ logMyState = intercept \case
myLog s'
myPut s'
printLog :: Member (Embed IO) r => Sem (MyLog ': r) a -> Sem r a
printLog = interpret \case
printMyLog :: Member (Embed IO) r => Sem (MyLog ': r) a -> Sem r a
printMyLog = interpret \case
MyLog msg -> embed $ putStrLn ("Info: " ++ show msg)
......@@ -27,4 +27,4 @@ runMyProg :: (Int, Bool)
runMyProg = run . runMyState myInitialState $ myProg
logMyProg :: IO (Int, Bool)
logMyProg = runM . printLog . runMyState myInitialState . logMyState $ myProg
logMyProg = runM . printMyLog . runMyState myInitialState . logMyState $ myProg
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment