From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on inbox.vuxu.org X-Spam-Level: X-Spam-Status: No, score=-3.4 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED, T_SCC_BODY_TEXT_LINE,UNPARSEABLE_RELAY autolearn=ham autolearn_force=no version=3.4.4 Received: (qmail 32506 invoked from network); 7 Feb 2022 12:59:31 -0000 Received: from zero.zsh.org (2a02:898:31:0:48:4558:7a:7368) by inbox.vuxu.org with ESMTPUTF8; 7 Feb 2022 12:59:31 -0000 ARC-Seal: i=1; cv=none; a=rsa-sha256; d=zsh.org; s=rsa-20210803; t=1644238771; b=ZtMzM23Yg4317Her4Br7sT4yfYbmE+nQY6YS9vv3ZEYSOI9KB9NdFflwGxrxUdpTSh4OY3lmB/ UVM/3JMDLhY1eyh2YNx27i0s+7G+qCU5GdQlJSrSc/czx17qPXZuz+9c86OjSpsZz3IMq3r1hb PEq4OYev+gfwVrrir+9ga+AWn+kixo441ZHwBrCSaJmsO8fS16VfppesVlOr0ydnJEEbw3LFDX ElFb8i/7NtN2d9qqcN3k/odriS+3m6MsYWNskLyVcNd0TrTYfEW7HAgwfxnGpbdZMGk9clajTs Kjob11hCfLWtVyz1WnH8B3fSe0mw1qB/ojN3rLHfBHM8aQ==; ARC-Authentication-Results: i=1; zsh.org; iprev=pass (smtpq2.tb.ukmail.iss.as9143.net) smtp.remote-ip=212.54.57.97; dkim=pass header.d=ntlworld.com header.s=meg.feb2017 header.a=rsa-sha256; dmarc=pass header.from=ntlworld.com; arc=none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed; d=zsh.org; s=rsa-20210803; t=1644238771; bh=ByQdj86xMtUTFrYq80fyFVLzahz+vTx6MXMJlkNPPgk=; h=List-Archive:List-Owner:List-Post:List-Unsubscribe:List-Subscribe:List-Help: List-Id:Sender:Content-Transfer-Encoding:Content-Type:MIME-Version:Subject: References:In-Reply-To:Message-ID:To:From:Date:DKIM-Signature: DKIM-Signature; b=NCJSgh+VOlhZGoQj/25RvV0jW70xglYmUHSn6Hlvpkmh8tDWDCCqXATGVqo7jisfCdb/2k7Sgv xPVkmr56fpHYXsTsrStMHcEHwpP0w2Wt8obhG9fispKe7vSrfFP4UMZwneMu19I4EXOMUPiOjD PM90M4DsZlpcCPpkVToZiJavKF1E9GKcYFOpF3cnQKt5LbaCS8xd1UaZZnCz90Vu8JE+qH2grN ltrnXQ8qGrxhEvvTh8iJc4O+kttvShSapAYXX/wB3rlj1L3EEZOeuzqHOQ2qODlPRiZfRPLiDm 6WzkRFUxTDIxwptQB3Fo+EICW4ZivbuGHAcUEVuPdpoMgw==; DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=zsh.org; s=rsa-20210803; h=List-Archive:List-Owner:List-Post:List-Unsubscribe: List-Subscribe:List-Help:List-Id:Sender:Content-Transfer-Encoding: Content-Type:MIME-Version:Subject:References:In-Reply-To:Message-ID:To:From: Date:Reply-To:Cc:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID; bh=w6leTG7SWAoqdcBbqA9o1lSSjX4ua3Gmax+3RnSV0KI=; b=X2rjg3q/BIkOcULdaIaT4mWH6j jO7O0UOHZTOEI3m9K0yP6VtLlS8lUPz+plpTilq3HYm9TgGxyetw7TnAjIRH+p0mf/vvnW8eTeIV6 iMnGdotJQcZDdxQm4KlwtTaobeo5gcHR441TNhIgTEmV5htTdrhuK819QEOJZM+KDOakLqOHC853B WfK5VeZj59BGO7xEV/+SC2+yaDP4PudqBEF9qZBZPDQJu32KF3/pfWunBOp2XTGYZSVeL4YrUfae4 OlyziTEbnd8Md4IuHFZBiz9Y6R3BADS6fTyXOn/2Y5gx2ZuH9qgG+x0WilRk1+3uRDnXFQNHqHfc1 1iIhYsJA==; Received: from authenticated user by zero.zsh.org with local id 1nH3cB-00033l-7e; Mon, 07 Feb 2022 12:59:31 +0000 Authentication-Results: zsh.org; iprev=pass (smtpq2.tb.ukmail.iss.as9143.net) smtp.remote-ip=212.54.57.97; dkim=pass header.d=ntlworld.com header.s=meg.feb2017 header.a=rsa-sha256; dmarc=pass header.from=ntlworld.com; arc=none Received: from smtpq2.tb.ukmail.iss.as9143.net ([212.54.57.97]:36798) by zero.zsh.org with esmtps (TLS1.2:ECDHE-RSA-AES256-GCM-SHA384:256) id 1nH3bt-0002iI-Qk; Mon, 07 Feb 2022 12:59:14 +0000 Received: from [212.54.57.82] (helo=smtp3.tb.ukmail.iss.as9143.net) by smtpq2.tb.ukmail.iss.as9143.net with esmtp (Exim 4.90_1) (envelope-from ) id 1nH3bs-00086u-GG for zsh-workers@zsh.org; Mon, 07 Feb 2022 13:59:12 +0100 Received: from oxbe3.tb.ukmail.iss.as9143.net ([172.25.160.134]) by smtp3.tb.ukmail.iss.as9143.net with ESMTP id H3bsnLXHrlejnH3bsn6Tc3; Mon, 07 Feb 2022 13:59:12 +0100 X-Env-Mailfrom: p.w.stephenson@ntlworld.com X-Env-Rcptto: zsh-workers@zsh.org X-SourceIP: 172.25.160.134 X-CNFS-Analysis: v=2.4 cv=LMt1/ba9 c=1 sm=1 tr=0 ts=620117a0 cx=a_exe a=rX2mKgs1IZJU9lF6pltyEQ==:117 a=I_Av47A-8eYA:10 a=IkcTkHD0fZMA:10 a=vinPr5In5y8A:10 a=NLZqzBF-AAAA:8 a=Rr6fL3rrA6O4HWt_H0wA:9 a=QEXdDO2ut3YA:10 a=wW_WBVUImv98JQXhvVPZ:22 X-Authenticated-Sender: p.w.stephenson@ntlworld.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ntlworld.com; s=meg.feb2017; t=1644238752; bh=ByQdj86xMtUTFrYq80fyFVLzahz+vTx6MXMJlkNPPgk=; h=Date:From:To:In-Reply-To:References:Subject; b=wqxCMD/29exP55uzmn2LPGSU9rmTYRGrcR2vVWRRfWkc0+LYvW/NYXpNpAXIAd1EX ZMBT+4ym6g5Anx3LxMSsWxzoPz0teu2ubY7EJ6AH++vCvPrFD23FOhBMF8WdqwvdJ1 TnU8HYD2vCGUEQShyVZwN+M24YylHLn1jDtB9oq2Aup+zkAox0Jzf5ECHfC3fZAB0q EP1oOAbeFp6PNvcJe28S4Yqcn1TACrA+2SUGGS6ZqbjP93Qi8E/rfGxOy/TRpVPZfq 4PBRC6Hr4js6QTt5InTtvMkMYX87yZbhOiydHpxKLDhcmll/Vo/CygHCwim7NOQ9tx 3wyhyevKK5PQA== Date: Mon, 7 Feb 2022 12:59:12 +0000 (GMT) From: Peter Stephenson To: zsh workers Message-ID: <884256764.581141.1644238752224@mail2.virginmedia.com> In-Reply-To: <1692212664.579212.1644236144924@mail2.virginmedia.com> References: <20220206084255.tn3dgitvpr7qdjig@chazelas.org> <1071890479.577225.1644233454174@mail2.virginmedia.com> <1692212664.579212.1644236144924@mail2.virginmedia.com> Subject: Re: clarification on (#U) in pattern matching. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Priority: 3 Importance: Medium X-Mailer: Open-Xchange Mailer v7.8.4-Rev72 X-Originating-IP: 165.225.17.146 X-Originating-Client: open-xchange-appsuite X-CMAE-Envelope: MS4xfAtKPIzrhYBJRj1BSVt8HfzQNGhru8L2PGHbxPUVkL8DzLRhJa5OD5SzipfBjMTV0sNGVkaoHNtAETbFn0LBhpwLl9d+lpoUmejXfFTyglGzkAw1ns9R 6l949BoDMaMOr3Q9nWH/SKp0UXQ8A2Zcy4OL3HFSW+W/A2nw3t0+cQaicCyqK6nVlOt4i2cR1nur8M9gblXfOuXDwOzckKSR3NxkyVIOgPxU6VbOA1eN3CVS X-Seq: 49747 Archived-At: X-Loop: zsh-workers@zsh.org Errors-To: zsh-workers-owner@zsh.org Precedence: list Precedence: bulk Sender: zsh-workers-request@zsh.org X-no-archive: yes List-Id: List-Help: List-Subscribe: List-Unsubscribe: List-Post: List-Owner: List-Archive: On 07 February 2022 at 12:15 Peter Stephenson wrote: > I think there might be a parameter matching flag that you can > also set that would help. I'd have to look in more detail. On examination, no, I don't think there is an option at the parameter level, as opposed to the pattern match level --- and I appreciate that this distinction, while clear in the code, isn't likely to be so obvious to a user staring at shell code, even if parameter substitution and pattern matching are documented separately. The doc for parameters simplify refers to the MULTIBYTE option. There's a limited feature to turn off multibyte counting when calculating widths for use in padding etc. I suppose in principle that could be extended for pattern matching, but in practice (at least without a major rewrite) all it would do is turn off the multibyte option locally --- probably carrying over into pattern matching, so you'd at least get consistency between the two that way round. There isn't a sane way to propagate the (U) flag out of the pattern code back up into the parameter level. pws