You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
And here is the confusing moment Toy.program.(nil) returns %Algae.Free.Pure{pure: %Toy.Bell{next: %Algae.Free.Pure{pure: nil}}} instead of %Toy.Output{next: %Algae.Free.Pure{pure: %Toy.Bell{next: %Algae.Free.Pure{pure: nil}}}, output: 1}. It basically does not 'concatenate' previous value with the next one
Thanks in advance for your help!
The text was updated successfully, but these errors were encountered:
Im not sure if issues is a correct place to request help, however I'm trying to understand
Algae.Free
and it isn't as easy as it might beThere is link to an article on free monads in docs
I tried to implement Haskell code in Elixir, and here's what I've got:
And here is the confusing moment
Toy.program.(nil)
returns%Algae.Free.Pure{pure: %Toy.Bell{next: %Algae.Free.Pure{pure: nil}}}
instead of%Toy.Output{next: %Algae.Free.Pure{pure: %Toy.Bell{next: %Algae.Free.Pure{pure: nil}}}, output: 1}
. It basically does not 'concatenate' previous value with the next oneThanks in advance for your help!
The text was updated successfully, but these errors were encountered: