From: Jonathan Nieder Date: Fri, 08 Jun 2018 21:52:07 GMT Subject: Re: [PATCH v2] completion: reduce overhead of clearing cached --options Message-ID: <20180608215207.GB42503@aiede.svl.corp.google.com> In-Reply-To: SZEDER Gábor wrote: > On Fri, Jun 8, 2018 at 11:23 PM, Jonathan Nieder wrote: >>> + [[ -z "${GIT_SOURCING_ZSH_COMPLETION}" ]] ; then >> >> Needs a - before the } to avoid errors in a shell where the user has >> chosen to use "set -u". See v1.7.4-rc0~159 (completion: fix zsh check >> under bash with 'set -u', 2010-10-27) for more details. > > Right... I did remember that, but by the time I finished typing out > that long variable name I forgot about it... :) > > However, I'm not sure it's worth caring about, because the > bash-competion scripts don't work with 'set -u' anyway... I'd be happy to see these '-'s go away (it would make the code both easier to read and easier to maintain), but as a post-2.18 topic, please. Alternatively, if there's a real need for them, I'd be happy to see the completion tests start using 'set -u'. Thanks, Jonathan