Hacker News new | ask | show | jobs
by EvilTerran 5064 days ago
Well, the past doesn't necessarily have to wait for the value from the future to arrive, thanks to lazy evaluation. But yes, you've got the basic gist of it.

State and Reverse State are both about having a single conceptually-mutable "cell" (although that can, of course, be a complex value like a mapping or whatever), written with "put" and read with "get" -- take a minimal example:

  do put "Past"
     x <- get
     put "Future"
     return x
In State, that would result in "Past"; in Reverse State, it would result in "Future".

The blog posts linked at the bottom of the readme may help make things clearer.