z0w0/helm

RFC: Revamp or remove FRP.Helm.Automaton

z0w0 opened this issue · 3 comments

z0w0 commented

Elm recently completely revamped their automaton module in favor of a more consistent design around arrowized FRP. I haven't actually seen automatons get used for stuff (although they are actually useful, just you don't necessarily need them because it's quite easy to map from signal to signal). I think we should just remove it. Thoughts?

The point of automotons are for a signal to have state. I'm not sure that removing it completely is beneficial.
https://github.com/evancz/Elm/blob/master/libraries/Automaton.elm
data Automaton a b = Step (a -> (Automaton a b, b))

I say keep them.

Well, you pretty much end up working with signal generators when using Elerea, which are stateful. So I can't see any point keeping them. Unless of course I've missunderstood something.

z0w0 commented

FYI I already removed it on master, but I'll keep this open for suggestions of alternatives. Helm's automaton API was designed directly after the original Elm automaton API and they revamped it for a reason. Seeing as we're working in the Haskell, I feel like there might be a nicer way to do stateful and composable signals based on some already existing library. And @klrr, that is correct. There are benefits to having an arrowized form of signals, though.