Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: David Carlton <carlton@math.stanford.edu>
To: Daniel Jacobowitz <drow@mvista.com>
Cc: gdb-patches@sources.redhat.com
Subject: Re: [rfa] replace SYMBOL_SOURCE_NAME by SYMBOL_PRINT_NAME
Date: Wed, 05 Feb 2003 05:42:00 -0000	[thread overview]
Message-ID: <ro11y2n2sgw.fsf@jackfruit.Stanford.EDU> (raw)
In-Reply-To: <20030205030631.GA25425@nevyn.them.org>

On Tue, 4 Feb 2003 22:06:31 -0500, Daniel Jacobowitz <drow@mvista.com> said:
> On Tue, Feb 04, 2003 at 06:00:34PM -0800, David Carlton wrote:

>> Here's a patch to begin dealing with the issue.  It renames
>> SYMBOL_SOURCE_NAME to SYMBOL_PRINT_NAME and adds a comment making it
>> clear that it's only suitable for output.

> I still don't understand why you want to rename it.  Why not just
> clarify the comment?

Some reasons:

1) The current name is inaccurate.  Sometimes it gives the source name
   of the symbol in question, sometimes it doesn't.  Functions or
   macros should have accurate names: we shouldn't depend on people
   actually reading comments any more than we have to.

2) Some people seem to be under the impression that SYMBOL_SOURCE_NAME
   always gives the demangled name (if there is one); it was used that
   way in an e-mail thread a month or so ago, for example.  Such
   people might well use it incorrectly when working on GDB, unless
   the macro is actually removed.  It's the same theory as Andrew's
   adding 'deprecated' to the names of things he doesn't like.

3) No matter what happens to SYMBOL_SOURCE_NAME, it's definitely
   necessary to introduce a macro that actually gives the source code
   name of a symbol.  It'll be a lot easier to remember to use
   SYMBOL_NATURAL_NAME (or whatever we end up calling it) if there's
   not a macro around called SYMBOL_SOURCE_NAME to compete with it in
   our fallible memories.

David Carlton
carlton@math.stanford.edu


  reply	other threads:[~2003-02-05  5:42 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-02-05  2:00 David Carlton
2003-02-05  3:06 ` Daniel Jacobowitz
2003-02-05  5:42   ` David Carlton [this message]
2003-02-05 15:18     ` Andrew Cagney
2003-02-20  4:21 ` Elena Zannoni
2003-02-20 17:19   ` David Carlton

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=ro11y2n2sgw.fsf@jackfruit.Stanford.EDU \
    --to=carlton@math.stanford.edu \
    --cc=drow@mvista.com \
    --cc=gdb-patches@sources.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