summaryrefslogtreecommitdiff
path: root/srfi
diff options
context:
space:
mode:
authorLudovic Courtès <ludo@gnu.org>2015-01-17 18:46:41 +0100
committerLudovic Courtès <ludo@gnu.org>2015-01-17 23:45:48 +0100
commit81a97734e04fa40412b2d44ccfae1b4796257648 (patch)
treedbb6513d891d778c41abe564891466c564721339 /srfi
parent5db3719153ccabd192eadaf99b14ad1149172c5b (diff)
monads: Add the state monad.
* guix/monads.scm (state-return, state-bind, run-with-state, current-state, set-current-state, state-push, state-pop): New procedures. (%state-monad): New variable. * tests/monads.scm (%monads): Add %STATE-MONAD. (%monad-run): Add 'run-with-state'. (values->list): New macro. ("set-current-state", "state-push etc."): New tests.
Diffstat (limited to 'srfi')
0 files changed, 0 insertions, 0 deletions