public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
* [Bug c/104044] New: Useless empty statements (across projects) @ 2022-01-15 23:01 roland.illig at gmx dot de 2022-11-20 2:26 ` [Bug other/104044] " cvs-commit at gcc dot gnu.org ` (2 more replies) 0 siblings, 3 replies; 4+ messages in thread From: roland.illig at gmx dot de @ 2022-01-15 23:01 UTC (permalink / raw) To: gcc-bugs https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104044 Bug ID: 104044 Summary: Useless empty statements (across projects) Product: gcc Version: 12.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c Assignee: unassigned at gcc dot gnu.org Reporter: roland.illig at gmx dot de Target Milestone: --- mn10300.c says: > break;; nvptx.c says: > tree r = NULL_TREE;; jit-playback.c says: > tree x = as_tree ();; These extra semicolons (and all the others in the whole tree) should be removed, as they don't add any value. Quite the opposite, they create an impression that the code were carelessly written. I'm only concerned about obviously useless semicolons. In particular, I have no problem with the empty statement in "while (i-- > 0) ;". Is there a GCC warning for useless empty statements like these? I saw that this was already reported as Bug 49053, but maybe your attitude towards this topic changed in the past 5 years. I stumbled upon these empty statements as I made the same mistake in my own code. ^ permalink raw reply [flat|nested] 4+ messages in thread
* [Bug other/104044] Useless empty statements (across projects) 2022-01-15 23:01 [Bug c/104044] New: Useless empty statements (across projects) roland.illig at gmx dot de @ 2022-11-20 2:26 ` cvs-commit at gcc dot gnu.org 2022-11-20 2:27 ` law at gcc dot gnu.org 2022-11-28 22:32 ` pinskia at gcc dot gnu.org 2 siblings, 0 replies; 4+ messages in thread From: cvs-commit at gcc dot gnu.org @ 2022-11-20 2:26 UTC (permalink / raw) To: gcc-bugs https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104044 --- Comment #1 from CVS Commits <cvs-commit at gcc dot gnu.org> --- The master branch has been updated by Jeff Law <law@gcc.gnu.org>: https://gcc.gnu.org/g:6d82e0fea5f988e829912aaa70a9964a81ad4e5e commit r13-4173-g6d82e0fea5f988e829912aaa70a9964a81ad4e5e Author: Jeff Law <jlaw@ventanamicro.com> Date: Sat Nov 19 19:21:37 2022 -0700 [PR other/104044] Remove extraneous semicolons gcc/ PR other/104044 * config/mn10300/mn10300.cc (mn10300_print_operand): Remove extraneous semicolon. * config/nvptx/nvptx.cc (nvptx_goacc_reduction_fini): Likewise. gcc/jit/ PR other/104044 * jit-playback.cc (playback::lvale::mark_addressable): Remove extraeous semicolon ^ permalink raw reply [flat|nested] 4+ messages in thread
* [Bug other/104044] Useless empty statements (across projects) 2022-01-15 23:01 [Bug c/104044] New: Useless empty statements (across projects) roland.illig at gmx dot de 2022-11-20 2:26 ` [Bug other/104044] " cvs-commit at gcc dot gnu.org @ 2022-11-20 2:27 ` law at gcc dot gnu.org 2022-11-28 22:32 ` pinskia at gcc dot gnu.org 2 siblings, 0 replies; 4+ messages in thread From: law at gcc dot gnu.org @ 2022-11-20 2:27 UTC (permalink / raw) To: gcc-bugs https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104044 Jeffrey A. Law <law at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |law at gcc dot gnu.org Status|UNCONFIRMED |RESOLVED Resolution|--- |FIXED --- Comment #2 from Jeffrey A. Law <law at gcc dot gnu.org> --- Fixed on the trunk. ^ permalink raw reply [flat|nested] 4+ messages in thread
* [Bug other/104044] Useless empty statements (across projects) 2022-01-15 23:01 [Bug c/104044] New: Useless empty statements (across projects) roland.illig at gmx dot de 2022-11-20 2:26 ` [Bug other/104044] " cvs-commit at gcc dot gnu.org 2022-11-20 2:27 ` law at gcc dot gnu.org @ 2022-11-28 22:32 ` pinskia at gcc dot gnu.org 2 siblings, 0 replies; 4+ messages in thread From: pinskia at gcc dot gnu.org @ 2022-11-28 22:32 UTC (permalink / raw) To: gcc-bugs https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104044 Andrew Pinski <pinskia at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Target Milestone|--- |13.0 ^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2022-11-28 22:32 UTC | newest] Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- 2022-01-15 23:01 [Bug c/104044] New: Useless empty statements (across projects) roland.illig at gmx dot de 2022-11-20 2:26 ` [Bug other/104044] " cvs-commit at gcc dot gnu.org 2022-11-20 2:27 ` law at gcc dot gnu.org 2022-11-28 22:32 ` pinskia at gcc dot gnu.org
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).