Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
syntactic trivia
- X-seq: zsh-users 26292
- From: Ray Andrews <rayandrews@xxxxxxxxxxx>
- To: Zsh Users <zsh-users@xxxxxxx>
- Subject: syntactic trivia
- Date: Sat, 2 Jan 2021 06:57:32 -0800
- Archived-at: <https://zsh.org/users/26292>
- Archived-at: <http://www.zsh.org/sympa/arcsearch_id/zsh-users/2021-01/565cd2e7-c999-5735-4089-a56870713432%40eastlink.ca>
- List-id: <zsh-users.zsh.org>
[ "$case" = 'insensitive' ] && dirs=( (#i)$1*(/N) ) \
|| dirs=( $1*(/N) )
Since '(#i)' is a modifier of the globing would not this be more intuitive?:
dirs=( $1*(/N#i) )
Just to understand it, I'm wondering why case filtering would be
syntactically different from the other filters.
Speaking of intuition:
[ true ] && do-this\ # No comments here, please.
|| do-that
I wonder how much trouble allowing that would be. Probably written in
stone that it will never happen, still, it's an obvious exception and
I'd guess it would only take five minutes to code, the parser just
throws out any comment before throwing out the backslash and the
newline. A tiny luxury.
Messages sorted by:
Reverse Date,
Date,
Thread,
Author