bluefin-internal-0.0.8.0: The Bluefin effect system, internals
Safe HaskellSafe-Inferred
LanguageHaskell2010

Bluefin.Internal.Pipes

Synopsis

Documentation

data Proxy a' a b' b e Source #

Constructors

MkProxy (Coroutine a' a e) (Coroutine b b' e) 

type Pipe a = Proxy () a () Source #

type Producer = Proxy Void () () Source #

(>->) infixl 7 Source #

Arguments

:: e1 :> es 
=> (forall e. Proxy a' a () b e -> Eff (e :& es) r) 
-> (forall e. Proxy () b c' c e -> Eff (e :& es) r) 
-> Proxy a' a c' c e1 
-> Eff es r

͘

(<-<) infixr 7 Source #

Arguments

:: e1 :> es 
=> (forall e. Proxy () b c' c e -> Eff (e :& es) r) 
-> (forall e. Proxy a' a () b e -> Eff (e :& es) r) 
-> Proxy a' a c' c e1 
-> Eff es r

͘

for Source #

Arguments

:: e1 :> es 
=> (forall e. Proxy x' x b' b e -> Eff (e :& es) a') 
-> (b -> forall e. Proxy x' x c' c e -> Eff (e :& es) b') 
-> Proxy x' x c' c e1 
-> Eff es a'

͘

(~>) infixr 4 Source #

Arguments

:: e1 :> es 
=> (a -> forall e. Proxy x' x b' b e -> Eff (e :& es) a') 
-> (b -> forall e. Proxy x' x c' c e -> Eff (e :& es) b') 
-> a 
-> Proxy x' x c' c e1 
-> Eff es a'

͘

(<~) infixl 4 Source #

Arguments

:: e1 :> es 
=> (b -> forall e. Proxy x' x c' c e -> Eff (e :& es) b') 
-> (a -> forall e. Proxy x' x b' b e -> Eff (e :& es) a') 
-> a 
-> Proxy x' x c' c e1 
-> Eff es a'

͘

reverseProxy :: Proxy a' a b' b e -> Proxy b b' a a' e Source #

(>~) infixl 5 Source #

Arguments

:: e1 :> es 
=> (forall e. Proxy a' a y' y e -> Eff (e :& es) b) 
-> (forall e. Proxy () b y' y e -> Eff (e :& es) c) 
-> Proxy a' a y' y e1 
-> Eff es c

͘

(~<) infixr 5 Source #

Arguments

:: e1 :> es 
=> (forall e. Proxy () b y' y e -> Eff (e :& es) c) 
-> (forall e. Proxy a' a y' y e -> Eff (e :& es) b) 
-> Proxy a' a y' y e1 
-> Eff es c

͘

cat :: Pipe a a e -> Eff (e :& es) r Source #

runEffect Source #

Arguments

:: (forall e. Effect e -> Eff (e :& es) r) 
-> Eff es r

͘

yield Source #

Arguments

:: e :> es 
=> Proxy x1 x () a e 
-> a 
-> Eff es ()

͘

await :: e :> es => Proxy () a y' y e -> Eff es a Source #

next :: () Source #

pipe's next doesn't exist in Bluefin

each Source #

Arguments

:: Foldable f 
=> f a 
-> Proxy x' x () a e 
-> Eff (e :& es) ()

͘

repeatM Source #

Arguments

:: e :> es 
=> Eff es a 
-> Proxy x' x () a e 
-> Eff es r

͘

replicateM Source #

Arguments

:: e :> es 
=> Int 
-> Eff es a 
-> Proxy x' x () a e 
-> Eff es ()

͘

print Source #

Arguments

:: (e2 :> es, e1 :> es, Show a) 
=> IOE e1 
-> Consumer a e2 
-> Eff es r

͘

unfoldr Source #

Arguments

:: e :> es 
=> (s -> Eff es (Either r (a, s))) 
-> s 
-> Proxy x1 x () a e 
-> Eff es r

͘

mapM_ Source #

Arguments

:: e :> es 
=> (a -> Eff es ()) 
-> Proxy () a b b' e 
-> Eff es r

͘

drain Source #

Arguments

:: e :> es 
=> Proxy () b c' c e 
-> Eff es r

͘

map Source #

Arguments

:: e :> es 
=> (a -> b) 
-> Pipe a b e 
-> Eff es r

͘

mapM Source #

Arguments

:: e :> es 
=> (a -> Eff es b) 
-> Pipe a b e 
-> Eff es r

͘

takeWhile' Source #

Arguments

:: e :> es 
=> (r -> Bool) 
-> Pipe r r e 
-> Eff es r

͘

stdinLn Source #

Arguments

:: (e1 :> es, e2 :> es) 
=> IOE e1 
-> Producer String e2 
-> Eff es r

͘

stdoutLn Source #

Arguments

:: (e1 :> es, e2 :> es) 
=> IOE e1 
-> Consumer String e2 
-> Eff es r

͘