From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 8091 invoked from network); 28 Apr 2001 05:47:39 -0000 Received: from sunsite.dk (130.225.51.30) by ns1.primenet.com.au with SMTP; 28 Apr 2001 05:47:39 -0000 Received: (qmail 2838 invoked by alias); 28 Apr 2001 05:47:29 -0000 Mailing-List: contact zsh-users-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 3836 Received: (qmail 2823 invoked from network); 28 Apr 2001 05:47:29 -0000 From: "Bart Schaefer" Message-Id: <1010428054705.ZM27672@candle.brasslantern.com> Date: Sat, 28 Apr 2001 05:47:05 +0000 In-Reply-To: <20010428131937.A3925@exodus> Comments: In reply to Andre Pang "problem completing anything after directory/" (Apr 28, 1:19pm) References: <20010428131937.A3925@exodus> X-Mailer: Z-Mail (5.0.0 30July97) To: Andre Pang , zsh-users@sunsite.auc.dk Subject: Re: problem completing anything after directory/ MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii On Apr 28, 1:19pm, Andre Pang wrote: } } 13:11 /% cd usr/ } completing `directory' or `corrections' } } doesn't perform any completion whatsoever. } } zsh details: } } kshglob You've discovered a rather serious problem with the function compilation scheme, and it's a good thing someone found it before the 4.0.1 release. For those who haven't been following zsh-workers, some while back a new mechanism was introduced whereby zsh functions are "compiled" into a very compact internal coding so that they'll occupy less space and execute faster. One part of this compilation process is to pre-process glob patterns when they appear inside [[ ]] or in `case' labels, into the form used internally by the matching code, so that they don't have to be recomputed every time they're used. Unfortunately, zsh has options like kshglob that change the syntax of glob patterns. When the completion system functions are autoloaded with kshglob in effect, the meanings of some of those patterns is altered -- and is compiled into the function, so even though kshglob is later turned off by the completion system, the [[ ]] and `case' patterns retain their ksh interpretations and fail to work. This is going to be somewhat difficult to fix; a possibility is that the `zcompile -z' and `autoload -z' commands are going to have to be extended to disable kshglob as well as kshautoload when processing a "zsh style" function, and we may have to consider installing compiled rather than (or as well as) text versions of all the completion system code. But perhaps Sven and/or PWS, who are more familiar with the compilation and globbing code than I, can think of a way to have the run-time rather than compile-time setting of kshglob apply to those patterns, which would be the preferred solution. -- Bart Schaefer Brass Lantern Enterprises http://www.well.com/user/barts http://www.brasslantern.com Zsh: http://www.zsh.org | PHPerl Project: http://phperl.sourceforge.net