aboutsummaryrefslogtreecommitdiff
path: root/src/algebra/strap/STAGG-.lsp
diff options
context:
space:
mode:
authordos-reis <gdr@axiomatics.org>2010-06-06 04:17:00 +0000
committerdos-reis <gdr@axiomatics.org>2010-06-06 04:17:00 +0000
commitf39c8c2ab9bf4ab06fefc09d75bcc95124d0acc1 (patch)
tree86e83ad35a5208b25a6bd0bdfd3e429df7713f7f /src/algebra/strap/STAGG-.lsp
parent4f5eed96341cffc2c2e783b99cd61dde37570230 (diff)
downloadopen-axiom-f39c8c2ab9bf4ab06fefc09d75bcc95124d0acc1.tar.gz
* interp/compiler.boot (compRepeatOrCollect): Compile list
comprehension to %collect form.
Diffstat (limited to 'src/algebra/strap/STAGG-.lsp')
-rw-r--r--src/algebra/strap/STAGG-.lsp35
1 files changed, 17 insertions, 18 deletions
diff --git a/src/algebra/strap/STAGG-.lsp b/src/algebra/strap/STAGG-.lsp
index 1d31c1cd..2c69bba1 100644
--- a/src/algebra/strap/STAGG-.lsp
+++ b/src/algebra/strap/STAGG-.lsp
@@ -50,25 +50,24 @@
(SPADCALL |x| (|getShellEntry| $ 9)))
(DEFUN |STAGG-;first;ANniA;3| (|x| |n| $)
- (PROG (#0=#:G1447 |i|)
+ (PROG ()
(RETURN
- (SEQ (SPADCALL
- (PROGN
- (LETT #0# NIL |STAGG-;first;ANniA;3|)
- (SEQ (LETT |i| 1 |STAGG-;first;ANniA;3|) G190
- (COND ((QSGREATERP |i| |n|) (GO G191)))
- (LETT #0#
- (CONS (|STAGG-;c2| |x|
- (LETT |x|
- (SPADCALL |x|
- (|getShellEntry| $ 13))
- |STAGG-;first;ANniA;3|)
- $)
- #0#)
- |STAGG-;first;ANniA;3|)
- (LETT |i| (QSADD1 |i|) |STAGG-;first;ANniA;3|)
- (GO G190) G191 (EXIT (NREVERSE0 #0#))))
- (|getShellEntry| $ 15))))))
+ (SPADCALL
+ (LET ((|i| 1) (#0=#:G1447 NIL))
+ (LOOP
+ (COND
+ ((> |i| |n|) (RETURN (NREVERSE #0#)))
+ (T (LETT #0#
+ (CONS (|STAGG-;c2| |x|
+ (LETT |x|
+ (SPADCALL |x|
+ (|getShellEntry| $ 13))
+ |STAGG-;first;ANniA;3|)
+ $)
+ #0#)
+ |STAGG-;first;ANniA;3|)))
+ (LETT |i| (+ |i| 1) |STAGG-;first;ANniA;3|)))
+ (|getShellEntry| $ 15)))))
(DEFUN |STAGG-;c2| (|x| |r| $)
(COND