diff options
Diffstat (limited to 'stdlib/source/documentation/lux/control/concurrency/stm.lux')
-rw-r--r-- | stdlib/source/documentation/lux/control/concurrency/stm.lux | 69 |
1 files changed, 35 insertions, 34 deletions
diff --git a/stdlib/source/documentation/lux/control/concurrency/stm.lux b/stdlib/source/documentation/lux/control/concurrency/stm.lux index fb4438584..afa5e4744 100644 --- a/stdlib/source/documentation/lux/control/concurrency/stm.lux +++ b/stdlib/source/documentation/lux/control/concurrency/stm.lux @@ -1,6 +1,6 @@ (.require [library - [lux (.except if loop) + [lux (.except) ["$" documentation] [data [text (.only \n) @@ -9,36 +9,37 @@ ["[0]" /]]) (.def .public documentation - (.List $.Module) - ($.module /._ - "" - [($.definition /.read) - ($.definition /.write) - ($.definition /.functor) - ($.definition /.apply) - ($.definition /.monad) - - ($.definition (/.Var it) - "A mutable cell containing a value, and observers that will be alerted of any change to it.") - - ($.definition /.var - "Creates a new STM var, with a default value." - [(var value)]) - - ($.definition /.changes - "Creates a channel that will receive all changes to the value of the given var." - [(changes target)]) - - ($.definition (/.STM it) - "A computation which updates a transaction and produces a value.") - - ($.definition /.update - "Update a var's value, and return a tuple with the old and the new values." - [(update function var)]) - - ($.definition /.commit! - (format "Commits a transaction and returns its result (asynchronously)." - \n "Note that a transaction may be re-run an indeterminate number of times if other transactions involving the same variables successfully commit first." - \n "For this reason, it's important to note that transactions must be free from side-effects, such as I/O.") - [(commit! procedure)])] - [])) + (.List $.Documentation) + (list ($.module /._ + "") + + ($.definition /.read) + ($.definition /.write) + ($.definition /.functor) + ($.definition /.apply) + ($.definition /.monad) + + ($.definition (/.Var it) + "A mutable cell containing a value, and observers that will be alerted of any change to it.") + + ($.definition /.var + "Creates a new STM var, with a default value." + [(var value)]) + + ($.definition /.changes + "Creates a channel that will receive all changes to the value of the given var." + [(changes target)]) + + ($.definition (/.STM it) + "A computation which updates a transaction and produces a value.") + + ($.definition /.update + "Update a var's value, and return a tuple with the old and the new values." + [(update function var)]) + + ($.definition /.commit! + (format "Commits a transaction and returns its result (asynchronously)." + \n "Note that a transaction may be re-run an indeterminate number of times if other transactions involving the same variables successfully commit first." + \n "For this reason, it's important to note that transactions must be free from side-effects, such as I/O.") + [(commit! procedure)]) + )) |