projects
/
jscl.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
3cac80c
)
For loop
author
David Vázquez
<davazp@gmail.com>
Mon, 24 Jun 2013 12:16:40 +0000
(14:16 +0200)
committer
David Vázquez
<davazp@gmail.com>
Mon, 24 Jun 2013 12:16:40 +0000
(14:16 +0200)
src/compiler-codegen.lisp
patch
|
blob
|
history
diff --git
a/src/compiler-codegen.lisp
b/src/compiler-codegen.lisp
index
6a3abc9
..
27114b2
100644
(file)
--- a/
src/compiler-codegen.lisp
+++ b/
src/compiler-codegen.lisp
@@
-446,6
+446,16
@@
(js-expr condition)
(js-format ")")
(js-stmt `(progn ,@body))))
+ (for
+ (destructuring-bind ((start condition step) &body body) (cdr form)
+ (js-format "for (")
+ (js-expr start)
+ (js-format ";")
+ (js-expr condition)
+ (js-format ";")
+ (js-expr step)
+ (js-format ")")
+ (js-stmt `(progn ,@body))))
(try
(destructuring-bind (&rest body) (cdr form)
(js-format "try")