From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 14443 invoked from network); 2 Mar 2009 10:07:07 -0000 X-Spam-Checker-Version: SpamAssassin 3.2.5 (2008-06-10) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-1.7 required=5.0 tests=AWL,BAYES_00,MISSING_HEADERS autolearn=no version=3.2.5 Received: from news.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.88) by ns1.primenet.com.au with SMTP; 2 Mar 2009 10:07:07 -0000 Received-SPF: none (ns1.primenet.com.au: domain at sunsite.dk does not designate permitted sender hosts) Received: (qmail 26075 invoked from network); 2 Mar 2009 10:07:00 -0000 Received: from sunsite.dk (130.225.247.90) by a.mx.sunsite.dk with SMTP; 2 Mar 2009 10:07:00 -0000 Received: (qmail 464 invoked by alias); 2 Mar 2009 10:06:54 -0000 Mailing-List: contact zsh-workers-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 26659 Received: (qmail 447 invoked from network); 2 Mar 2009 10:06:52 -0000 Received: from bifrost.dotsrc.org (130.225.254.106) by sunsite.dk with SMTP; 2 Mar 2009 10:06:52 -0000 Received: from cluster-g.mailcontrol.com (cluster-g.mailcontrol.com [208.87.233.190]) by bifrost.dotsrc.org (Postfix) with ESMTPS id 821C48058F82 for ; Mon, 2 Mar 2009 11:06:47 +0100 (CET) Received: from cameurexb01.EUROPE.ROOT.PRI ([193.128.72.68]) by rly28g.srv.mailcontrol.com (MailControl) with ESMTP id n22A6hEE007402 for ; Mon, 2 Mar 2009 10:06:43 GMT Received: from news01 ([10.103.143.38]) by cameurexb01.EUROPE.ROOT.PRI with Microsoft SMTPSVC(6.0.3790.3959); Mon, 2 Mar 2009 10:06:42 +0000 Date: Mon, 2 Mar 2009 10:06:41 +0000 From: Peter Stephenson Cc: zsh-workers@sunsite.dk Subject: Re: PATCH: Error parsing $(...) Message-ID: <20090302100641.58879b39@news01> In-Reply-To: <090227083334.ZM24342@torch.brasslantern.com> References: <20090226094507.43cf3c16@gmail.com> <20090226225743.1b707d46@pws-pc> <20090227101941.5552f177@pws-pc> <090227083334.ZM24342@torch.brasslantern.com> Organization: CSR X-Mailer: Claws Mail 3.5.0 (GTK+ 2.12.8; i386-redhat-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-OriginalArrivalTime: 02 Mar 2009 10:06:42.0549 (UTC) FILETIME=[960C6A50:01C99B1E] X-Scanned-By: MailControl A_08_51_00 (www.mailcontrol.com) on 10.71.0.138 X-Virus-Scanned: ClamAV 0.92.1/9061/Mon Mar 2 10:28:18 2009 on bifrost X-Virus-Status: Clean On Fri, 27 Feb 2009 08:33:34 -0800 Bart Schaefer wrote: > This doesn't work properly with respect to NO_INTERACTIVECOMMENTS: > > schaefer<501> print $(echo XX > echo this # is not a comment > echo YY) > XX this YY > schaefer<502> allopt interactive > interactive on > interactivecomments off That behaviour hasn't changed, it's always worked that way. The bug was only that stuff after the '#' wasn't properly ignored. It's never been well defined whether the text of a "$(...)" was "interactive" in the sense meant. The bit that happens interactively is reading from "$(" until ")" is hit, during which the lexical analsyer isn't looking for comments because it know the "end of the current interactive line" (again, in some not very well defined sense) is after the ")". After that the string is stored internally and evaluated later. Anyway, it's probably too late to do it the other way now, but if someone wants to write a patch to clarify it they're welcome. -- Peter Stephenson Software Engineer CSR PLC, Churchill House, Cambridge Business Park, Cowley Road Cambridge, CB4 0WZ, UK Tel: +44 (0)1223 692070