summaryrefslogtreecommitdiff
path: root/lisp/emacs-lisp
diff options
context:
space:
mode:
authorEli Zaretskii <eliz@gnu.org>2023-08-14 18:10:00 +0300
committerEli Zaretskii <eliz@gnu.org>2023-08-14 18:10:00 +0300
commitef3c410018400f34b7613786542a3ad89b1664da (patch)
treea415b80fe77252f939952f5fd41b86fcd9201b5a /lisp/emacs-lisp
parent545f95d1a3213318389ecadc7cfff3f48b555b03 (diff)
parentc868a737e41b76a6c47b1e3101a29f7eb7cc8563 (diff)
downloademacs-ef3c410018400f34b7613786542a3ad89b1664da.tar.gz
emacs-ef3c410018400f34b7613786542a3ad89b1664da.tar.bz2
emacs-ef3c410018400f34b7613786542a3ad89b1664da.zip
Merge branch 'master' of git.savannah.gnu.org:/srv/git/emacs
Diffstat (limited to 'lisp/emacs-lisp')
-rw-r--r--lisp/emacs-lisp/ert.el4
1 files changed, 3 insertions, 1 deletions
diff --git a/lisp/emacs-lisp/ert.el b/lisp/emacs-lisp/ert.el
index be9f013ebcf..4ea894f4ede 100644
--- a/lisp/emacs-lisp/ert.el
+++ b/lisp/emacs-lisp/ert.el
@@ -237,7 +237,9 @@ in batch mode, an error is signaled.
`(:expected-result-type ,expected-result))
,@(when tags-supplied-p
`(:tags ,tags))
- :body (lambda () ,@body)
+ ;; Add `nil' after the body to enable compiler warnings
+ ;; about unused computations at the end.
+ :body (lambda () ,@body nil)
:file-name ,(or (macroexp-file-name) buffer-file-name)))
',name))))