Mailing-List: contact zsh-workers-help@zsh.org; run by ezmlm
Precedence: bulk
X-No-Archive: yes
List-Id: Zsh Workers List <zsh-workers.zsh.org>
List-Post: <mailto:zsh-workers@zsh.org>
List-Help: <mailto:zsh-workers-help@zsh.org>
X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on f.primenet.com.au
X-Spam-Level: 
X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=ham
	autolearn_force=no version=3.4.1
X-AuditID: cbfec7f4-f79026d00000418a-19-56d41d20cefc
Date: Mon, 29 Feb 2016 10:27:41 +0000
From: Peter Stephenson <p.stephenson@samsung.com>
To: Zsh hackers list <zsh-workers@zsh.org>
Subject: Re: Why zsh chose to be non-compliant in pattern matching
Message-id: <20160229102741.6c1d5518@pwslap01u.europe.root.pri>
In-reply-to:
 <CALS7p_ccvXTx4STR+kgbsC_QhV1Rrd_uMxYEu5-xCFAHzx5A-w@mail.gmail.com>
References:
 <CALS7p_eC1W57J671TP5GDpw4=N+__+w4b+a0Gkgaa3swKq76fA@mail.gmail.com>
 <CAH+w=7bZApGfDBA+1pGO8jrkWu0ioFDGpoYUsGQAWFN8sKMsPQ@mail.gmail.com>
 <CALS7p_ccvXTx4STR+kgbsC_QhV1Rrd_uMxYEu5-xCFAHzx5A-w@mail.gmail.com>
Organization: Samsung Cambridge Solution Centre
X-Mailer: Claws Mail 3.7.9 (GTK+ 2.22.0; i386-redhat-linux-gnu)
MIME-version: 1.0
Content-type: text/plain; charset=US-ASCII
Content-transfer-encoding: 7bit
X-Brightmail-Tracker:
 H4sIAAAAAAAAA+NgFrrILMWRmVeSWpSXmKPExsVy+t/xa7oKslfCDA49VLc42PyQyYHRY9XB
	D0wBjFFcNimpOZllqUX6dglcGQ83NjMXLOesaJzazd7AuIW9i5GTQ0LAROLF7AVQtpjEhXvr
	2boYuTiEBJYySjS9mcMM4cxgknj39h0LhHOOUeL50q1MEM5ZRollH96C9bMIqEq0TdjGBmKz
	CRhKTN00mxHEFhHQkthx8iQTiC0s4CTx9PlFsBpeAXuJg49/gtVwCgRL/Gh5CWYLCTxglGi/
	pQZi8wvoS1z9+4kJ4j57iZlXzjBC9ApK/Jh8jwXEZgaav3lbEyuELS+xec1bZog56hI37u5m
	n8AoPAtJyywkLbOQtCxgZF7FKJpamlxQnJSea6hXnJhbXJqXrpecn7uJERLQX3YwLj5mdYhR
	gINRiYf3heblMCHWxLLiytxDjBIczEoivEGSV8KEeFMSK6tSi/Lji0pzUosPMUpzsCiJ887d
	9T5ESCA9sSQ1OzW1ILUIJsvEwSnVwJjze/mO9U135Y6URDsLB+8oSJIMdtkxRWbGbhlm02v3
	T5hfSZ7K9n32Tf/1+zt7GNX31iz8OeuwzLvYWQe2eJ/y3ho36djdrSdLzt6OX69Zv/XTvxcn
	XlUddt4/SyKO70vR/2OnHZXmhXBOvWpm21XHH5gvZ7TT5Vz5dc+wos3fnSxVmjef0F6jxFKc
	kWioxVxUnAgAMJIeCGQCAAA=
X-Seq: zsh-workers 38047

On Mon, 29 Feb 2016 17:00:28 +0700
Cuong Manh Le <cuong.manhle.vn@gmail.com> wrote:
> The super user in U&L site post his opinion at
> http://unix.stackexchange.com/a/266394/38906
> 
> He said that the pattern matching spec is unspecified for quoted characters
> inside bracket expression. What is your opinion?

He's talking about the standard, which indeed doesn't say anything about
the subject.

[
    If an open bracket introduces a bracket expression as in XBD RE
    Bracket Expression, except that the <exclamation-mark> character (
    '!' ) shall replace the <circumflex> character ( '^' ) in its role
    in a non-matching list in the regular expression notation, it shall
    introduce a pattern bracket expression. A bracket expression
    starting with an unquoted <circumflex> character produces
    unspecified results. Otherwise, '[' shall match the character
    itself.

There's a reference there to regular expressions, for which only
backslash quoting is valid, as far as I'm aware.  Zsh has supported
that for quite a while.

I think it's more a question of current practice.  It's probably
widespread enough now to be standardisable.

pws

