Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Tom Tromey <tom@tromey.com>
To: Keith Seitz <keiths@redhat.com>
Cc: Tom Tromey <tom@tromey.com>,  gdb-patches@sourceware.org
Subject: Re: [RFA 3/4] Remove TYPE_TAG_NAME
Date: Wed, 18 Apr 2018 17:57:00 -0000	[thread overview]
Message-ID: <8736zs9z3o.fsf@tromey.com> (raw)
In-Reply-To: <072a09ed-40a3-4e15-2a67-54ac58d1f82a@redhat.com> (Keith Seitz's	message of "Wed, 18 Apr 2018 09:57:55 -0700")

>>>>> "Keith" == Keith Seitz <keiths@redhat.com> writes:

>> +      /* If we have "typedef struct foo {. . .} bar;" do we want to
>> +	 print it as "struct foo" or as "bar"?  Pick the latter for
>> +	 C++, because C++ folk tend to expect things like "class5
>> +	 *foo" rather than "struct class5 *foo".  */
>> +      if (language == language_c || language == language_minimal)

Keith> I'm almost afraid to ask, but why was language_minimal necessary here?
Keith> A small comment might be appropriate?
Keith> [I think I can already guess the heinous reason...] Do you know if
Keith> there is a test case that specifically covers this block with
Keith> language_minimal?

I think in this case, I added language_minimal on the theory that it is
"C-like".  I don't think there's a test case.

I can add a comment, and a test case wouldn't be too hard either.

Keith> Good riddance! I never did understand the "except by poorly
Keith> designed C++ code" comment.

Haha, me neither.  I always considered it a critique of some other code
elsewhere in gdb (perhaps long since removed) but who knows.

>> gdb_test "ptype \$structreg" \
>> "type = struct struct1 {\r\n *v4int8 v4;\r\n *v2int16 v2;\r\n}"

Keith> <rhetorical>Was the tag name never printed until now?</rhetorical> Wow!

Maybe I should have investigated this one more deeply?
I dunno.  The change seemed to make sense to me so I just moved on.

Tom


  reply	other threads:[~2018-04-18 17:57 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-04-17 19:51 [RFA 0/4] " Tom Tromey
2018-04-17 19:51 ` [RFA 3/4] " Tom Tromey
2018-04-18 16:57   ` Keith Seitz
2018-04-18 17:57     ` Tom Tromey [this message]
2018-04-18 18:06       ` Keith Seitz
2018-05-31  2:35   ` Joel Brobecker
2018-04-17 19:51 ` [RFA 2/4] Thread language through c_type_print_args Tom Tromey
2018-04-18 17:53   ` Tom Tromey
2018-05-31  1:37   ` Joel Brobecker
2018-04-17 19:51 ` [RFA 4/4] Remove type_name_no_tag and rename type_name_no_tag_or_error Tom Tromey
2018-05-31  6:22   ` Joel Brobecker
2018-04-17 19:51 ` [RFA 1/4] Make c_type_print_varspec_suffix static Tom Tromey
2018-05-31  1:33   ` Joel Brobecker
2018-04-18 16:57 ` [RFA 0/4] Remove TYPE_TAG_NAME Keith Seitz
2018-05-09 15:42 ` Tom Tromey
2018-05-25 17:30   ` 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=8736zs9z3o.fsf@tromey.com \
    --to=tom@tromey.com \
    --cc=gdb-patches@sourceware.org \
    --cc=keiths@redhat.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