From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 20278 invoked by alias); 9 Mar 2015 18:46:07 -0000 Mailing-List: contact zsh-users-help@zsh.org; run by ezmlm Precedence: bulk X-No-Archive: yes List-Id: Zsh Users List List-Post: List-Help: X-Seq: 19987 Received: (qmail 13553 invoked from network); 9 Mar 2015 18:45:54 -0000 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FROM,RCVD_IN_DNSWL_LOW autolearn=ham version=3.3.2 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== MIME-Version: 1.0 X-Received: by 10.107.153.193 with SMTP id b184mr50941202ioe.85.1425926752428; Mon, 09 Mar 2015 11:45:52 -0700 (PDT) In-Reply-To: <20150309090815.004678df@pwslap01u.europe.root.pri> References: <20150308233821.GB2746@localhost.localdomain> <150308195642.ZM11614@torch.brasslantern.com> <20150309090815.004678df@pwslap01u.europe.root.pri> Date: Mon, 9 Mar 2015 19:45:52 +0100 Message-ID: Subject: Re: (r) flag on scalar From: Mikael Magnusson To: Peter Stephenson Cc: zsh-user Content-Type: text/plain; charset=UTF-8 On Mon, Mar 9, 2015 at 10:08 AM, Peter Stephenson wrote: > On Sun, 8 Mar 2015 19:56:42 -0700 > Bart Schaefer 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