[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/compat c445418 04/99: Fix named-let implementation
From: |
ELPA Syncer |
Subject: |
[elpa] externals/compat c445418 04/99: Fix named-let implementation |
Date: |
Sun, 17 Oct 2021 05:57:47 -0400 (EDT) |
branch: externals/compat
commit c445418968537d2c99ad01c66f7c9d7f86494a66
Author: Philip Kaludercic <philipk@posteo.net>
Commit: Philip Kaludercic <philipk@posteo.net>
Fix named-let implementation
The previous version inserted a quoted symbol into the funcall
generated by the macro. Since letrec binds the variable directly, the
value couldn't be seen and the generated code threw an error when
evaluated.
Thanks again to Mattias EngdegÄrd for noticing this.
---
compat-28.1.el | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/compat-28.1.el b/compat-28.1.el
index d2ff192..93d3699 100644
--- a/compat-28.1.el
+++ b/compat-28.1.el
@@ -321,15 +321,15 @@ Like `let', bind variables in BINDINGS and then evaluate
BODY,
but with the twist that BODY can evaluate itself recursively by
calling NAME, where the arguments passed to NAME are used
as the new values of the bound variables in the recursive invocation."
- ;; :feature subr-x
+ :feature subr-x
(declare (indent 2) (debug (symbolp (&rest (symbolp form)) body)))
(let* ((fargs (mapcar (lambda (b) (if (consp b) (car b) b)) bindings))
(aargs (mapcar (lambda (b) (if (consp b) (cadr b))) bindings))
(fn (make-symbol "self"))
- (macro (lambda (&rest args) `(apply ',fn (list ,@args)))))
- `(letrec ((,fn (lambda ,fargs . ,(macroexpand-all
- (macroexp-progn body)
- (list (cons name macro))))))
+ (macro (lambda (&rest args) `(apply ,fn (list ,@args)))))
+ `(letrec ((,fn (lambda ,fargs ,(macroexpand-all
+ (macroexp-progn body)
+ (list (cons name macro))))))
(apply ,fn (list ,@aargs)))))
;;;; Defined in files.el
- [elpa] branch externals/compat created (now 5506770), ELPA Syncer, 2021/10/17
- [elpa] externals/compat 51b832c 02/99: Remove compat--disable-defer check from installation check, ELPA Syncer, 2021/10/17
- [elpa] externals/compat 10033e0 01/99: Initial import, ELPA Syncer, 2021/10/17
- [elpa] externals/compat e00fc9c 03/99: Simplify mapcan implementation, ELPA Syncer, 2021/10/17
- [elpa] externals/compat 9688d79 05/99: Split proper-list-p into two implementations, ELPA Syncer, 2021/10/17
- [elpa] externals/compat c445418 04/99: Fix named-let implementation,
ELPA Syncer <=
- [elpa] externals/compat b8e8cba 07/99: Use markdown instead of outline-mode for the README file, ELPA Syncer, 2021/10/17
- [elpa] externals/compat a403485 10/99: Require compat-macs in eval-when-compile instead of eval-and-compile, ELPA Syncer, 2021/10/17
- [elpa] externals/compat 0d77194 14/99: Remove compat--disable-defer variable, ELPA Syncer, 2021/10/17
- [elpa] externals/compat eafe584 15/99: Remove unnecessary eval-and-compile block from compat-tests, ELPA Syncer, 2021/10/17
- [elpa] externals/compat c7d1615 06/99: Remove elisp-shorthands from compat-tests.el, ELPA Syncer, 2021/10/17
- [elpa] externals/compat 5936773 08/99: Fix installation check, ELPA Syncer, 2021/10/17
- [elpa] externals/compat d77b31f 11/99: Reorder files to byte compile in Makefile, ELPA Syncer, 2021/10/17
- [elpa] externals/compat 12e36f7 12/99: Check if actual name is fbound before binding a function or macro, ELPA Syncer, 2021/10/17
- [elpa] externals/compat 5846fbe 13/99: Pull compatibility definition out of eval-after-load block, ELPA Syncer, 2021/10/17
- [elpa] externals/compat b3d1100 17/99: Prepend font-lock-preprocessor-face to compatibility symbols, ELPA Syncer, 2021/10/17