From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on inbox.vuxu.org X-Spam-Level: X-Spam-Status: No, score=-1.2 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,DKIM_VALID_EF,MAILING_LIST_MULTI,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.4 Received: from zero.zsh.org (zero.zsh.org [IPv6:2a02:898:31:0:48:4558:7a:7368]) by inbox.vuxu.org (Postfix) with ESMTP id C048129C25 for ; Sat, 9 Mar 2024 21:44:21 +0100 (CET) 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:Message-ID:Date:Content-ID: Content-Type:MIME-Version:Subject:To:References:From:In-reply-to:cc:Reply-To: Content-Transfer-Encoding:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID; bh=MzQv46SN5QSIeKFDdYUsnvlasVYSJumqkwJpQyVr49g=; b=cLbbIddWwq+brf20La+24yDdad DrF88D/fTIYbjnH12Rl1cq5kgRqPQ7z1ZgaWZhwmbdTXO7glmpOlrhU8uY7WasqZAMzbQN085WbLK qMfKK66Rbaha+dsKrA3ejD0p9WcQ5P/H2EoCiIgyToR6rSIlnLRZq0SPEOVA+zaphnh9x0m+VLdaq gabK50DnNhRSdrj3yriuNKzaKRIQoo54WFNk9jL8yj8VPtYfFOvpZTRLKV3g5WXkmWNPkDUElyqc4 DrdYXNj2ZQJvheGTwMNjUFKWvk2s6J8MJCSOWbWL9mVtBLMfRWnQkMahudN4UJavNqKkFNmi7mUj1 yKKIc7Bw==; Received: by zero.zsh.org with local id 1rj3YI-000FbH-Ri; Sat, 09 Mar 2024 20:44:18 +0000 Received: by zero.zsh.org with esmtpsa (TLS1.3:TLS_AES_256_GCM_SHA384:256) id 1rj3Y0-000FHn-3w; Sat, 09 Mar 2024 20:44:01 +0000 Received: from [192.168.178.21] (helo=hydra) by mail.kiddle.eu with esmtp(Exim 4.97.1) (envelope-from ) id 1rj3Xy-0000000092K-44Qo; Sat, 09 Mar 2024 21:43:59 +0100 cc: zsh-workers@zsh.org In-reply-to: From: Oliver Kiddle References: <20240305065606.ccr2ieheahslcpye@chazelas.org> <20240306175711.t3uz2sery3b6tbjw@chazelas.org> <90726-1709936102.086878@xlWC.oGpX.V4Q4> To: Bart Schaefer Subject: Re: [PATCH?] Nofork and removing newlines MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <34738.1710017038.1@hydra> Date: Sat, 09 Mar 2024 21:43:58 +0100 Message-ID: <34739-1710017038.959920@XhYc.enDL.DTxr> X-Seq: 52723 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: Bart Schaefer wrote: > See above about the requirement for it to look like ${|ident|...}. > Since = * and ? are not identifiers, this is like writing { =|: } etc. Ok, that makes sense. Thanks > and you get the same errors. All of the non-identifier special > parameters are read-only so it doesn't make sense to assign to them, > and the |ident| has to be assignable for the expansion to mean > anything, so why allow them in that position? Unless you're just going > for side-effects, but then why use the |var| form? You may not be able to assign to it directly but I can think of uses for $? (and perhaps also $!) if supported there. That is assuming $? is the return status for the command running inside the expansion. Being an identifier, $_ does work there, not that it's especially useful. $1, $2 etc also work. Oliver