From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 29722 invoked from network); 12 Apr 2005 15:17:45 -0000 Received: from news.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.88) by ns1.primenet.com.au with SMTP; 12 Apr 2005 15:17:45 -0000 Received: (qmail 14037 invoked from network); 12 Apr 2005 15:17:39 -0000 Received: from sunsite.dk (130.225.247.90) by a.mx.sunsite.dk with SMTP; 12 Apr 2005 15:17:39 -0000 Received: (qmail 4342 invoked by alias); 12 Apr 2005 15:17:29 -0000 Mailing-List: contact zsh-users-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 8672 Received: (qmail 4328 invoked from network); 12 Apr 2005 15:17:28 -0000 Received: from news.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.88) by sunsite.dk with SMTP; 12 Apr 2005 15:17:28 -0000 Received: (qmail 12902 invoked from network); 12 Apr 2005 15:17:28 -0000 Received: from vms040pub.verizon.net (206.46.252.40) by a.mx.sunsite.dk with SMTP; 12 Apr 2005 15:17:16 -0000 Received: from candle.brasslantern.com ([4.11.1.68]) by vms040.mailsrvcs.net (Sun Java System Messaging Server 6.2 HotFix 0.04 (built Dec 24 2004)) with ESMTPA id <0IEU004DQAGQZU13@vms040.mailsrvcs.net> for zsh-users@sunsite.dk; Tue, 12 Apr 2005 10:17:15 -0500 (CDT) Received: from candle.brasslantern.com (IDENT:schaefer@localhost [127.0.0.1]) by candle.brasslantern.com (8.12.11/8.12.11) with ESMTP id j3CFHDvm028147 for ; Tue, 12 Apr 2005 08:17:13 -0700 Received: (from schaefer@localhost) by candle.brasslantern.com (8.12.11/8.12.11/Submit) id j3CFHDXe028146 for zsh-users@sunsite.dk; Tue, 12 Apr 2005 08:17:13 -0700 Date: Tue, 12 Apr 2005 15:17:12 +0000 From: Bart Schaefer Subject: Re: Real KSH93 is finally free software! In-reply-to: <29001.1113309527@csr.com> To: zsh-users mailing list Message-id: <1050412151712.ZM28145@candle.brasslantern.com> MIME-version: 1.0 X-Mailer: Z-Mail (5.0.0 30July97) Content-type: text/plain; charset=us-ascii References: <8764yswpbh.fsf@heresy.ainola.jyu.fi> <1050412053438.ZM27569@candle.brasslantern.com> <87r7hgqjnm.fsf@heresy.ainola.jyu.fi> <29001.1113309527@csr.com> Comments: In reply to Peter Stephenson "Re: Real KSH93 is finally free software!" (Apr 12, 1:38pm) X-Spam-Checker-Version: SpamAssassin 3.0.2 on a.mx.sunsite.dk X-Spam-Level: X-Spam-Status: No, score=-2.6 required=6.0 tests=AWL,BAYES_00 autolearn=ham version=3.0.2 X-Spam-Hits: -2.6 On Apr 12, 1:38pm, Peter Stephenson wrote: } } Juhapekka Tolvanen wrote: } > Bart Schaefer writes: } > } > > Sure; almost anything using namerefs or discipline functions. } > } > Are them difficult or impossible to implement? If not, when they are } > added to zsh? } } I don't think they're particularly tricky Actually they *are* particularly tricky, because of the way zsh's nested parameter expansion passes data around. Our first attempt to implement namerefs was what led to ${(P)var}. Discipline functions are ugly because in order to set them the parser has to implement the other missing bit of ksh syntax, which is namespaces as in ${foo.bar}. Zsh doesn't allow "." as a valid character in variable names and it's difficult to do so because the same identifier parser is used both inside and outside the braces; that is, if you make the most obvious change to enable ${foo.bar} then $foo.bar also parses as a single variable name rather than as ${foo}.bar, which will break large numbers of scripts. So the changes to implement both of these things go fairly deep into the most critical parts of the shell.