From: Junio C Hamano <gitster@pobox.com>
To: Thiago Farina <tfransosi@gmail.com>
Cc: Git Mailing List <git@vger.kernel.org>
Subject: Re: cmd_struct
Date: Wed, 13 May 2015 16:31:46 -0700 [thread overview]
Message-ID: <xmqq617w9hr1.fsf@gitster.dls.corp.google.com> (raw)
In-Reply-To: <CAPc5daUF1SaCOqb0iEZ527q-CgQn3YyMSWufOsQx9Lo1+aUBrg@mail.gmail.com> (Junio C. Hamano's message of "Wed, 13 May 2015 16:24:14 -0700")
Junio C Hamano <gitster@pobox.com> writes:
> On Wed, May 13, 2015 at 4:10 PM, Thiago Farina <tfransosi@gmail.com> wrote:
>>
>> Would be too churn/noise (at this point) to rename cmd_struct to builtin_cmd?
>
> The name has served us well, I do not see a compelling reason to change it
> to anything else, and I suspect the name stayed unchanged because nobody
> else found such a reason, either.
>
> So... if you are unwilling to make a compelling case telling us why the current
> name does not work, I do not think it is likely that anybody finds such a change
> necessary, welcome, or even tolerable.
Having said that, I would agree that if I were writing git.c from
scratch today, I would have done
static struct builtin_cmd builtin_cmd[] = { ...
insead of the current
static struct cmd_struct commands[] = { ...
just because I think it makes more sense. But that reason suggests
it is a mere code churn of no value, after all these years.
"Because the non-POSIX non-ANSI-C platform I am porting for stomps
on the end-user program's namespace, and cmd_struct is one of the
victims" could be a reason that is better than "just because I think
it makes more sense", but even then, there would probably be a
better ways other than renaming the symbols in end-user code
(i.e. Git) to solve such a name clash.
next prev parent reply other threads:[~2015-05-13 23:31 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-05-13 23:10 cmd_struct Thiago Farina
2015-05-13 23:23 ` cmd_struct Jonathan Nieder
2015-05-13 23:24 ` cmd_struct Junio C Hamano
2015-05-13 23:31 ` Junio C Hamano [this message]
2015-05-14 7:49 ` cmd_struct Johannes Schindelin
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=xmqq617w9hr1.fsf@gitster.dls.corp.google.com \
--to=gitster@pobox.com \
--cc=git@vger.kernel.org \
--cc=tfransosi@gmail.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