summaryrefslogtreecommitdiff
path: root/lisp/emacs-lisp
diff options
context:
space:
mode:
authorStefan Kangas <stefankangas@gmail.com>2022-12-12 09:05:53 +0100
committerStefan Kangas <stefankangas@gmail.com>2022-12-12 09:05:53 +0100
commitfcd0b377e0e25b7b68bd51229098edb30972352b (patch)
tree372c6ec23588ef8f80d47f408abd4a71f68b702a /lisp/emacs-lisp
parentb889eced4449555373e53c26c280dffa548dcfc3 (diff)
parent06ef030f9363a33646369e8583cbac695810fe80 (diff)
downloademacs-fcd0b377e0e25b7b68bd51229098edb30972352b.tar.gz
emacs-fcd0b377e0e25b7b68bd51229098edb30972352b.tar.bz2
emacs-fcd0b377e0e25b7b68bd51229098edb30972352b.zip
Merge from origin/emacs-29
06ef030f936 use-package.texi: New section "Manual installation" f4ce6fa7d3e Revert "Revert "Improve last change to xfaces.c" (05ece1e... b8d2ec920f3 Revert "Improve last change to xfaces.c" (05ece1eb8b) 24c8c28ae61 Do not pare arguments unnecessarily. 9c0d7bb73bb Add automated tests for Eglot d3669cfe156 Eglot: allow skipping compile-time warnings about LSP int... 04b7e01885d ; project.el: Bump version. f2876014adb Add customizale faces for tree-sitter explorer 3e349ee1198 Fix error message when installing non-existent package 733cdeabfb9 Don't use diff-mode buffer as a patch when it's visiting ... 87475f4af21 Fix pcase rx patterns using rx-let bindings (bug#59814) 4893a156317 Fix use-package-defaults defcustom type (bug#59941) 074b7e6f4d1 ; * lisp/use-package/bind-key.el: Remove ineffective back... 864ed9dfa1f ; * lisp/progmodes/dockerfile-ts-mode.el: use \' instead ... 9f7e5584a4f * lisp/language/indian.el: Improve Brahmi composition rul... 78ad33bb05f ; Minor cleanup of last change in xfaces.c. 2024ade271d ; Improve docs of relaxing face-font attribute match (bug...
Diffstat (limited to 'lisp/emacs-lisp')
-rw-r--r--lisp/emacs-lisp/package.el6
-rw-r--r--lisp/emacs-lisp/rx.el14
2 files changed, 11 insertions, 9 deletions
diff --git a/lisp/emacs-lisp/package.el b/lisp/emacs-lisp/package.el
index a9fd8c741e8..4d33311cb74 100644
--- a/lisp/emacs-lisp/package.el
+++ b/lisp/emacs-lisp/package.el
@@ -1949,8 +1949,10 @@ SEEN is used internally to detect infinite recursion."
(if (eq next-pkg 'emacs)
(error "This package requires Emacs version %s"
(package-version-join next-version))
- (error "Package `%s-%s' is unavailable"
- next-pkg (package-version-join next-version))))))
+ (error (if (not next-version)
+ (format "Package `%s' is unavailable" next-pkg)
+ (format "Package `%s' (version %s) is unavailable"
+ next-pkg (package-version-join next-version))))))))
(setq packages
(package-compute-transaction (cons found packages)
(package-desc-reqs found)
diff --git a/lisp/emacs-lisp/rx.el b/lisp/emacs-lisp/rx.el
index ec51146484a..f2a0dc54832 100644
--- a/lisp/emacs-lisp/rx.el
+++ b/lisp/emacs-lisp/rx.el
@@ -1152,7 +1152,12 @@ For extending the `rx' notation in FORM, use `rx-define' or `rx-let-eval'."
(defun rx--to-expr (form)
"Translate the rx-expression FORM to a Lisp expression yielding a regexp."
- (let* ((rx--delayed-evaluation t)
+ (let* ((rx--local-definitions
+ ;; Retrieve local definitions from the macroexpansion environment.
+ ;; (It's unclear whether the previous value of `rx--local-definitions'
+ ;; should be included, and if so, in which order.)
+ (cdr (assq :rx-locals macroexpand-all-environment)))
+ (rx--delayed-evaluation t)
(elems (car (rx--translate form)))
(args nil))
;; Merge adjacent strings.
@@ -1282,12 +1287,7 @@ Additional constructs can be defined using `rx-define' and `rx-let',
which see.
\(fn REGEXPS...)"
- ;; Retrieve local definitions from the macroexpansion environment.
- ;; (It's unclear whether the previous value of `rx--local-definitions'
- ;; should be included, and if so, in which order.)
- (let ((rx--local-definitions
- (cdr (assq :rx-locals macroexpand-all-environment))))
- (rx--to-expr (cons 'seq regexps))))
+ (rx--to-expr (cons 'seq regexps)))
(defun rx--make-binding (name tail)
"Make a definitions entry out of TAIL.