Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: workers/40626 (commit 6c476c22) causes multiple test failures
- X-seq: zsh-workers 40685
- From: Bart Schaefer <schaefer@xxxxxxxxxxxxxxxx>
- To: zsh-workers@xxxxxxx
- Subject: Re: workers/40626 (commit 6c476c22) causes multiple test failures
- Date: Wed, 1 Mar 2017 07:55:08 -0800
- Authentication-results: amavisd4.gkg.net (amavisd-new); dkim=pass (2048-bit key) header.d=brasslantern-com.20150623.gappssmtp.com
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=brasslantern-com.20150623.gappssmtp.com; s=20150623; h=from:message-id:date:in-reply-to:comments:references:to:subject :mime-version; bh=RrwsqJtwHd/Ealh6eq4YVy96IHqbMOoSdNvzNXoUt64=; b=MpuqoLq3dXURZoASs0l1XB2FaRJwiCA9ZD+VIDvccxf7CPGnrWos0L53BJBhRw0cRW pzv3yhol3kDlhM8iOVpJSdbTlhZC18pyqVN1bkmnF8OoU0k5wotl+S7kzCT62G3Ax5qO LhUXLBYPSTeLC6s8R65npMcuqTBi+HLFcq1oTTXHCldy4Guzyttqpx1+jMZ7Xi4Ijqny Mf7yroxxvDL1DryOLQyaSIdNPCiDGtfvDgvT+vfaq+l3pqwMHcZJhBLjF0n2WAfeFQmp +zIlpFCheA5AZfw9KVYEcCVy1XajEi635m8c/yqHfLSStyC/dte+k/D9OiT91P8yE1uR +zoA==
- In-reply-to: <20170228215110.GA15436@fujitsu.shahaf.local2>
- List-help: <mailto:zsh-workers-help@zsh.org>
- List-id: Zsh Workers List <zsh-workers.zsh.org>
- List-post: <mailto:zsh-workers@zsh.org>
- Mailing-list: contact zsh-workers-help@xxxxxxx; run by ezmlm
- References: <170225160455.ZM15040@torch.brasslantern.com> <20170226061620.GA3729@fujitsu.shahaf.local2> <170226114216.ZM4201@torch.brasslantern.com> <20170228074549.GA8753@fujitsu.shahaf.local2> <170228083855.ZM7434@torch.brasslantern.com> <20170228170329.GA9204@fujitsu.shahaf.local2> <170228110424.ZM7827@torch.brasslantern.com> <20170228215110.GA15436@fujitsu.shahaf.local2>
On Feb 28, 9:51pm, Daniel Shahaf wrote:
}
} I noticed that they're equivalent, but I think it's more readable to use
} += when setting values of some options and = when setting values of all
} options. That's because using = without specifying all options violates
} the following invariant of hashes:
}
} local -a a=(...)
} local -A hash=( $a )
} (( $#a == $#hash ))
I'm presuming you mean (( $#a == 2 * $#hash )) ... but that's not an
invariant in the first place.
local -a a=( a 1 b 2 a 3 b 4 )
local -A h=( $a )
Anwyay there are several special hashes that don't obey normal rules
for hashes (which is why they're special), but I will concede your
readability point.
Messages sorted by:
Reverse Date,
Date,
Thread,
Author