Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: (r) flag on scalar
- X-seq: zsh-users 19987
- From: Mikael Magnusson <mikachu@xxxxxxxxx>
- To: Peter Stephenson <p.stephenson@xxxxxxxxxxx>
- Subject: Re: (r) flag on scalar
- Date: Mon, 9 Mar 2015 19:45:52 +0100
- Cc: zsh-user <zsh-users@xxxxxxx>
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=oW3gynxTNqKYA4kXkZy6xkDQZUankH9wNYMKbmhhXTo=; b=r6uK+QJp6yF6eg/fIXhIDUBYIU+HZYg2V0hoB4xNUWvWWT/pDloSM0LRb4jqVRWOV7 hmvk27tkS1ruptVdsU3/TMYKP5OIujdW4UTAkWwMsh856CnHICJCeEH+qeZHlePixYXm d2UDilSQO1iIRaaASRpOe2mgOt0nmQrKuPXrs+vQSe7GR4Q59AE+rIx2/oDRBWIaVOZx qMWssVgQCUOcTjMPn3PA+AOSdpwl6RBgCK2EoAuqRQblaozulGzxJ1EQd65oAhfmmLoy x/qPdu8IL+ktfJuJ+eVRHNA/5Z9aJlpliqnc8uuKXob5A4fpEDq7csumwzZwtUPSaFOZ aiRw==
- In-reply-to: <20150309090815.004678df@pwslap01u.europe.root.pri>
- List-help: <mailto:zsh-users-help@zsh.org>
- List-id: Zsh Users List <zsh-users.zsh.org>
- List-post: <mailto:zsh-users@zsh.org>
- Mailing-list: contact zsh-users-help@xxxxxxx; run by ezmlm
- References: <20150308233821.GB2746@localhost.localdomain> <150308195642.ZM11614@torch.brasslantern.com> <20150309090815.004678df@pwslap01u.europe.root.pri>
On Mon, Mar 9, 2015 at 10:08 AM, Peter Stephenson
<p.stephenson@xxxxxxxxxxx> wrote:
> On Sun, 8 Mar 2015 19:56:42 -0700
> Bart Schaefer <schaefer@xxxxxxxxxxxxxxxx> wrote:
>> The only thing not quite intuitive about this is that a wildcard (either
>> * or with extendedglob ?# ) at the end of the ending patterrn is not
>> considered part of the match for (r) but is part of the match for (R).
>> PWS's latest doc tweak still doesn't explicitly describe that.
>
> diff --git a/Doc/Zsh/params.yo b/Doc/Zsh/params.yo
> index 7b127bc..1b175b2 100644
> --- a/Doc/Zsh/params.yo
> +++ b/Doc/Zsh/params.yo
> @@ -197,7 +197,17 @@ example(string="abcdefghijklm"
> print ${string[+LPAR()r+RPAR()d?,+LPAR()r+RPAR()h?]})
>
> prints `tt(defghi)'. This is an obvious generalisation of the
> -rule for single-character matches.
> +rule for single-character matches. For a single subscript,
> +only a single character is referenced (not the range of chracters
characters*
--
Mikael Magnusson
Messages sorted by:
Reverse Date,
Date,
Thread,
Author