public inbox for gdb-cvs@sourceware.org
help / color / mirror / Atom feed
* [binutils-gdb] Remove some redundant "break"s
@ 2023-11-14 17:39 Tom Tromey
0 siblings, 0 replies; only message in thread
From: Tom Tromey @ 2023-11-14 17:39 UTC (permalink / raw)
To: gdb-cvs
https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=c748dbd95bf3305539956053c2a25ecea7b442a5
commit c748dbd95bf3305539956053c2a25ecea7b442a5
Author: Tom Tromey <tromey@adacore.com>
Date: Tue Nov 14 10:37:55 2023 -0700
Remove some redundant "break"s
I found some "break" statements that follow "return" or a call to a
noreturn function. These aren't needed, and the compiler would warn
if they were. So, this patch removes them.
Tested by rebuilding.
Diff:
---
gdb/breakpoint.c | 4 ----
1 file changed, 4 deletions(-)
diff --git a/gdb/breakpoint.c b/gdb/breakpoint.c
index fe09dbcbeee..a6b9b2402ed 100644
--- a/gdb/breakpoint.c
+++ b/gdb/breakpoint.c
@@ -4977,13 +4977,11 @@ print_bp_stop_message (bpstat *bs)
case print_it_noop:
/* Nothing should be printed for this bpstat entry. */
return PRINT_UNKNOWN;
- break;
case print_it_done:
/* We still want to print the frame, but we already printed the
relevant messages. */
return PRINT_SRC_AND_LOC;
- break;
case print_it_normal:
{
@@ -4997,11 +4995,9 @@ print_bp_stop_message (bpstat *bs)
/* Normal case. Call the breakpoint's print_it method. */
return b->print_it (bs);
}
- break;
default:
internal_error (_("print_bp_stop_message: unrecognized enum value"));
- break;
}
}
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2023-11-14 17:39 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-11-14 17:39 [binutils-gdb] Remove some redundant "break"s Tom Tromey
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).