From: Tom Tromey <tom@tromey.com>
To: gdb-patches@sourceware.org
Cc: Tom Tromey <tom@tromey.com>
Subject: [PATCH 0/5] Remove `...' and related forms of quoting from gdb
Date: Sat, 22 Aug 2026 14:30:02 -0600 [thread overview]
Message-ID: <20260822-no-backquotes-in-strings-v1-0-0b035ad036a3@tromey.com> (raw)
As part of my ongoing quoting-regularization quest
(https://sourceware.org/bugzilla/show_bug.cgi?id=34044), this changes
gdb and gdbserver to avoid `...' `...`, and ``...'' when quoting
output, preferring double quotes instead.
I wrote this by writing a short script using Pygments to find all
strings in the source using the back-quote character; then fixing all
the relevant ones.
I've also fixed up the test suite, though there are probably tests I
have missed, since I did this primarily by looking at regressions.
(The only exception being s390-multiarch.exp, which I found while
searching for a particular string.)
I think it would also be good to tackle '...' quoting, but I haven't
attempted that yet.
Regression tested on x86-64 Fedora 40.
Signed-off-by: Tom Tromey <tom@tromey.com>
---
Tom Tromey (5):
Change `...'-style quoting in gdbsupport
Change `...'-style quoting in gdbserver
Fix weird quoting in stap-probe.c
Change `...'-style quoting in gdb
Fix styling in a few messages
gdb/aarch64-linux-tdep.c | 2 +-
gdb/ada-lang.c | 19 ++++-----
gdb/ada-lex.l | 6 +--
gdb/alpha-tdep.c | 2 +-
gdb/arch-utils.c | 2 +-
gdb/arm-linux-tdep.c | 2 +-
gdb/async-event.c | 14 +++----
gdb/auto-load.c | 6 +--
gdb/ax-gdb.c | 46 +++++++++++-----------
gdb/breakpoint.c | 12 +++---
gdb/build-id.c | 4 +-
gdb/c-exp.y | 6 +--
gdb/c-lang.c | 2 +-
gdb/charset.c | 26 ++++++------
gdb/cli/cli-cmds.c | 4 +-
gdb/cli/cli-option.c | 2 +-
gdb/cli/cli-script.c | 10 ++---
gdb/corefile.c | 4 +-
gdb/corelow.c | 10 ++---
gdb/cp-namespace.c | 2 +-
gdb/d-exp.y | 2 +-
gdb/darwin-nat.c | 4 +-
gdb/dtrace-probe.c | 2 +-
gdb/dwarf2/expr.c | 2 +-
gdb/dwarf2/index-write.c | 10 ++---
gdb/dwarf2/line-header.c | 4 +-
gdb/dwarf2/loc.c | 8 ++--
gdb/dwarf2/macro.c | 12 +++---
gdb/eval.c | 6 +--
gdb/exec.c | 6 +--
gdb/filesystem.c | 14 +++----
gdb/findvar.c | 10 ++---
gdb/gdb-demangle.c | 2 +-
gdb/gnu-nat.c | 10 ++---
gdb/gnu-v3-abi.c | 4 +-
gdb/go-exp.y | 4 +-
gdb/go32-nat.c | 8 ++--
gdb/guile/guile.c | 2 +-
gdb/i386-fbsd-tdep.c | 4 +-
gdb/i386-linux-tdep.c | 4 +-
gdb/i386-tdep.c | 6 +--
gdb/ia64-tdep.c | 6 +--
gdb/infcmd.c | 12 +++---
gdb/infrun.c | 2 +-
gdb/interps.c | 2 +-
gdb/language.c | 2 +-
gdb/m2-lang.c | 2 +-
gdb/machoread.c | 8 ++--
gdb/macrocmd.c | 20 +++++-----
gdb/macroexp.c | 4 +-
gdb/macroscope.c | 2 +-
gdb/macrotab.c | 6 +--
gdb/main.c | 10 ++---
gdb/maint.c | 2 +-
gdb/mi/mi-main.c | 2 +-
gdb/mips-tdep.c | 4 +-
gdb/objfiles.c | 4 +-
gdb/p-exp.y | 2 +-
gdb/parse.c | 4 +-
gdb/ppc-linux-tdep.c | 2 +-
gdb/printcmd.c | 6 +--
gdb/probe.c | 6 +--
gdb/python/py-breakpoint.c | 26 ++++++------
gdb/python/py-finishbreakpoint.c | 4 +-
gdb/python/py-infthread.c | 4 +-
gdb/python/python.c | 12 +++---
gdb/remote-fileio.c | 2 +-
gdb/remote.c | 14 +++----
gdb/riscv-tdep.c | 2 +-
gdb/solib-aix.c | 2 +-
gdb/solib-darwin.c | 2 +-
gdb/solib-rocm.c | 12 +++---
gdb/solib.c | 12 +++---
gdb/source.c | 6 +--
gdb/stack.c | 6 +--
gdb/stap-probe.c | 38 +++++++++---------
gdb/symfile.c | 28 ++++++-------
gdb/symtab.c | 18 ++++-----
gdb/target.c | 14 +++----
gdb/testsuite/gdb.ada/bp_c_mixed_case.exp | 4 +-
gdb/testsuite/gdb.ada/catch_ex.exp | 4 +-
gdb/testsuite/gdb.ada/catch_ex_std.exp | 2 +-
gdb/testsuite/gdb.ada/excep_handle.exp | 6 +--
gdb/testsuite/gdb.ada/limited-length.exp | 2 +-
gdb/testsuite/gdb.ada/literals.exp | 2 +-
gdb/testsuite/gdb.ada/mi_catch_ex.exp | 2 +-
gdb/testsuite/gdb.ada/mi_catch_ex_hand.exp | 2 +-
gdb/testsuite/gdb.ada/mi_ex_cond.exp | 4 +-
.../gdb.arch/amd64-stap-optional-prefix.exp | 4 +-
gdb/testsuite/gdb.arch/amd64-stap-wrong-subexp.exp | 2 +-
gdb/testsuite/gdb.arch/s390-multiarch.exp | 2 +-
gdb/testsuite/gdb.base/attach.exp | 6 +--
gdb/testsuite/gdb.base/break-unload-file.exp | 2 +-
gdb/testsuite/gdb.base/cached-source-file.exp | 2 +-
gdb/testsuite/gdb.base/define.exp | 4 +-
gdb/testsuite/gdb.base/exprs.exp | 4 +-
gdb/testsuite/gdb.base/gdb-index-err.exp | 8 ++--
gdb/testsuite/gdb.base/help.exp | 4 +-
gdb/testsuite/gdb.base/info-macros.exp | 4 +-
gdb/testsuite/gdb.base/jump-inline.exp | 2 +-
gdb/testsuite/gdb.base/jump.exp | 4 +-
gdb/testsuite/gdb.base/macscp.exp | 20 +++++-----
gdb/testsuite/gdb.base/maint-info-sections.exp | 4 +-
gdb/testsuite/gdb.base/new-ui.exp | 2 +-
gdb/testsuite/gdb.base/options.exp | 4 +-
gdb/testsuite/gdb.base/settings.exp | 4 +-
gdb/testsuite/gdb.base/subst.exp | 28 ++++++-------
gdb/testsuite/gdb.base/tls-nothreads.exp | 4 +-
gdb/testsuite/gdb.base/watch_thread_num.exp | 2 +-
gdb/testsuite/gdb.base/watchpoint.exp | 20 +++++-----
gdb/testsuite/gdb.cp/maint.exp | 2 +-
gdb/testsuite/gdb.cp/namespace-enum.exp | 2 +-
gdb/testsuite/gdb.cp/overload.exp | 2 +-
gdb/testsuite/gdb.dlang/expression.exp | 2 +-
gdb/testsuite/gdb.dwarf2/macro-complaints.exp | 10 ++---
gdb/testsuite/gdb.server/bkpt-other-inferior.exp | 2 +-
gdb/testsuite/gdb.server/no-thread-db.exp | 2 +-
gdb/testsuite/gdb.server/server-exec-info.exp | 2 +-
gdb/testsuite/gdb.server/target-exec-file.exp | 2 +-
gdb/testsuite/gdb.threads/gcore-stale-thread.exp | 2 +-
gdb/testsuite/gdb.trace/actions.exp | 2 +-
gdb/testsuite/lib/gdb.exp | 2 +-
gdb/thread.c | 4 +-
gdb/tracefile-tfile.c | 2 +-
gdb/tracefile.c | 2 +-
gdb/tracepoint.c | 10 ++---
gdb/tui/tui-win.c | 2 +-
gdb/tui/tui-winsource.c | 8 ++--
gdb/utils.c | 8 ++--
gdb/valarith.c | 2 +-
gdb/valops.c | 10 ++---
gdb/value.c | 2 +-
gdb/windows-nat.c | 5 ++-
gdb/xml-syscall.c | 8 +++-
gdb/z80-tdep.c | 10 ++---
gdbserver/thread-db.cc | 4 +-
gdbserver/tracepoint.cc | 12 +++---
gdbsupport/agent.cc | 2 +-
gdbsupport/event-loop.cc | 4 +-
gdbsupport/format.cc | 4 +-
140 files changed, 458 insertions(+), 452 deletions(-)
---
base-commit: d2102b0d6a95ba3b37204976fb3f6ebd935822fb
change-id: 20260822-no-backquotes-in-strings-65517420b3b1
Best regards,
--
Tom Tromey <tom@tromey.com>
next reply other threads:[~2026-08-22 20:30 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-08-22 20:30 Tom Tromey [this message]
2026-08-22 20:30 ` [PATCH 1/5] Change `...'-style quoting in gdbsupport Tom Tromey
2026-08-22 20:30 ` [PATCH 2/5] Change `...'-style quoting in gdbserver Tom Tromey
2026-08-22 20:30 ` [PATCH 3/5] Fix weird quoting in stap-probe.c Tom Tromey
2026-08-23 4:31 ` Eli Zaretskii
2026-08-24 18:09 ` Tom de Vries
2026-08-22 20:30 ` [PATCH 4/5] Change `...'-style quoting in gdb Tom Tromey
2026-08-22 20:30 ` [PATCH 5/5] Fix styling in a few messages Tom Tromey
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20260822-no-backquotes-in-strings-v1-0-0b035ad036a3@tromey.com \
--to=tom@tromey.com \
--cc=gdb-patches@sourceware.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox