[v2,13/14] Rename show_registers -> set_register_group

Message ID 20240120-tui-regs-cleanup-v2-13-a3cccc6a3573@tromey.com
State New
Headers
Series Cleanups for the TUi register window |

Checks

Context Check Description
linaro-tcwg-bot/tcwg_gdb_build--master-aarch64 success Testing passed
linaro-tcwg-bot/tcwg_gdb_build--master-arm success Testing passed
linaro-tcwg-bot/tcwg_gdb_check--master-aarch64 success Testing passed
linaro-tcwg-bot/tcwg_gdb_check--master-arm success Testing passed

Commit Message

Tom Tromey Jan. 20, 2024, 6:23 p.m. UTC
  This renames a method on the TUI register window to reflect its real
purpose.

Tested-By: Tom de Vries <tdevries@suse.de>
Reviewed-By: Andrew Burgess <aburgess@redhat.com>
---
 gdb/tui/tui-regs.c | 6 +++---
 gdb/tui/tui-regs.h | 2 +-
 2 files changed, 4 insertions(+), 4 deletions(-)
  

Patch

diff --git a/gdb/tui/tui-regs.c b/gdb/tui/tui-regs.c
index 10d9bc6ef7d..fa4d10d1039 100644
--- a/gdb/tui/tui-regs.c
+++ b/gdb/tui/tui-regs.c
@@ -164,7 +164,7 @@  tui_data_window::first_reg_element_no_inline (int line_no) const
 /* Show the registers of the given group in the data window
    and refresh the window.  */
 void
-tui_data_window::show_registers (const reggroup *group)
+tui_data_window::set_register_group (const reggroup *group)
 {
   update_register_data (group);
   rerender ();
@@ -404,7 +404,7 @@  void
 tui_data_window::check_register_values (frame_info_ptr frame)
 {
   if (m_regs_content.empty ())
-    show_registers (m_current_group);
+    set_register_group (m_current_group);
   else
     {
       for (tui_register_info &data_item_win : m_regs_content)
@@ -542,7 +542,7 @@  tui_reg_command (const char *args, int from_tty)
       if (match == NULL)
 	error (_("unknown register group '%s'"), args);
 
-      TUI_DATA_WIN->show_registers (match);
+      TUI_DATA_WIN->set_register_group (match);
     }
   else
     {
diff --git a/gdb/tui/tui-regs.h b/gdb/tui/tui-regs.h
index 880f360bec6..caa9d395bec 100644
--- a/gdb/tui/tui-regs.h
+++ b/gdb/tui/tui-regs.h
@@ -76,7 +76,7 @@  struct tui_data_window : public tui_win_info
 
   void check_register_values (frame_info_ptr frame);
 
-  void show_registers (const reggroup *group);
+  void set_register_group (const reggroup *group);
 
   const reggroup *get_current_group () const
   {