diff options
author | Tom Tromey <tom@tromey.com> | 2023-03-07 18:26:06 -0700 |
---|---|---|
committer | Tom Tromey <tom@tromey.com> | 2023-03-11 08:48:29 -0700 |
commit | ddc6677b170be399dfcc7d81325870ff022ba875 (patch) | |
tree | 1152a15de8b893033b69ee48da454a25c58a3f1a | |
parent | 82c5090c61ed2a4a6cd37e575ae66323e0a837f7 (diff) | |
download | gdb-ddc6677b170be399dfcc7d81325870ff022ba875.zip gdb-ddc6677b170be399dfcc7d81325870ff022ba875.tar.gz gdb-ddc6677b170be399dfcc7d81325870ff022ba875.tar.bz2 |
Change linetable_entry::is_stmt to bool
This changes linetable_entry::is_stmt to type bool, rather than
unsigned.
Approved-By: Simon Marchi <simon.marchi@efficios.com>
-rw-r--r-- | gdb/jit.c | 2 | ||||
-rw-r--r-- | gdb/record-btrace.c | 2 | ||||
-rw-r--r-- | gdb/symtab.h | 2 | ||||
-rw-r--r-- | gdb/xcoffread.c | 4 |
4 files changed, 5 insertions, 5 deletions
@@ -493,7 +493,7 @@ jit_symtab_line_mapping_add_impl (struct gdb_symbol_callbacks *cb, { stab->linetable->item[i].set_raw_pc ((CORE_ADDR) map[i].pc); stab->linetable->item[i].line = map[i].line; - stab->linetable->item[i].is_stmt = 1; + stab->linetable->item[i].is_stmt = true; } } diff --git a/gdb/record-btrace.c b/gdb/record-btrace.c index 5b6e33f..3e71c6c 100644 --- a/gdb/record-btrace.c +++ b/gdb/record-btrace.c @@ -738,7 +738,7 @@ btrace_find_line_range (CORE_ADDR pc) change was made I was unsure how to test this so chose to go with maintaining the existing experience. */ if ((lines[i].raw_pc () == pc) && (lines[i].line != 0) - && (lines[i].is_stmt == 1)) + && lines[i].is_stmt) range = btrace_line_range_add (range, lines[i].line); } diff --git a/gdb/symtab.h b/gdb/symtab.h index 9fc9527..005b64b 100644 --- a/gdb/symtab.h +++ b/gdb/symtab.h @@ -1575,7 +1575,7 @@ struct linetable_entry int line; /* True if this PC is a good location to place a breakpoint for LINE. */ - unsigned is_stmt : 1; + bool is_stmt : 1; /* True if this location is a good location to place a breakpoint after a function prologue. */ diff --git a/gdb/xcoffread.c b/gdb/xcoffread.c index 0642fb5..72c0a0d 100644 --- a/gdb/xcoffread.c +++ b/gdb/xcoffread.c @@ -422,7 +422,7 @@ arrange_linetable (std::vector<linetable_entry> &old_linetable) for (int ii = 0; ii < old_linetable.size (); ++ii) { - if (old_linetable[ii].is_stmt == 0) + if (!old_linetable[ii].is_stmt) continue; if (old_linetable[ii].line == 0) @@ -431,7 +431,7 @@ arrange_linetable (std::vector<linetable_entry> &old_linetable) fentries.emplace_back (); linetable_entry &e = fentries.back (); e.line = ii; - e.is_stmt = 1; + e.is_stmt = true; e.set_raw_pc (old_linetable[ii].raw_pc ()); } } |