git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
From: Felipe Contreras <felipe.contreras@gmail.com>
To: "Ævar Arnfjörð Bjarmason" <avarab@gmail.com>,
	"Junio C Hamano" <gitster@pobox.com>
Cc: Git List <git@vger.kernel.org>,
	Eric Sunshine <sunshine@sunshineco.com>,
	"brian m. carlson" <sandals@crustytoothpaste.net>
Subject: Re: [PATCH v2] CodingGuidelines: explicitly allow "local" for test scripts
Date: Tue, 04 May 2021 15:22:30 -0500	[thread overview]
Message-ID: <6091ad06cecb0_b34a8208bf@natae.notmuch> (raw)
In-Reply-To: <87a6pawmyu.fsf@evledraar.gmail.com>

Ævar Arnfjörð Bjarmason wrote:
> On Tue, May 04 2021, Junio C Hamano wrote:
> > Ævar Arnfjörð Bjarmason <avarab@gmail.com> writes:
> >
> >> It's effectively synonymous with saying "we still want to support git on
> >> platforms that are so broken they can't even run a single test in our
> >> test suite".
> >
> > Not really.  Those on such a platform would (rightly) say that it is
> > the test suite that is broken and out of compliance.
> 
> Indeed. But the lack of any reports about that suggests that in practice
> this is universally supported enough to be a hard dependency.

It is universally supported but not always in the same way, which is why
it hasn't managed to become part of POSIX.

I for example stumbled upon an issue where 'local x' does not work the
same in bash and zsh, triggering a huge discussion on the zsh mailing
list.

However, if you set a value (e.g. 'local x=') then you shouldn't have
any problems.

  f () { local x; echo ${x-unset}; }; f # this behavior varies

For a full discussion check [1].

[1] https://www.austingroupbugs.net/bug_view_page.php?bug_id=767

-- 
Felipe Contreras

  reply	other threads:[~2021-05-04 20:22 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-05-03  4:10 [PATCH] CodingGuidelines: explicitly allow "local" for test scripts Junio C Hamano
2021-05-03  4:21 ` Eric Sunshine
2021-05-03  5:21   ` Junio C Hamano
2021-05-03  5:23     ` [PATCH v2] " Junio C Hamano
2021-05-03  9:01       ` Ævar Arnfjörð Bjarmason
2021-05-04  3:01         ` Junio C Hamano
2021-05-04 12:27           ` Ævar Arnfjörð Bjarmason
2021-05-04 12:50             ` Junio C Hamano
2021-05-04 15:09               ` Ævar Arnfjörð Bjarmason
2021-05-04 20:22                 ` Felipe Contreras [this message]
2021-05-04 23:17                 ` brian m. carlson
2021-05-04 23:55                   ` Junio C Hamano
2021-05-05  0:08                   ` Felipe Contreras
2021-05-05  1:58                     ` brian m. carlson
2021-05-05  3:59                       ` Felipe Contreras
2021-05-05 14:16                         ` Jeff King
2021-05-05 17:18                           ` Felipe Contreras

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

  List information: http://vger.kernel.org/majordomo-info.html

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=6091ad06cecb0_b34a8208bf@natae.notmuch \
    --to=felipe.contreras@gmail.com \
    --cc=avarab@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.com \
    --cc=sandals@crustytoothpaste.net \
    --cc=sunshine@sunshineco.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.
Code repositories for project(s) associated with this public inbox

	https://80x24.org/mirrors/git.git

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).