aboutsummaryrefslogtreecommitdiff
path: root/gdb/tui/tui-stack.c
diff options
context:
space:
mode:
authorTom Tromey <tom@tromey.com>2019-11-13 16:33:21 -0700
committerTom Tromey <tom@tromey.com>2019-12-20 09:15:58 -0700
commiteb390f499b820b74e0ab07162b0b8bd12da6f35a (patch)
treeae9837dcb8eb5a3eb7f5b13e8f840f2c496620cc /gdb/tui/tui-stack.c
parentfc9d2d724fcc30b66308ae31d3de98e977d27a76 (diff)
downloadfsf-binutils-gdb-eb390f499b820b74e0ab07162b0b8bd12da6f35a.zip
fsf-binutils-gdb-eb390f499b820b74e0ab07162b0b8bd12da6f35a.tar.gz
fsf-binutils-gdb-eb390f499b820b74e0ab07162b0b8bd12da6f35a.tar.bz2
Change tui_show_frame_info to return bool
This changes tui_show_frame_info to return bool. gdb/ChangeLog 2019-12-20 Tom Tromey <tom@tromey.com> * tui/tui-stack.h (tui_show_frame_info): Return bool. * tui/tui-stack.c (tui_show_frame_info): Return bool. * tui/tui-hooks.c (tui_refresh_frame_and_register_information): Update. Change-Id: Id1374f04f919c30a9f50c1beeb70cbc10b9a8f3b
Diffstat (limited to 'gdb/tui/tui-stack.c')
-rw-r--r--gdb/tui/tui-stack.c16
1 files changed, 7 insertions, 9 deletions
diff --git a/gdb/tui/tui-stack.c b/gdb/tui/tui-stack.c
index d244343..3f606cb 100644
--- a/gdb/tui/tui-stack.c
+++ b/gdb/tui/tui-stack.c
@@ -301,10 +301,10 @@ tui_update_locator_fullname (struct symtab *symtab)
/* Function to print the frame information for the TUI. The windows are
refreshed only if frame information has changed since the last refresh.
- Return 1 if frame information has changed (and windows subsequently
- refreshed), 0 otherwise. */
+ Return true if frame information has changed (and windows
+ subsequently refreshed), false otherwise. */
-int
+bool
tui_show_frame_info (struct frame_info *fi)
{
bool locator_changed_p;
@@ -329,15 +329,13 @@ tui_show_frame_info (struct frame_info *fi)
not changed. If frame information has not changed, then the windows'
contents will not change. So don't bother refreshing the windows. */
if (!locator_changed_p)
- return 0;
+ return false;
for (struct tui_source_window_base *win_info : tui_source_windows ())
{
win_info->maybe_update (fi, sal);
win_info->update_exec_info ();
}
-
- return 1;
}
else
{
@@ -346,13 +344,13 @@ tui_show_frame_info (struct frame_info *fi)
locator_changed_p = locator->set_locator_info (NULL, sal, "");
if (!locator_changed_p)
- return 0;
+ return false;
for (struct tui_source_window_base *win_info : tui_source_windows ())
win_info->erase_source_content ();
-
- return 1;
}
+
+ return true;
}
void