fix(lib): ensure after! body gets expanded

Relying on eval-after-load's compiler-macro magic (after 8b4f722) can
cause scope issues with nested macros (like file! and dir! running in
the context of a temp buffer), so best we use with-eval-after-load
directly.

Ref: 8b4f722fa3
This commit is contained in:
Henrik Lissner 2022-09-08 13:16:59 +02:00
parent 7e0c2ed8a3
commit f3e85afc7e
No known key found for this signature in database
GPG key ID: B60957CA074D39A3

View file

@ -586,7 +586,7 @@ things you want byte-compiled in them! Like function/macro definitions."
(require package nil 'noerror)) (require package nil 'noerror))
#'progn #'progn
#'with-no-warnings) #'with-no-warnings)
`(eval-after-load ',package ',(macroexp-progn body)))) `(with-eval-after-load ',package ,@body)))
(let ((p (car package))) (let ((p (car package)))
(cond ((memq p '(:or :any)) (cond ((memq p '(:or :any))
(macroexp-progn (macroexp-progn