]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commitdiff
Rename two maint commands
authorTom Tromey <tom@tromey.com>
Sun, 5 Jan 2025 22:20:50 +0000 (15:20 -0700)
committerTom Tromey <tom@tromey.com>
Wed, 8 Jan 2025 00:17:56 +0000 (17:17 -0700)
This renames two maint commands, removing a hyphen from
"check-symtabs" and "check-psymtabs"; that is, moving them under the
existing "maint check" prefix.

Regression tested on x86-64 Fedora 40.

Reviewed-By: Tom de Vries <tdevries@suse.de>
Approved-By: Andrew Burgess <aburgess@redhat.com>
Reviewed-By: Eli Zaretskii <eliz@gnu.org>
gdb/NEWS
gdb/doc/gdb.texinfo
gdb/psymtab.c
gdb/symmisc.c
gdb/testsuite/gdb.ada/maint_with_ada.exp
gdb/testsuite/gdb.base/check-psymtab.exp
gdb/testsuite/gdb.base/maint.exp

index 941b29e072d9b2634f2bab5f0d8739ac839e95c2..1b218c40a23e620f1b5e8ecea5b4e7efdbedd057 100644 (file)
--- a/gdb/NEWS
+++ b/gdb/NEWS
@@ -3,6 +3,14 @@
 
 *** Changes since GDB 16
 
+* New commands
+
+maintenance check psymtabs
+  Renamed from maintenance check-psymtabs
+
+maintenance check symtabs
+  Renamed from maintenance check-symtabs
+
 *** Changes in GDB 16
 
 * Support for Nios II targets has been removed as this architecture
index 5c16361610ca3482a62ef54dc6ef460df127a6cc..7bd760648500e6064558d6a321fec9fd6b2cfa75 100644 (file)
@@ -41602,13 +41602,13 @@ only if non-stop mode is active (@pxref{Non-Stop Mode}) and the target
 architecture supports displaced stepping.
 @end table
 
-@kindex maint check-psymtabs
-@item maint check-psymtabs
+@kindex maint check psymtabs
+@item maint check psymtabs
 Check the consistency of currently expanded psymtabs versus symtabs.
 Use this to check, for example, whether a symbol is in one but not the other.
 
-@kindex maint check-symtabs
-@item maint check-symtabs
+@kindex maint check symtabs
+@item maint check symtabs
 Check the consistency of currently expanded symtabs.
 
 @kindex maint expand-symtabs
index 309590d5d2659b95174f4d9e880eab9128213a88..e92125dae670dd09e6d65d4fff4ff02b3a104ebb 100644 (file)
@@ -1572,8 +1572,8 @@ This does not include information about individual partial symbols,\n\
 just the symbol table structures themselves."),
           &maintenanceinfolist);
 
-  add_cmd ("check-psymtabs", class_maintenance, maintenance_check_psymtabs,
+  add_cmd ("psymtabs", class_maintenance, maintenance_check_psymtabs,
           _("\
 Check consistency of currently expanded psymtabs versus symtabs."),
-          &maintenancelist);
+          &maintenancechecklist);
 }
index 616b1ce82d7a647dd3f6cecfbbd81915d9e7ddef..3f06cb11a340dc811d94b91222d3ea97b6c0f8ba 100644 (file)
@@ -838,7 +838,7 @@ maintenance_info_symtabs (const char *regexp, int from_tty)
    GDB assumes they are always non-NULL.
 
    Note: This does not check for psymtab vs symtab consistency.
-   Use "maint check-psymtabs" for that.  */
+   Use "maint check psymtabs" for that.  */
 
 static void
 maintenance_check_symtabs (const char *ignore, int from_tty)
@@ -1093,10 +1093,10 @@ With an argument REGEXP, list just the line tables for the symbol\n\
 tables with matching names."),
           &maintenanceinfolist);
 
-  add_cmd ("check-symtabs", class_maintenance, maintenance_check_symtabs,
+  add_cmd ("symtabs", class_maintenance, maintenance_check_symtabs,
           _("\
 Check consistency of currently expanded symtabs."),
-          &maintenancelist);
+          &maintenancechecklist);
 
   add_cmd ("expand-symtabs", class_maintenance, maintenance_expand_symtabs,
           _("Expand symbol tables.\n\
index 89c8c01c94ab729270c95a5f9b5d9fec1053a3bc..063213d33378deee58c42d90631126ea014e1deb 100644 (file)
@@ -26,7 +26,7 @@ if {[gdb_compile_ada "${srcfile}" "${binfile}" executable [list debug ]] != "" }
 clean_restart ${testfile}
 
 # Insert a breakpoint in each compilation unit, to force their psymtab's
-# expansion to a full symtab.  This will allow the check-psymtabs command
+# expansion to a full symtab.  This will allow the check psymtabs command
 # to perform a more extensive check regarding those units which are in
 # Ada.
 
@@ -34,6 +34,6 @@ gdb_breakpoint "adainit"
 gdb_breakpoint "Var_Arr_Typedef"
 gdb_breakpoint "Do_Nothing"
 
-gdb_test_no_output "maintenance check-psymtabs"
+gdb_test_no_output "maintenance check psymtabs"
 
-gdb_test_no_output "maintenance check-symtabs"
+gdb_test_no_output "maintenance check symtabs"
index 6ae211cdfe33b7dcf3647e0a37e72fc21cdd823c..43e232c3746fa9496bdcfca2cd30b77cca1d47d4 100644 (file)
@@ -23,4 +23,4 @@ gdb_test_no_output "maint expand-symtabs"
 
 # Check that we don't get:
 #   Static symbol `foo' only found in check-psymtab.c psymtab
-gdb_test_no_output "maint check-psymtab"
+gdb_test_no_output "maint check psymtab"
index 2c58ffa36c5c73159d7eafacdf0e82f0eded5436..9745076a71423e36429bac29a5c4fb95240fcc63 100644 (file)
@@ -20,8 +20,8 @@
 # source file used is break.c
 
 
-#maintenance check-psymtabs -- Check consistency of psymtabs vs symtabs
-#maintenance check-symtabs -- Check consistency of symtabs
+#maintenance check psymtabs -- Check consistency of psymtabs vs symtabs
+#maintenance check symtabs -- Check consistency of symtabs
 #maintenance expand-symtabs -- Expand symtabs matching a file regexp
 #maintenance set -- Set GDB internal variables used by the GDB maintainer
 #maintenance show -- Show GDB internal variables used by the GDB maintainer
@@ -156,8 +156,8 @@ set have_psyms [expr ! ( $have_gdb_index || $readnow_p )]
 # issues.
 
 set seen_command false
-gdb_test_multiple "maint check-psymtabs" "" {
-    -re "^maint check-psymtabs\r\n" {
+gdb_test_multiple "maint check psymtabs" "" {
+    -re "^maint check psymtabs\r\n" {
        set seen_command true
        exp_continue
     }
@@ -174,7 +174,7 @@ gdb_test_multiple "maint check-psymtabs" "" {
 # This command does not produce any output unless there is some problem
 # with the symtabs, so that branch will really never be covered in the
 # tests here!!
-gdb_test_no_output "maint check-symtabs"
+gdb_test_no_output "maint check symtabs"
 
 # Test per-command stats.
 gdb_test_no_output "maint set per-command on"