projects
/
fw
/
altos
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
altos/lisp: Rename progn to begin
[fw/altos]
/
src
/
lisp
/
ao_lisp_const.lisp
diff --git
a/src/lisp/ao_lisp_const.lisp
b/src/lisp/ao_lisp_const.lisp
index 9fb7634c5858e1cd7d4d76330b8ab72953ad9da6..f8a709799ff5b05b580246bc176910b4345545d2 100644
(file)
--- a/
src/lisp/ao_lisp_const.lisp
+++ b/
src/lisp/ao_lisp_const.lisp
@@
-25,7
+25,7
@@
(set (quote define) (macro (name val rest)
(list
(set (quote define) (macro (name val rest)
(list
- '
prog
n
+ '
begi
n
(list
'set
(list 'quote name)
(list
'set
(list 'quote name)
@@
-520,6
+520,26
@@
'(54 0 37 -3 245 19))
#t))
'(54 0 37 -3 245 19))
#t))
+(define repeat (macro (count rest)
+ (list
+ let
+ (list
+ (list '__count__ count))
+ (append
+ (list
+ while
+ (list
+ <=
+ 0
+ (list
+ set!
+ '__count__
+ (list
+ -
+ '__count__
+ 1))))
+ rest))))
+
;(define number->string (lexpr (arg opt)
; (let ((base (if (null? opt) 10 (car opt)))
;
;(define number->string (lexpr (arg opt)
; (let ((base (if (null? opt) 10 (car opt)))
;