summaryrefslogtreecommitdiff
path: root/docs/embedding.rst
diff options
context:
space:
mode:
authorOwen Jacobson <owen@grimoire.ca>2017-12-06 04:21:29 -0500
committerOwen Jacobson <owen@grimoire.ca>2017-12-06 04:21:29 -0500
commite05abf6e117be08dc33c7664b3d823c08887de1e (patch)
tree9b1f85d69450fb3a995883d70c7e8f2c77bda4ea /docs/embedding.rst
parentf1b953de65ec060af50b35b553ff80e7fd5ceeda (diff)
Massively expanded the reference section.
Diffstat (limited to 'docs/embedding.rst')
-rw-r--r--docs/embedding.rst9
1 files changed, 7 insertions, 2 deletions
diff --git a/docs/embedding.rst b/docs/embedding.rst
index f07b0f6..d179baf 100644
--- a/docs/embedding.rst
+++ b/docs/embedding.rst
@@ -78,8 +78,8 @@ will automatically determine the name to bind to:
session.bind_fn(example)
print(*session.run('(example)')) # prints "5"
-Finally, to bind a function returning a tuple of results, call
-``bind_builtin``. This will automatically determine the name to bind to:
+To bind a function returning a tuple of results, call ``bind_builtin``. This
+will automatically determine the name to bind to:
.. code-block:: python
@@ -128,6 +128,11 @@ The symbol must be bound to an instance of the ``Registry`` class from the
def two_values():
return 1, "Two"
+ An.eval('''
+ (begin
+ (define (three-values) (values 1 2 3)))
+ ''')
+
# @An.macro_bind, @An.macro_void, @An.macro_fn, and @An.macro_builtin follow
# the same pattern.