Hello,

  My question/wish is maybe naive, but anyway:
Is there a library (not a language extension, like
Concurrent Haskell, Glasgow Parallel Haskell, ...) enabling
to run two functions in parallel, possibly in cascade?

Something like:

>  testAll (threadStart f1 (threadStart f2 f3))
>
> where threadStart :: a -> b -> (WillBe a, WillBe b)
> where type WillBe is something like Maybe, but
> changing within a time (mutable values) ~ Processing, Just a, Nothing
>
> testAll (Nothing,p) = putStr "No result for f1" >> testPair p
> testAll (l,(Nothing,r)) = putStr "Noresult for f2" >> testPair (l,r)
> testAll (l,(ll,Nothing)) = putStr "No result for f3" >> testPair (l,ll)
> testAll (Just a,p) = putStr ("res of f1: " ++ show a) >> testPair p
> ...
>
> testPair ~ about the same like testAll

Probably the explanation is not too clear and what I wish
is out of the language scope (not really functional), but
I would appreciate something like that. Is there something
like that for Haskell/Hugs?

 Thx for any ref.

    Dusan

_______________________________________________
Haskell-Cafe mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/haskell-cafe

Reply via email to