summaryrefslogtreecommitdiffstats
path: root/txr.1
diff options
context:
space:
mode:
authorKaz Kylheku <kaz@kylheku.com>2017-07-31 05:44:39 -0700
committerKaz Kylheku <kaz@kylheku.com>2017-07-31 05:44:39 -0700
commit7d2dfcb941a4954948bd99808676eae3456191c0 (patch)
tree00d8a8bc89c234efd942e73d91545ed6bc48e1ff /txr.1
parentae6c40f3d231b9573a256693f354289c8900c25b (diff)
downloadtxr-7d2dfcb941a4954948bd99808676eae3456191c0.tar.gz
txr-7d2dfcb941a4954948bd99808676eae3456191c0.tar.bz2
txr-7d2dfcb941a4954948bd99808676eae3456191c0.zip
Evaluate doloop forms in an implicit tagbody.
This eliminates one incompatibility between doloop and ANSI CL do. * share/txr/stdlib/doloop.tl (sys:expand-doloop): Wrap body in tagbody form. * txr.1: Documentation updated.
Diffstat (limited to 'txr.1')
-rw-r--r--txr.132
1 files changed, 21 insertions, 11 deletions
diff --git a/txr.1 b/txr.1
index 9e8d25f4..b9a12800 100644
--- a/txr.1
+++ b/txr.1
@@ -15370,7 +15370,7 @@ operator to be used to terminate at any point.
.mets ({doloop | doloop*}
.mets \ \ ({ sym | >> ( sym >> [ init-form <> [ step-form ])}*)
.mets \ \ >> ([ test-form << result-form *])
-.mets \ \ << body-form *)
+.mets \ \ << tagbody-form *)
.syne
.desc
The
@@ -15388,6 +15388,19 @@ Each
element in the form must be a symbol suitable for use as a variable name.
The
+.metn tagbody-form -s
+are placed into an implicit
+.codn tagbody ,
+meaning that a
+.meta tagbody-form
+which is an integer, character or symbol is interpreted
+as a
+.code tagbody
+label which may be the target of a control transfer via the
+.code go
+macro.
+
+The
.code doloop
macro binds each
.meta sym
@@ -15416,10 +15429,13 @@ If
.meta test-form
produces a true value, then
.metn result-form -s
-are not evaluated. Instead, the
-.metn body-form -s
-are evaluated. Next, the loop variables are updated by assigning
-to each
+are not evaluated. Instead, the implicit
+.code tagbody
+comprised of the
+.metn tagbody-form -s
+is evaluated.
+If that evaluation terminates normally, the loop variables are
+then updated by assigning to each
.meta sym
the value of
.metn step-form .
@@ -15523,12 +15539,6 @@ the ANSI CL macros do not feature the automatic replication of
into the
.meta step-form
position.
-Lastly,
-.code doloop
-and
-.code doloop*
-do not implement an implicit
-.codn tagbody .
.coNP Operators @ block and @ block*
.synb