From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 24242 invoked by alias); 10 Sep 2017 21:24:54 -0000 Mailing-List: contact zsh-workers-help@zsh.org; run by ezmlm Precedence: bulk X-No-Archive: yes List-Id: Zsh Workers List List-Post: List-Help: X-Seq: 41664 Received: (qmail 27308 invoked by uid 1010); 10 Sep 2017 21:24:54 -0000 X-Qmail-Scanner-Diagnostics: from mail-wm0-f52.google.com 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(74.125.82.52):SA:0(-1.9/5.0):. Processed in 1.494922 secs); 10 Sep 2017 21:24:54 -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=-1.9 required=5.0 tests=BAYES_00,FREEMAIL_FROM, RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H3,RCVD_IN_MSPIKE_WL,SPF_PASS, T_DKIM_INVALID autolearn=ham autolearn_force=no version=3.4.1 X-Envelope-From: s.seletskiy@gmail.com X-Qmail-Scanner-Mime-Attachments: | X-Qmail-Scanner-Zip-Files: | DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=019EafikwjP6D8aJB49CzQbX7XFu8ZGTFPZsZhLtBAk=; b=jf1AYRrkac3N7C420KaYJGjf2zLugs6SrxdVG+ZjGl16fh/zh83CNz2RLBTqchBkO7 gYcYO6biLYT4AK7NHYxOlp1rCyFNAINy9pG0MvJU2hOBPpqdtAVgdxhPC0cYm31rjL4S D2bhzStXFtr7wMeVjZMGKehp0xKUGa8mO/kxyeAYkWzvoUA5aPU41VAAjEvTP7toFEq8 KQYTg86o17QATc6mBNfxhSfLnNVrVPHZs+ggM5haDwVJzpFRtK4aPmgRrSK2MfDX5hDB /FbUTGgiKB/wvtGkMDtbhB4zNPz+nJgqvDVax3kebLf4R0dHnzfux3fC7RS/+8tX8AFz FHvw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=019EafikwjP6D8aJB49CzQbX7XFu8ZGTFPZsZhLtBAk=; b=oJsGUgHw2BJeB3qFCd8JcRgZFaF766deYrXcIpQpTqO8DRb+qI2rmQzsH0Z9wRrwz0 rieDfH+VIMtGoS4HWUEdNkL4pFgpoCo38rzxvRLKMJY5HkjRRkMXD5hHkmjrxb8fiA4m VX4s7G2Z0wOBAIw0xiYZ5m84pq/5nw72F9HGkhu6tBqesnsJvFNgU/mvStsz6XSnOZd8 137ce2/JXfOjYHgC6v4O9XDwwmFofM71fI1tHFty0/RK1CpJXfTODM7pCG2CIAxGbUpr YF8qMD7+RQOrOrhMV79pGsPz8B+fqzRrj1t7N/qXuBHBhqCja+EKuUeP94XRR9BRTpuz 0RwA== X-Gm-Message-State: AHPjjUjQMnWVwG5Lrpt8Frqqapb/MLHIcXceebzXu7h40hAXzi8QXzsS mII+67Yy5CksVVJ/ X-Google-Smtp-Source: ADKCNb5u2isYs+OkCOa1n3lJ4TplyI6yX0a9diBzUJi+p9KBeRPsJE5ookqWnOXIpkAnoCNnHMa4pw== X-Received: by 10.28.128.19 with SMTP id b19mr6065467wmd.136.1505078687892; Sun, 10 Sep 2017 14:24:47 -0700 (PDT) Date: Mon, 11 Sep 2017 00:24:44 +0300 From: Stanislav Seletskiy To: zsh-workers@zsh.org Subject: Re: Comment (# char) behavior in the sub-shell Message-ID: <20170910212442.GA16460@archlinux> References: <20170910210636.17bc0581@ntlworld.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20170910210636.17bc0581@ntlworld.com> User-Agent: Mutt/1.9.0 (2017-09-02) > I suspect this changed some versions ago now. At some point we changed > the way we handled $(...) to parse it better. Previously, we just > blindly treated it as a string when we first enountered it, reading it > in interactively until we got to a closing parenthesis. That wasn't > actually the right thing to do, and crucially it failed where there was > a case statement in the old syntax where a pattern only has a closing > parenthesis and not an opening parenthesis. So what we do now is parse > properly until the (right) closing parenthesis, but still store what we > parsed as a string for reading again when we execute the $(...). So, shouldn't it be fixed? It's very misleading, since for me as for user $(...) that I type in the shell is still interactive mode and should be treated in the same way.