public inbox for gdb-patches@sourceware.org
 help / color / mirror / Atom feed
From: Eli Zaretskii <eliz@gnu.org>
To: Enze Li <lienze2010@hotmail.com>
Cc: gdb-patches@sourceware.org
Subject: Re: [PATCH v3] gdb: Add new 'print nibbles' feature
Date: Wed, 25 Aug 2021 17:10:43 +0300	[thread overview]
Message-ID: <83bl5lvcm4.fsf@gnu.org> (raw)
In-Reply-To: <MEAP282MB02938CB231E57DF2E65DD48DDDC69@MEAP282MB0293.AUSP282.PROD.OUTLOOK.COM> (message from Enze Li via Gdb-patches on Wed, 25 Aug 2021 21:24:16 +0800)

> Date: Wed, 25 Aug 2021 21:24:16 +0800
> From: Enze Li via Gdb-patches <gdb-patches@sourceware.org>
> 
> Make an introduction of a new print setting that can be set by 'set
> print nibbles [on|off].  The default value is OFF, and it would be
> changed by users manually.
> 
> And of course, 'show print nibbles' is also included in the patch.
> 
> The new feature could display binary values in groups, and each group
> has four bits.

Thanks.

>   (gdb) print/t a
>   $3 = 100 1100 1110

Wouldn't it be better to show

    $3 = 0100 1100 1110

instead?

> --- a/gdb/NEWS
> +++ b/gdb/NEWS
> @@ -135,6 +135,11 @@ set debug event-loop
>  show debug event-loop
>    Control the display of debug output about GDB's event loop.
>  
> +set print nibbles [on|off]
> +show print nibbles
> +  This controls whether the 'print/t' command will display binary values
> +  in groups of four bits, known as "nibbles".  The default is 'off'.
> +

This part is OK.

> +@item -nibbles [@code{on}|@code{off}]
> +Set whether to print binary values in groups of four bits, known
> +as "nibbles". 
      ^^^^^^^^^
``nibbles'', please, to produce nicer quotes.

>                Related setting: @ref{set print nibbles}.

A lone "@ref" is seldom a good idea, except in the HTML output.
Suggest to say just @xref{set print nibbles}, without the "Related
setting" part.

> +@anchor{set print nibbles}
> +@item set print nibbles
> +@itemx set print nibbles on
> +Print binary values in groups of four bits, known as "nibbles",  when
                                                        ^^^^^^^^^
Here, I'd use @dfn{nibbles} instead of quotes, and add a @cindex for
"nibbles".

> +@item set print nibbles off
> +Stop printing binary values in groups.  This is the default.

I'd say "Don't" instead of "Stop".

Thanks.

  reply	other threads:[~2021-08-25 14:10 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-08-25 13:24 Enze Li
2021-08-25 14:10 ` Eli Zaretskii [this message]
2021-08-29  4:13   ` Enze Li
2021-08-27 18:18 ` Tom Tromey
2021-08-29  4:46   ` Enze Li

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=83bl5lvcm4.fsf@gnu.org \
    --to=eliz@gnu.org \
    --cc=gdb-patches@sourceware.org \
    --cc=lienze2010@hotmail.com \
    /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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).