]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commitdiff
gdb/testsuite: fix gdb.base/maint.exp odd test name
authorSimon Marchi <simon.marchi@efficios.com>
Fri, 20 Feb 2026 14:52:14 +0000 (09:52 -0500)
committerSimon Marchi <simon.marchi@efficios.com>
Fri, 20 Feb 2026 18:06:34 +0000 (13:06 -0500)
I noticed this odd test name:

    PASS: gdb.base/maint.exp: maint currently expandedinfo currently expandedline-table currently expandedwith currently expandedfilename currently expandedof currently expandedsymtab currently expandedthat currently expandedis currently expandednot

This is because the join TCL proc is misused.  It ends up joining all of
the words in

    "maint info line-table with filename of symtab that is not"

with the string

    " currently expanded"

when the intention was to concatenate.

Change it back to just a plain string.  We can have a debate over this,
but in my opinion it's more readable to have the plain string (even if
the line is a bit long) instead of building the test name by
concatenating parts.  It's also more grep-able.

Change-Id: I491eb6843deed1c1b6edf0ebf9161644f0894b5a
Approved-By: Tom de Vries <tdevries@suse.de>
gdb/testsuite/gdb.base/maint.exp

index d077dcd19a0e51090b04b01b2335ac31ca4fad07..c3de727a740f1dc5736455ca1be9f7d026045510 100644 (file)
@@ -473,9 +473,7 @@ gdb_test "maint info line-table ${srcfile}" \
 
 if { ! $readnow_p } {
     gdb_test_no_output "maint info line-table ${srcfile2}" \
-       [join \
-            "maint info line-table with filename of symtab that is not" \
-            " currently expanded"]
+       "maint info line-table with filename of symtab that is not currently expanded"
 }
 
 gdb_test_no_output "maint expand-symtabs"