Mercurial > emacs
comparison lisp/emacs-lisp/cl-macs.el @ 103195:22f651c59c50
* emacs-lisp/cl-macs.el (lexical-let*): Doc fix (Bug#3178).
author | Chong Yidong <cyd@stupidchicken.com> |
---|---|
date | Sun, 10 May 2009 22:01:20 +0000 |
parents | a9dc0e7c3f2b |
children | d2b52a0cf462 |
comparison
equal
deleted
inserted
replaced
103194:aed44175c8f2 | 103195:22f651c59c50 |
---|---|
1446 ebody)))) | 1446 ebody)))) |
1447 | 1447 |
1448 ;;;###autoload | 1448 ;;;###autoload |
1449 (defmacro lexical-let* (bindings &rest body) | 1449 (defmacro lexical-let* (bindings &rest body) |
1450 "Like `let*', but lexically scoped. | 1450 "Like `let*', but lexically scoped. |
1451 The main visible difference is that lambdas inside BODY will create | 1451 The main visible difference is that lambdas inside BODY, and in |
1452 lexical closures as in Common Lisp. | 1452 successive bindings within BINDINGS, will create lexical closures |
1453 as in Common Lisp. This is similar to the behavior of `let*' in | |
1454 Common Lisp. | |
1453 \n(fn VARLIST BODY)" | 1455 \n(fn VARLIST BODY)" |
1454 (if (null bindings) (cons 'progn body) | 1456 (if (null bindings) (cons 'progn body) |
1455 (setq bindings (reverse bindings)) | 1457 (setq bindings (reverse bindings)) |
1456 (while bindings | 1458 (while bindings |
1457 (setq body (list (list* 'lexical-let (list (pop bindings)) body)))) | 1459 (setq body (list (list* 'lexical-let (list (pop bindings)) body)))) |