mirror of
https://github.com/graninas/Hydra.git
synced 2024-11-28 04:35:18 +03:00
939 B
939 B
- Effects list vs type class hierarchy
meteorShower
:: (L.ControlFlowL m, L.RandomL m, L.LoggerL m)
=> AppState -> Region -> m ()
class (L.ControlFlowL m, L.RandomL m, L.LoggerL m) => LangL m
- Impossible embedded hierarchy
- Problems with StateL, ProcessL
- Too much freedom
-- Impossible to say it should not do anything but state.
initState :: L.StateL m => m AppState
initState = ...
-- Someone can fix it:
initState :: (L.LoggerL m, L.StateL m) => m AppState
initState = ...
-
Hierarchy of runtimes breaks
-
Single runtime
FT obligates to have a single runtime per application (only a single monad stack, only a single runtime structure). It makes the app hard coupled
- Endless type checking battles
Could not deduce (Hydra.Core.Evaluable.Evaluable m'0)
Could not deduce (L.LangL m'0)
arising from a use of ‘meteorCounter’
from the context: (L.ProcessL m, L.LangL m)