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.3 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, MAILING_LIST_MULTI,NICE_REPLY_A,RCVD_IN_DNSWL_MED,UNPARSEABLE_RELAY autolearn=ham autolearn_force=no version=3.4.4 Received: (qmail 11519 invoked from network); 16 May 2021 18:26:19 -0000 Received: from zero.zsh.org (2a02:898:31:0:48:4558:7a:7368) by inbox.vuxu.org with ESMTPUTF8; 16 May 2021 18:26:19 -0000 ARC-Seal: i=1; cv=none; a=rsa-sha256; d=zsh.org; s=rsa-20200801; t=1621189580; b=zdR7LPdEii6veVXh/8xvZj0f3lff7ooCRhloKhLAbV+Qly2A+Ppi8T1XxrYJ6P8KaT02w6npBq X5dPDIUjphWL8QHNXu6uWI+449gbpGRnWY9L6r2ylaYTJy3zhNPWElOhtHxgiZYz5kRwFVI1i8 xKBcNelZ2f4vx7e5LeMhtPIgvN1DwWNEn9P6rPIercqdF6M60fydKZiCkoYe12ukwbosHWvZCC FZricMIxQ+pXThLc4aXE7OUuk5d1HbzbQ1yJ20dKCJ/fJ9+Z6T+9vushjFf2dDIj595mLsRTMl whEt29pbLJAKJbUJD6IeaIltrQ5Qe0nAdQCEC35ZVNl94A==; ARC-Authentication-Results: i=1; zsh.org; iprev=pass (lb1-smtp-cloud9.xs4all.net) smtp.remote-ip=194.109.24.22; dmarc=none header.from=inlv.org; arc=none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed; d=zsh.org; s=rsa-20200801; t=1621189580; bh=OwSotvjnhB7YZ1u/Fj+VIAFyCQi0mpuy3w5zu7f5Okk=; h=List-Archive:List-Owner:List-Post:List-Unsubscribe:List-Subscribe:List-Help: List-Id:Sender:Content-Transfer-Encoding:Content-Type:In-Reply-To: MIME-Version:Date:Message-ID:From:References:To:Subject:DKIM-Signature; b=ED6lv9V6q0fUfkYEt5QtpCBKQ/QUwdsdDEoy8GW6FA1T0TIR4jYFiPKQnEW0VfThzgwg6BI844 99+JSxww3RJ7ocg/yvm5UyDrVdEvuK8b7xdX/E8Si572psfpyVQqtRVz8/b7yK4AMNGU0ckcJM qljuEA2/2oaMjQd3x4XjRO7bn6TXM6fA5iQq7yWA+p8wVIUJfjF5yMycZ3DYtvddolHeRZ10yp hOuixCB8LpC5M0UILDMqM/zFaTJBnw92wxYIHAEPplq3NSJzNbYseN+DggWi0X2thiXJ+6dzue EqyMd3vw7zcxGs6O/5KGImUgwFFMFIxk21qkn+c5Vv4jlA==; DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=zsh.org; s=rsa-20200801; h=List-Archive:List-Owner:List-Post:List-Unsubscribe: List-Subscribe:List-Help:List-Id:Sender:Content-Transfer-Encoding: Content-Type:In-Reply-To:MIME-Version:Date:Message-ID:From:References:To: Subject:Reply-To:Cc:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID; bh=6cDbOjjs9EVFDIT6nUHnU8J2EAzZZAwkjGLAJ+TmC5E=; b=j26vnw1zgnHX5ElzgPqWsXa+p7 ioAKp/oBv5/igQFw2ESDhoCCInVtU25lEMF3+o14VEyNmImfaJ5hicPbGIhv89xwD2ooYPVt8v33z KfdvyhpjNx/iSCYmzXQKL+mACZ+S0Z3gh56wf9pwWRMu5iJYPsJJ/pOUSl7K4kPFsAVSAvna08l+3 +B9w5yS06BmbBEHnJyZp8bIsvmFBtgfOhbpOKRbBwfIhP7esToO+JQMGj7nfAe+wGEp+IsHIenOpR RBoxeP90Qh/h1DZWeWx5LEEdjCaacLx7djlSIzN6YqGseSLl0W+xrE83hHwKNFNiKTLcxifqAIHK1 lP26VnMQ==; Received: from authenticated user by zero.zsh.org with local id 1liLT1-0007Ff-TH; Sun, 16 May 2021 18:26:19 +0000 Authentication-Results: zsh.org; iprev=pass (lb1-smtp-cloud9.xs4all.net) smtp.remote-ip=194.109.24.22; dmarc=none header.from=inlv.org; arc=none Received: from lb1-smtp-cloud9.xs4all.net ([194.109.24.22]:54897) by zero.zsh.org with esmtps (TLS1.3:TLS_AES_256_GCM_SHA384:256) id 1liLS7-00062v-9R; Sun, 16 May 2021 18:25:23 +0000 Received: from cust-839a4cd3 ([IPv6:fc0c:c184:1742:62a6:ec35:71f7:b085:244]) by smtp-cloud9.xs4all.net with ESMTPA id iLS6lKfFEVN4kiLS7l10BX; Sun, 16 May 2021 20:25:23 +0200 Subject: Re: 'while do done' hangs interactive zsh To: zsh-workers@zsh.org References: <20210516164328.x7jnh3gfqfiidd7a@chazelas.org> From: Martijn Dekker Message-ID: Date: Sun, 16 May 2021 20:25:21 +0200 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.14; rv:78.0) Gecko/20100101 Thunderbird/78.10.1 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-GB Content-Transfer-Encoding: 7bit X-CMAE-Envelope: MS4xfOfhFEeUUs+xvn8Ix2cONE7sVtGlhV4OMqk54JVaeC66WSDbwlZ+HbUiK+sc/yp243Nllz7EPZLZdyxF3/isZEHzu9olAA3PjsR/OeucfsLhZty7v05h lsHJpucmQyZyEsNCXOKExUSW1toHgx9eyzI5TvxDrv9F0bbB3SmqGechWll8xjwj75VLJArh0RGHmaxtcrQzdM53ncgxMh57HbD0ctvPP1ih0fUGT5NK2W3J BAWSBBCx7xUFUm1e8WUOQQ== X-Seq: 48851 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: Op 16-05-21 om 20:02 schreef Bart Schaefer: > Bash requires at least one pipeline in the do-LIST as well. > > Is this worth making into an emulation-mode thing, i.e., adding a > couple of more conditions to my while-do-done patch? My understanding of the emulation mode is that it attempts to make the changes necessary to eliminate incompatibilities with the POSIX standard. This does not require disabling extensions that are compatible with it. The two empty command lists in 'while do done' are both straightforward syntax errors in POSIX, so the extension to allow them is not incompatible with the standard; there's no syntactic clash with the POSIX equivalent, 'while :; do :; done'. So I see no need for the emulation mode to disallow empty command lists. AFAIK there's only one shell with a POSIX mode that attempts to disallow (almost) everything not specified by the standard, and that's yash. -- || modernish -- harness the shell || https://github.com/modernish/modernish || || KornShell lives! || https://github.com/ksh93/ksh