From: Andrew Burgess via Gdb-patches <gdb-patches@sourceware.org>
To: gdb-patches@sourceware.org
Cc: Andrew Burgess <aburgess@redhat.com>
Subject: [PATCH 8/9] gdb/mi: some int to bool conversion
Date: Thu, 23 Jun 2022 17:05:15 +0100 [thread overview]
Message-ID: <f3ece7bb60048418077d2e9cf9941209fcccc16b.1655999715.git.aburgess@redhat.com> (raw)
In-Reply-To: <cover.1655999715.git.aburgess@redhat.com>
Just some simple int to bool conversion in mi_cmd_disassemble. There
should be no user visible changes after this commit.
---
gdb/mi/mi-cmd-disas.c | 24 ++++++++++++------------
1 file changed, 12 insertions(+), 12 deletions(-)
diff --git a/gdb/mi/mi-cmd-disas.c b/gdb/mi/mi-cmd-disas.c
index c8e06cd940a..4f6e5613b9d 100644
--- a/gdb/mi/mi-cmd-disas.c
+++ b/gdb/mi/mi-cmd-disas.c
@@ -62,12 +62,12 @@ mi_cmd_disassemble (const char *command, char **argv, int argc)
struct symtab *s;
/* Which options have we processed ... */
- int file_seen = 0;
- int line_seen = 0;
- int num_seen = 0;
- int start_seen = 0;
- int end_seen = 0;
- int addr_seen = 0;
+ bool file_seen = false;
+ bool line_seen = false;
+ bool num_seen = false;
+ bool start_seen = false;
+ bool end_seen = false;
+ bool addr_seen = false;
/* ... and their corresponding value. */
char *file_string = NULL;
@@ -107,27 +107,27 @@ mi_cmd_disassemble (const char *command, char **argv, int argc)
{
case FILE_OPT:
file_string = oarg;
- file_seen = 1;
+ file_seen = true;
break;
case LINE_OPT:
line_num = atoi (oarg);
- line_seen = 1;
+ line_seen = true;
break;
case NUM_OPT:
how_many = atoi (oarg);
- num_seen = 1;
+ num_seen = true;
break;
case START_OPT:
low = parse_and_eval_address (oarg);
- start_seen = 1;
+ start_seen = true;
break;
case END_OPT:
high = parse_and_eval_address (oarg);
- end_seen = 1;
+ end_seen = true;
break;
case ADDR_OPT:
addr = parse_and_eval_address (oarg);
- addr_seen = 1;
+ addr_seen = true;
break;
}
}
--
2.25.4
next prev parent reply other threads:[~2022-06-23 16:10 UTC|newest]
Thread overview: 25+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-06-23 16:05 [PATCH 0/9] Disassembler opcode display and text alignment Andrew Burgess via Gdb-patches
2022-06-23 16:05 ` [PATCH 1/9] gdb/doc: improve description of --data-disassemble opcodes output Andrew Burgess via Gdb-patches
2022-06-23 16:09 ` Eli Zaretskii via Gdb-patches
2022-06-29 12:54 ` Andrew Burgess via Gdb-patches
2022-06-23 16:05 ` [PATCH 2/9] gdb/testsuite: new test for -data-disassemble opcodes format Andrew Burgess via Gdb-patches
2022-06-23 16:05 ` [PATCH 3/9] gdb/disasm: read opcodes bytes with a single read_code call Andrew Burgess via Gdb-patches
2022-06-23 16:05 ` [PATCH 4/9] gdb: disassembler opcode display formatting Andrew Burgess via Gdb-patches
2022-06-23 16:14 ` Eli Zaretskii via Gdb-patches
2022-06-23 16:05 ` [PATCH 5/9] gdb: make gdb_disassembly_flag unsigned Andrew Burgess via Gdb-patches
2022-06-23 16:05 ` [PATCH 6/9] gdb/doc: fix column widths in MI compatibility table Andrew Burgess via Gdb-patches
2022-06-23 16:22 ` Eli Zaretskii via Gdb-patches
2022-06-30 9:39 ` Andrew Burgess via Gdb-patches
2022-06-23 16:05 ` [PATCH 7/9] gdb/doc: update syntax of -data-disassemble command arguments Andrew Burgess via Gdb-patches
2022-06-23 16:21 ` Eli Zaretskii via Gdb-patches
2022-06-30 10:18 ` Andrew Burgess via Gdb-patches
2022-06-30 10:46 ` Eli Zaretskii via Gdb-patches
2022-06-23 16:05 ` Andrew Burgess via Gdb-patches [this message]
2022-06-23 16:05 ` [PATCH 9/9] gdb/mi: new options for -data-disassemble command Andrew Burgess via Gdb-patches
2022-06-23 16:34 ` Eli Zaretskii via Gdb-patches
2022-06-30 11:22 ` Andrew Burgess via Gdb-patches
2022-06-30 13:36 ` Eli Zaretskii via Gdb-patches
2022-07-25 18:28 ` [PATCH 0/9] Disassembler opcode display and text alignment Andrew Burgess via Gdb-patches
2022-09-05 14:11 ` Andrew Burgess via Gdb-patches
2022-09-21 16:41 ` Tom Tromey
2022-10-02 13:15 ` Andrew Burgess via Gdb-patches
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=f3ece7bb60048418077d2e9cf9941209fcccc16b.1655999715.git.aburgess@redhat.com \
--to=gdb-patches@sourceware.org \
--cc=aburgess@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox