Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: P modify in history event
- X-seq: zsh-workers 44914
- From: Peter Stephenson <p.stephenson@xxxxxxxxxxx>
- To: <zsh-workers@xxxxxxx>
- Subject: Re: P modify in history event
- Date: Tue, 19 Nov 2019 19:11:03 +0000
- Cms-type: 201P
- Dkim-filter: OpenDKIM Filter v2.11.0 mailout2.w1.samsung.com 20191119191104euoutp02a14159f25f04c020eda226b547c36610~YphGu8Zoc1220012200euoutp02o
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=samsung.com; s=mail20170921; t=1574190664; bh=dFP/hVMKS8zcYjWAKhemxkqdvSc8vZAIYrWnj6EZlCU=; h=Subject:From:To:Date:In-Reply-To:References:From; b=QhG78kxUdZbfSPfCdkwArFh1fuh+mv1ZqnOmID10NUEZ+G3AMkFYBQpuRy7dy2D1A wyOVvA7w6Bls95XvVTa+auj2YlKgUdQTcVQscIp56HJUZVGiQYSAlQFqR+902qPTkq ffhBaSo1GHkgeeo5q+Pd7aXRViCwARt2LM0g+QLM=
- In-reply-to: <f11ea64b-8415-4bbc-bd8c-f4d6342ce763@www.fastmail.com>
- List-help: <mailto:zsh-workers-help@zsh.org>
- List-id: Zsh Workers List <zsh-workers.zsh.org>
- List-post: <mailto:zsh-workers@zsh.org>
- List-unsubscribe: <mailto:zsh-workers-unsubscribe@zsh.org>
- Mailing-list: contact zsh-workers-help@xxxxxxx; run by ezmlm
- References: <CGME20191117184333epcas5p15bc1aa7b0f78182c3d1acc703f55d445@epcas5p1.samsung.com> <BEBF5AEC-185E-4887-98D7-4731E1D8F7B0@easesoftware.com> <1574070429.4551.2.camel@samsung.com> <d64df0bd-0ebb-4f5b-af63-cab62dfbd5fb@www.fastmail.com> <1574187661.6021.15.camel@samsung.com> <f11ea64b-8415-4bbc-bd8c-f4d6342ce763@www.fastmail.com>
On Tue, 2019-11-19 at 19:03 +0000, Daniel Shahaf wrote:
> Peter Stephenson wrote on Tue, 19 Nov 2019 18:21 +00:00:
> >
> > On Tue, 2019-11-19 at 18:00 +0000, Daniel Shahaf wrote:
> > >
> > > Can «zgetcwd()» return an empty string? If that's possible, the
> > > condition will be undefined behaviour («""[-1]»).
> > Not in a sane world, but there are cases where we can't work out the
> > current directory. I think we return "." then, in fact. But a bit of
> > safety probably wouldn't hurt --- applying [-1] to functions arguably
> > isn't top class style.
> How about this, then?
That looks sensible.
pws
Messages sorted by:
Reverse Date,
Date,
Thread,
Author