From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 22376 invoked by alias); 9 Feb 2012 18:22:16 -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: 30195 Received: (qmail 12670 invoked from network); 9 Feb 2012 18:22:15 -0000 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) 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 autolearn=ham version=3.3.2 Received-SPF: none (ns1.primenet.com.au: domain at brasslantern.com does not designate permitted sender hosts) MIME-Version: 1.0 In-Reply-To: References: <120209073732.ZM31309@torch.brasslantern.com> Date: Thu, 9 Feb 2012 10:22:08 -0800 Message-ID: Subject: Re: \## -> x when completing From: Bart Schaefer To: zsh workers Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Gm-Message-State: ALoCoQlHGRebzA47XiMI09Sw+ukVh5qeKnof1Ho6Un2JwTGEAqF/CNjarCWWA20Yame6e/RXncl1 On Thu, Feb 9, 2012 at 8:16 AM, Mikael Magnusson wrote: >> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0tokenize(tmp); >> - =A0 =A0 =A0 =A0 =A0 =A0 =A0 remnulargs(tmp); >> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0if (haswilds(tmp)) { >> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0if (is) >> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0tmp[llpl + gfl] =3D Star; >> + =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 remnulargs(tmp); >> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0if ((cp =3D patcompile(tmp, 0, NU= LL))) >> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0haspattern =3D 1; >> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0} > > This fix seems to work for me, I have barely tried anything but my > test case so far though :). cat \##g now works in an irclogs dir My new worry is that tokenize() might make the string *longer*, thus causing the Star to be inserted too far to the left.