From: Tom Tromey <tom@tromey.com>
To: Tom de Vries <tdevries@suse.de>
Cc: gdb-patches@sourceware.org, Tom Tromey <tom@tromey.com>
Subject: Re: [PATCH 1/4] [gdb/tui] Remove default entries in TUI translation tables
Date: Fri, 23 Jun 2023 14:28:05 -0600 [thread overview]
Message-ID: <87fs6h2aay.fsf@tromey.com> (raw)
In-Reply-To: <20230623111536.1623-1-tdevries@suse.de> (Tom de Vries's message of "Fri, 23 Jun 2023 13:15:33 +0200")
>>>>> Tom de Vries <tdevries@suse.de> writes:
> The TUI translation tables contain default entries at the end:
> ...
> static struct tui_translate tui_border_kind_translate_hline[] = {
> { "space", ' ' },
> { "ascii", '-' },
> { "acs", -1 },
> { 0, 0 },
> { "ascii", '-' }
> };
> ...
> A simpler way of implementing this would be to to declare the first (or last)
> entry the default, but in fact these default entries are not used.
> Make this explicit by removing the default entries, and asserting in translate
> that an entry will always be found.
Looks good to me.
Tom
prev parent reply other threads:[~2023-06-23 20:28 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-06-23 11:15 Tom de Vries
2023-06-23 11:15 ` [PATCH 2/4] [gdb/tui] Introduce translate_acs Tom de Vries
2023-06-23 20:28 ` Tom Tromey
2023-06-23 11:15 ` [PATCH 3/4] [gdb/tui] Merge tui border-kind corner translation tables Tom de Vries
2023-06-23 20:30 ` Tom Tromey
2023-06-23 11:15 ` [PATCH 4/4] [gdb/tui] Make translate return entry->value instead of entry Tom de Vries
2023-06-23 20:30 ` Tom Tromey
2023-06-23 20:28 ` Tom Tromey [this message]
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=87fs6h2aay.fsf@tromey.com \
--to=tom@tromey.com \
--cc=gdb-patches@sourceware.org \
--cc=tdevries@suse.de \
/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).