Haskell - Is effect order deterministic in case of Applicative?

后端 未结 3 1705
耶瑟儿~
耶瑟儿~ 2021-01-01 21:03

When executing the IO action defined by someFun <$> (a :: IO ()) <$> (b :: IO ()), is the execution of the a and b actions

3条回答
  •  自闭症患者
    2021-01-01 21:38

    For the IO Applicative, this is certainly the case. But check out the async package for an example of an Applicative where in f <$> a <*> b the effects of a and b happen in parallel.

提交回复
热议问题