aboutsummaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
authorLudovic Courtès <ludo@gnu.org>2014-10-08 23:35:08 +0200
committerLudovic Courtès <ludo@gnu.org>2014-10-08 23:35:20 +0200
commit405a9d4ec9806993a6453f0dfba78fc65d5e7993 (patch)
tree83096b186be61f0a0daca3b808ab2aeb58bfb352 /doc
parent2e1bafb03438757c7cc34c16230b00623507ff84 (diff)
downloadpatches-405a9d4ec9806993a6453f0dfba78fc65d5e7993.tar
patches-405a9d4ec9806993a6453f0dfba78fc65d5e7993.tar.gz
monads: Add 'mbegin'.
* guix/monads.scm (mbegin): New macro. * tests/monads.scm ("mbegin"): New test. * doc/guix.texi (The Store Monad): Document it.
Diffstat (limited to 'doc')
-rw-r--r--doc/guix.texi9
1 files changed, 9 insertions, 0 deletions
diff --git a/doc/guix.texi b/doc/guix.texi
index ed2b81ba33..c9760f5f60 100644
--- a/doc/guix.texi
+++ b/doc/guix.texi
@@ -2061,6 +2061,15 @@ Bind the variables @var{var} to the monadic values @var{mval} in
(@pxref{Local Bindings,,, guile, GNU Guile Reference Manual}).
@end deffn
+@deffn {Scheme System} mbegin @var{monad} @var{mexp} ...
+Bind @var{mexp} and the following monadic expressions in sequence,
+returning the result of the last expression.
+
+This is akin to @code{mlet}, except that the return values of the
+monadic expressions are ignored. In that sense, it is analogous to
+@code{begin}, but applied to monadic expressions.
+@end deffn
+
The interface to the store monad provided by @code{(guix monads)} is as
follows.