From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 16764 invoked by alias); 30 Dec 2017 23:30:22 -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: List-Unsubscribe: X-Seq: 23039 Received: (qmail 15152 invoked by uid 1010); 30 Dec 2017 23:30:22 -0000 X-Qmail-Scanner-Diagnostics: from mta03.eastlink.ca by f.primenet.com.au (envelope-from , uid 7791) with qmail-scanner-2.11 (clamdscan: 0.99.2/21882. spamassassin: 3.4.1. Clear:RC:0(24.224.136.9):SA:0(-2.6/5.0):. Processed in 2.369232 secs); 30 Dec 2017 23:30:22 -0000 X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-2.6 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_LOW, SPF_PASS,T_RP_MATCHES_RCVD autolearn=ham autolearn_force=no version=3.4.1 X-Envelope-From: rayandrews@eastlink.ca X-Qmail-Scanner-Mime-Attachments: | X-Qmail-Scanner-Zip-Files: | MIME-version: 1.0 Content-transfer-encoding: 8BIT Content-type: text/plain; charset=utf-8; format=flowed X-Authority-Analysis: v=2.3 cv=OKgJIxSB c=1 sm=1 tr=0 a=RnRVsdTsRxS/hkU0yKjOWA==:117 a=RnRVsdTsRxS/hkU0yKjOWA==:17 a=IkcTkHD0fZMA:10 a=oVxo1Yf1ElbkfeqR2v4A:9 a=QEXdDO2ut3YA:10 X-EL-IP-NOAUTH: 24.207.101.9 Subject: Re: Can zsh `else` reserved keyword command be aliased and the lexem itself be repurposed as `fi` keyword command? To: zsh-users@zsh.org References: <71ef7896-39f8-66fe-f8f8-c7c81b11e2ce@culture-libre.org> <918acbfa-b637-1d13-816b-c6edee0afa5c@culture-libre.org> <81beaeae-6507-c961-b6fd-5831ba58e045@eastlink.ca> From: Ray Andrews Message-id: <0206889d-5088-4604-0f89-80ea23a7b43f@eastlink.ca> Date: Sat, 30 Dec 2017 15:00:14 -0800 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.5.0 In-reply-to: Content-language: en-CA On 30/12/17 02:06 PM, Bart Schaefer wrote: > > You really don't want to go there. > > If you're desperate to experience something like this, Heck no, not me, I'm just interested in the zen of the idea.  And you've already said enough for me to understand that some naive idea about a 'csh' mode is a nonstarter. Yabut, what about some sort of auto-ending of code structures? Even if parsing was by exactly the same non-csh method, would it not be possible to turn off the code checker and just sorta run until the tracks stop at which point the thing returns?     if [ something ]; then blah     elif [something_else]; then foo ... and it just stops there not worrying about the fact that 'fi' is missing. Or, does the zsh parsing system really forbid such a thing? True, it would know about the issue at the parse and before execution even begins, but could it not just 'presume' the 'fi'? Sorta like the fact that I should close the door after I leave, but it is possible for me to depart and leave the door open. Mind, this could only even theoretically apply to code that is missing closings at the very end of itself.  Maybe easier to imagine than to implement, and certainly rather strange.  Never mind, I'm just curious.