From: Eli Zaretskii <eliz@gnu.org>
To: Andrew Burgess <aburgess@redhat.com>
Cc: gdb-patches@sourceware.org
Subject: Re: [PATCH 2/5] gdb/doc: fix some incorrect '@table @code' uses
Date: Tue, 13 Oct 2026 14:56:13 +0300 [thread overview]
Message-ID: <86y0c1g6g2.fsf@gnu.org> (raw)
In-Reply-To: <ff0d9c95b9cddf5caa8c61815b7ef55dd5ca2953.1791831032.git.aburgess@redhat.com> (message from Andrew Burgess on Mon, 12 Oct 2026 19:54:27 +0100)
> From: Andrew Burgess <aburgess@redhat.com>
> Cc: Andrew Burgess <aburgess@redhat.com>
> Date: Mon, 12 Oct 2026 19:54:27 +0100
>
> When we have something like this:
>
> @table @code
> @item blah
> This is the text.
> @end table
>
> Then the 'blah' text is formatted as '@code{blah}'. We have several
> places in the GDB docs where we use '@table @code' when there is a
> better alternative than @code.
>
> I also found a few places where we did something like:
>
> @table @code
> @item @code{blah}
> This is the text.
> @end table
>
> In this case the @code around 'blah' is unnecessary, as the table
> already applies @code formatting. In this case I've removed the
> formatting around the blah text.
>
> I also spotted this pattern:
>
> @table @code
> @item @var{blah}, some additional explanation.
> This is the text.
> @end table
>
> In this case 'blah' is formatted as @var and 'some additional
> explanation' is formatted as @code, when I think it is really just
> normal text. In this case I change the @code to @asis which will
> leave the additional text as-is, i.e. with no special formatting.
>
> I have not tried to check every @table in the docs. This patch mostly
> focused on @code to @kbd, though I did fix up a few other tables where
> it was obvious that something else should be applied. However, there
> are a lot of tables in the docs, my strategy was to basically spend no
> more than a second or two looking at a table, if it wasn't immediately
> obvious what change was needed then I left the table as @code. My
> hope is that this patch improves the quality of the docs.
> ---
> gdb/doc/gdb.texinfo | 622 ++++++++++++++++++++++----------------------
> gdb/doc/guile.texi | 6 +-
> gdb/doc/python.texi | 16 +-
> 3 files changed, 322 insertions(+), 322 deletions(-)
Thanks, this is okay. I have a comments:
> -@table @code
> +@table @asis
> @item @var{linenum}
> @itemx @var{filename}:@var{linenum}
> @itemx -line @var{linenum}
There's nothing wrong with having a @var inside @code, we do it in
many manuals all the time. The problem happens when there are words
in such a table which should neither be in @code nor in @var; but
there are no such cases here, AFAICT. OTOH, changing to @asis makes
the "@item -line" have the wrong typeface: it should be in @code.
So I would leave this case alone.
Approved-By: Eli Zaretskii <eliz@gnu.org>
next prev parent reply other threads:[~2026-10-13 11:56 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-10-12 18:54 [PATCH 0/5] gdb/doc: a series of doc clean ups Andrew Burgess
2026-10-12 18:54 ` [PATCH 1/5] gdb/doc: use (@value{GDBP}) for the prompt in examples Andrew Burgess
2026-10-13 11:43 ` Eli Zaretskii
2026-10-12 18:54 ` [PATCH 2/5] gdb/doc: fix some incorrect '@table @code' uses Andrew Burgess
2026-10-13 11:56 ` Eli Zaretskii [this message]
2026-10-12 18:54 ` [PATCH 3/5] gdb/doc: consistent formatting for on|off on @item lines Andrew Burgess
2026-10-13 11:33 ` Eli Zaretskii
2026-10-12 18:54 ` [PATCH 4/5] gdb/doc: make more use of @option{...} formatting Andrew Burgess
2026-10-13 12:00 ` Eli Zaretskii
2026-10-12 18:54 ` [PATCH 5/5] gdb/doc: more @command and @kbd Andrew Burgess
2026-10-13 11:43 ` Eli Zaretskii
2026-10-16 14:52 ` Andrew Burgess
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=86y0c1g6g2.fsf@gnu.org \
--to=eliz@gnu.org \
--cc=aburgess@redhat.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