Skip to content

Commit

Permalink
package-build--write-pkg-file: Don't quote nil
Browse files Browse the repository at this point in the history
  • Loading branch information
tarsius committed Sep 21, 2024
1 parent 493bf57 commit 19b6696
Showing 1 changed file with 4 additions and 12 deletions.
16 changes: 4 additions & 12 deletions package-build.el
Original file line number Diff line number Diff line change
Expand Up @@ -949,20 +949,12 @@ Use a sandbox if `package-build--use-sandbox' is non-nil."
(pp `(define-package ,(symbol-name name)
,(package-version-join (package-desc-version desc))
,(package-desc-summary desc)
',(mapcar (pcase-lambda (`(,pkg ,ver))
,(macroexp-quote
(mapcar (pcase-lambda (`(,pkg ,ver))
(list pkg (package-version-join ver)))
(package-desc-reqs desc))
(package-desc-reqs desc)))
,@(cl-mapcan (pcase-lambda (`(,key . ,val))
(when (or (symbolp val) (listp val))
;; We must quote lists and symbols,
;; because Emacs 24.3 and earlier evaluate
;; the package information, which would
;; break for unquoted symbols or lists.
;; While this library does not support
;; such old Emacsen, the packages that
;; we produce should remain compatible.
(setq val (list 'quote val)))
(list key val))
(list key (macroexp-quote val)))
(package-desc-extras desc)))
(current-buffer))
(princ ";; Local Variables:\n;; no-byte-compile: t\n;; End:\n"
Expand Down

0 comments on commit 19b6696

Please sign in to comment.