emacs/test/lisp
Mattias Engdegård 7c63b632e4 Add empty-body warning for when, unless etc
Warn about code like (when SOME-CONDITION) because these may indicate
bugs.  Warnings currently apply to `when`, `unless`, `ignore-error`,
`with-suppressed-warnings` and (as before) `let` and `let*`.

* lisp/emacs-lisp/byte-run.el (with-suppressed-warnings):
Update doc string.
* lisp/emacs-lisp/bytecomp.el: (byte-compile-warning-types)
(byte-compile-warnings): Add empty-body.
(byte-compile-initial-macro-environment):
Add empty-body warning for with-suppressed-warnings.
* lisp/emacs-lisp/macroexp.el (macroexp--expand-all):
Use the empty-body category for let and let*.
* lisp/subr.el (when, unless, ignore-error): Add empty-body warning.
* test/lisp/emacs-lisp/bytecomp-tests.el
(bytecomp-test--with-suppressed-warnings): Add test cases.
2022-12-29 13:01:47 +01:00
..
align-resources Add some tests for align.el 2020-12-29 08:38:25 +01:00
auth-source-resources Move netrc tests to auth-source-tests.el 2022-08-04 17:33:34 +02:00
bookmark-resources Add ability to mark/unmark/delete all bookmarks 2020-08-09 15:13:05 -05:00
calc Remove redundant local variables in tests 2022-08-08 13:47:15 +02:00
calendar Delete temp files after icalendar tests 2022-12-14 08:21:34 +01:00
cedet ; Fix typos (don't abbreviate "with" or "without") 2022-12-01 16:36:09 +01:00
custom-resources Avoid saving session customizations in the custom-file 2021-05-10 13:33:32 +02:00
dired-resources/insert-directory Change how Dired displays available space 2021-12-01 23:27:19 +01:00
emacs-lisp Add empty-body warning for when, unless etc 2022-12-29 13:01:47 +01:00
emulation Merge from origin/emacs-28 2022-01-01 07:03:03 -05:00
epg-resources Replace aging OpenPGP artifacts in the epg tests. 2022-10-06 14:53:39 +02:00
erc Warn of absent networks module in ERC 2022-12-28 06:51:38 -08:00
eshell Simplify handling of /dev/null redirection in Eshell 2022-12-22 11:35:12 -08:00
faces-resources ; Add 2022 to copyright years. 2022-01-01 02:45:51 -05:00
files-resources * test/lisp/files-resources/compile-utf8.el: Use lexical-binding 2022-05-26 12:16:04 -04:00
gnus ; Fix typos 2022-12-26 10:42:02 +01:00
hfy-cmap-resources * test/lisp/hfy-cmap-resources/rgb.txt: Add comment line. 2020-11-12 03:20:39 +01:00
image ; * test/lisp/image/wallpaper-tests.el: Simplify last change. 2022-10-19 20:53:36 +02:00
international Do not run slow tests on EMBA 2022-12-06 12:36:15 +01:00
loadhist-resources ; Normalize GPLv3 license statements in new files 2022-12-09 00:13:00 +01:00
mail Prefer pos-bol and pos-eol in tests 2022-08-21 17:45:04 +02:00
mh-e ; Pacify unknown fun warning in mh-utils-tests.el. 2022-06-26 15:08:57 +03:00
minibuffer-resources Move more test data to follow our conventions 2020-10-23 21:07:26 +02:00
net Handle make-directory return values in file name handlers 2022-12-22 19:39:59 +01:00
nxml ; Add 2022 to copyright years. 2022-01-01 02:45:51 -05:00
obsolete Move thumbs.el to lisp/obsolete 2022-09-24 14:07:57 +02:00
org ; Add 2022 to copyright years. 2022-01-01 02:45:51 -05:00
pcmpl-linux-resources Use lexical-binding in pcmpl-linux.el and add tests 2020-09-02 12:53:02 +02:00
play ; Add 2022 to copyright years. 2022-01-01 02:45:51 -05:00
progmodes ; Fix typos 2022-12-26 10:42:02 +01:00
saveplace-resources Use lexical-binding in saveplace.el and add tests 2020-08-08 01:40:38 +02:00
so-long-tests Fix more misleading cl-case quoting in tests 2022-09-14 14:20:52 +03:00
term ; Add 2022 to copyright years. 2022-01-01 02:45:51 -05:00
textmodes Consider key=val labels when renumbering 2022-09-12 09:34:23 +02:00
time-resources Add missed file needed by time-tests.el 2020-10-22 18:51:00 +02:00
url ; Fix typos in some function names 2022-12-20 06:15:55 +01:00
use-package ; Normalize GPLv3 license statements in new files 2022-12-09 00:13:00 +01:00
vc Add some diff-fixup-modifs tests 2022-12-24 09:27:07 +02:00
xdg-resources Move more test data to follow our conventions 2020-10-23 21:07:26 +02:00
abbrev-tests.el Don't signal errors in abbrev-table-p 2022-02-14 12:00:22 +01:00
align-tests.el ; Add 2022 to copyright years. 2022-01-01 02:45:51 -05:00
allout-tests.el ; Add 2022 to copyright years. 2022-01-01 02:45:51 -05:00
allout-widgets-tests.el ; Add 2022 to copyright years. 2022-01-01 02:45:51 -05:00
ansi-color-tests.el test: Remove redundant "" arg to mapconcat 2022-09-08 16:08:42 -04:00
ansi-osc-tests.el Rename osc.el to ansi-osc.el (bug#58200) 2022-10-01 11:58:27 +02:00
apropos-tests.el Audit some plist uses with new predicate argument 2022-10-22 19:33:12 +03:00
arc-mode-tests.el ; Add 2022 to copyright years. 2022-01-01 02:45:51 -05:00
auth-source-pass-tests.el Respect some spaces in auth-source-pass--match-regexp 2022-12-09 06:35:36 -08:00
auth-source-tests.el Move netrc tests to auth-source-tests.el 2022-08-04 17:33:34 +02:00
autoinsert-tests.el Merge from origin/emacs-28 2022-01-01 07:03:03 -05:00
autorevert-tests.el ; Fix typos in symbol names 2022-10-27 23:04:37 +02:00
battery-tests.el ; Add 2022 to copyright years. 2022-01-01 02:45:51 -05:00
bookmark-tests.el Update bookmark tests for recent change 2022-06-17 20:08:55 +02:00
buff-menu-tests.el Merge from origin/emacs-28 2022-01-01 07:03:03 -05:00
button-tests.el Merge from origin/emacs-28 2022-01-01 07:03:03 -05:00
calculator-tests.el ; Add 2022 to copyright years. 2022-01-01 02:45:51 -05:00
char-fold-tests.el test: Remove redundant "" arg to mapconcat 2022-09-08 16:08:42 -04:00
color-tests.el Fix color-lighten-hsl logic 2022-03-22 15:28:02 +01:00
comint-tests.el ; * test/lisp/comint-tests.el (w32-application-type): Fix typo. 2022-12-07 21:52:00 +02:00
completion-tests.el ; Add 2022 to copyright years. 2022-01-01 02:45:51 -05:00
cus-edit-tests.el Repair setopt test after error demotion to warning 2022-12-19 12:05:09 +01:00
custom-tests.el Fix cl-generic bootstrap problems 2022-06-24 11:04:51 +02:00
dabbrev-tests.el ; Add 2022 to copyright years. 2022-01-01 02:45:51 -05:00
delim-col-tests.el ; Fix typos 2022-12-16 08:29:28 +01:00
descr-text-tests.el ; Add 2022 to copyright years. 2022-01-01 02:45:51 -05:00
desktop-tests.el Load desktop without prompting if process is dead 2022-03-24 09:23:31 +01:00
dired-aux-tests.el Move dired-guess commands from dired-x to dired 2022-08-17 16:21:09 +02:00
dired-tests.el ; * test/lisp/dired-tests.el (dired-test-bug59047): Rename. 2022-11-10 12:08:47 +02:00
dired-x-tests.el Move dired-guess commands from dired-x to dired 2022-08-17 16:21:09 +02:00
dnd-tests.el ; Prefer HTTPS to HTTP in many URLs 2022-10-15 13:06:45 +02:00
dom-tests.el ; Add 2022 to copyright years. 2022-01-01 02:45:51 -05:00
edmacro-tests.el test/lisp/edmacro-tests.el: Adjust to recent changes 2022-04-04 09:55:03 -04:00
electric-tests.el Merge from origin/emacs-28 2022-09-21 10:25:06 +02:00
elide-head-tests.el Support Apache License 2.0 in elide-head-mode 2022-12-27 18:16:58 +01:00
env-tests.el * test/lisp/env-tests.el: New file. 2022-08-05 11:47:05 +02:00
epg-config-tests.el ; Add 2022 to copyright years. 2022-01-01 02:45:51 -05:00
epg-tests.el Replace aging OpenPGP artifacts in the epg tests. 2022-10-06 14:53:39 +02:00
faces-tests.el ; Add 2022 to copyright years. 2022-01-01 02:45:51 -05:00
ffap-tests.el Convert ffap comments to tests 2022-07-28 15:07:34 +02:00
filenotify-tests.el ; Fix typos (don't abbreviate "with" or "without") 2022-12-01 16:36:09 +01:00
files-tests.el Fix copy-directory bug when dest dir exists 2022-12-17 14:24:16 -08:00
files-x-tests.el Add helpers to dynamically assign connection-local values 2022-10-17 18:48:52 -07:00
find-cmd-tests.el ; Add 2022 to copyright years. 2022-01-01 02:45:51 -05:00
font-lock-tests.el ; Add 2022 to copyright years. 2022-01-01 02:45:51 -05:00
format-spec-tests.el Make format-spec accept function substitutions 2022-09-29 15:39:27 +02:00
help-fns-tests.el Merge from origin/emacs-28 2022-07-23 01:37:59 +02:00
help-mode-tests.el Allow using xref buttons in non-*Help* buffers 2022-06-06 16:12:39 +02:00
help-tests.el Fix substitute-command-keys for global binding lookup 2022-09-21 09:15:47 +02:00
hfy-cmap-tests.el ; Add 2022 to copyright years. 2022-01-01 02:45:51 -05:00
hi-lock-tests.el Fix thinko in previous hi-lock-read-face-name change 2022-01-20 14:53:12 +01:00
hl-line-tests.el Fix hl-line tests 2022-03-23 20:25:33 +08:00
htmlfontify-tests.el Don't generate separate autoload file for htmlfontify 2022-06-05 18:23:17 +02:00
ibuffer-tests.el Make ibuffer-awhen obsolete in favor of when-let 2022-08-09 15:46:54 +02:00
ido-tests.el ; Add 2022 to copyright years. 2022-01-01 02:45:51 -05:00
image-file-tests.el ; Add 2022 to copyright years. 2022-01-01 02:45:51 -05:00
image-tests.el Fix failing image test on nox builds 2022-05-01 01:19:51 +03:00
imenu-tests.el ; Add 2022 to copyright years. 2022-01-01 02:45:51 -05:00
info-tests.el ; Add 2022 to copyright years. 2022-01-01 07:07:15 -05:00
info-xref-tests.el Prefer pos-bol and pos-eol in tests 2022-08-21 17:45:04 +02:00
isearch-tests.el * lisp/isearch.el (isearch-search-fun-in-noncontiguous-region): New function. 2022-07-08 20:58:33 +03:00
jit-lock-tests.el ; Add 2022 to copyright years. 2022-01-01 02:45:51 -05:00
json-tests.el Allow plist-get/plist-put/plist-member to take a comparison function 2022-06-27 12:22:05 +02:00
jsonrpc-tests.el ; Add 2022 to copyright years. 2022-01-01 02:45:51 -05:00
kmacro-tests.el kmacro: Represent it as an OClosure 2022-04-01 20:07:33 -04:00
loadhist-tests.el (function-history): New symbol property (bug#53632) 2022-01-31 11:07:26 -05:00
lpr-tests.el ; Add 2022 to copyright years. 2022-01-01 02:45:51 -05:00
ls-lisp-tests.el Fix sorting in ls-lisp.el under -v 2022-06-05 09:52:09 +03:00
man-tests.el ; Add 2022 to copyright years. 2022-01-01 02:45:51 -05:00
md4-tests.el test: Remove redundant "" arg to mapconcat 2022-09-08 16:08:42 -04:00
minibuffer-tests.el * lisp/simple.el (completion-auto-wrap): Rename from completion-wrap-movement. 2022-06-14 10:04:56 +03:00
misc-tests.el Add duplicate-dwim (bug#56418) 2022-07-26 14:23:30 +02:00
mouse-tests.el Fix handling double-click-time nil or t 2022-05-02 12:03:08 +02:00
mwheel-tests.el ; Add 2022 to copyright years. 2022-01-01 02:45:51 -05:00
newcomment-tests.el ; Add 2022 to copyright years. 2022-01-01 02:45:51 -05:00
obarray-tests.el ; Add 2022 to copyright years. 2022-01-01 02:45:51 -05:00
paren-tests.el Merge from origin/emacs-28 2022-01-01 07:03:03 -05:00
password-cache-tests.el ; Add 2022 to copyright years. 2022-01-01 02:45:51 -05:00
pcmpl-linux-tests.el ; Add 2022 to copyright years. 2022-01-01 02:45:51 -05:00
pcomplete-tests.el pcomplete: Generate completions from --help messages 2022-09-14 21:58:04 +02:00
proced-tests.el Make proced-tests work on more systems 2022-12-14 16:53:29 +02:00
ps-print-tests.el ; Add 2022 to copyright years. 2022-01-01 02:45:51 -05:00
register-tests.el ; Add 2022 to copyright years. 2022-01-01 02:45:51 -05:00
repeat-tests.el * lisp/repeat.el: Fix repeat-keep-prefix to allow customizing it to non-nil. 2022-12-20 19:22:15 +02:00
replace-tests.el Prefer pos-bol and pos-eol in tests 2022-08-21 17:45:04 +02:00
rot13-tests.el ; Add 2022 to copyright years. 2022-01-01 02:45:51 -05:00
saveplace-tests.el Fix namespace problem in saveplace.el 2022-08-05 12:28:59 +02:00
scroll-lock-tests.el ; Add 2022 to copyright years. 2022-01-01 02:45:51 -05:00
server-tests.el ; Fix a failure when running server-tests via the command line 2022-12-10 11:06:47 +01:00
ses-tests.el ses-test Prefix used symbols by ses-- 2022-04-10 00:26:33 +02:00
shadowfile-tests.el Fix Tramp test environment on hydra.nixos.org 2022-07-10 18:13:50 +02:00
shell-tests.el ; Add 2022 to copyright years. 2022-01-01 02:45:51 -05:00
simple-tests.el Fix simple-tests when run noninteractively 2022-11-18 12:12:09 +01:00
sort-tests.el test: Remove redundant "" arg to mapconcat 2022-09-08 16:08:42 -04:00
soundex-tests.el ; Add 2022 to copyright years. 2022-01-01 02:45:51 -05:00
startup-tests.el ; Add 2022 to copyright years. 2022-01-01 02:45:51 -05:00
subr-tests.el Avoid raw control characters in two files 2022-11-17 20:10:05 +01:00
tab-bar-tests.el ; Add 2022 to copyright years. 2022-01-01 02:45:51 -05:00
tabify-tests.el test: Remove redundant "" arg to mapconcat 2022-09-08 16:08:42 -04:00
tar-mode-tests.el Merge from origin/emacs-28 2022-01-01 07:03:03 -05:00
tempo-tests.el ; Add 2022 to copyright years. 2022-01-01 02:45:51 -05:00
term-tests.el Merge from origin/emacs-28 2022-01-01 07:03:03 -05:00
thingatpt-tests.el Teach thing-at-point to recognize bracketed IPv6 URLs 2022-11-09 05:15:11 -08:00
thread-tests.el ; Add 2022 to copyright years. 2022-01-01 02:45:51 -05:00
time-stamp-tests.el ; improve test coverage of time-stamp-pattern parsing 2022-10-14 20:47:27 -07:00
time-tests.el ; Add 2022 to copyright years. 2022-01-01 02:45:51 -05:00
timezone-tests.el ; Add 2022 to copyright years. 2022-01-01 02:45:51 -05:00
version-tests.el ; Add 2022 to copyright years. 2022-01-01 02:45:51 -05:00
wdired-tests.el Merge from origin/emacs-28 2022-01-01 07:03:03 -05:00
whitespace-tests.el whitespace: Avoid mutating original buffer's markers in clones 2022-12-21 16:02:30 +02:00
wid-edit-tests.el ; Add 2022 to copyright years. 2022-01-01 02:45:51 -05:00
x-dnd-tests.el Fix typo in x-dnd-tests.el 2022-07-25 10:08:41 +08:00
xdg-tests.el Add new function xdg-current-desktop to xdg.el 2022-09-14 10:23:45 +02:00
xml-tests.el Remove no-byte-compile cookie from some libraries 2022-08-08 11:50:33 +02:00
xt-mouse-tests.el Pacify obsolete gv warnings in xt-mouse-tests.el 2022-08-26 12:53:49 +03:00
yank-media-tests.el Fix yank-media utf-16 detection 2022-02-05 08:50:05 +01:00