diff options
author | Mark Oteiza <mvoteiza@udel.edu> | 2017-09-12 12:44:45 -0400 |
---|---|---|
committer | Mark Oteiza <mvoteiza@udel.edu> | 2017-09-12 13:18:06 -0400 |
commit | 4612b2a2b37026bef5a9b8e92878a15dabb9b261 (patch) | |
tree | 2434bb2f510047ae9570086c424266743411a39f /lisp/emacs-lisp/cl-macs.el | |
parent | c87331a1c04aa4be55be7b944680e4ec486f5b04 (diff) | |
download | emacs-4612b2a2b37026bef5a9b8e92878a15dabb9b261.tar.gz emacs-4612b2a2b37026bef5a9b8e92878a15dabb9b261.tar.bz2 emacs-4612b2a2b37026bef5a9b8e92878a15dabb9b261.zip |
Implement and-let*
This also includes changes to if-let and when-let. The single tuple
special case is ambiguous, and binding a symbol to nil is not as
useful as binding it to its value outside the lexical scope of the
binding. (Bug#28254)
* etc/NEWS: Mention.
* lisp/emacs-lisp/subr-x.el (internal--listify):
(internal--build-binding-value-form): Extend to account for
solitary symbols and (EXPR) items in binding varlist.
(if-let*, when-let*): Nix single tuple case and incumbent
bind-symbol-to-nil behavior.
(and-let*): New macro.
(if-let, when-let): Mark obsolete. Redefine in terms of if-let*, so
they implicitly gain the new features without breaking existing code.
* test/lisp/emacs-lisp/subr-x-tests.el: Adjust tests for: lack of
single-tuple special case, lack of binding solitary symbols to nil,
and the introduction of uninterned symbols for (EXPR) bindings. Add
SRFI-2 test suite adapted to Elisp.
Diffstat (limited to 'lisp/emacs-lisp/cl-macs.el')
0 files changed, 0 insertions, 0 deletions