From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 13675 invoked from network); 21 Sep 2006 17:27:45 -0000 X-Spam-Checker-Version: SpamAssassin 3.1.5 (2006-08-29) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-2.4 required=5.0 tests=AWL,BAYES_00, FORGED_RCVD_HELO autolearn=ham version=3.1.5 Received: from news.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.88) by ns1.primenet.com.au with SMTP; 21 Sep 2006 17:27:45 -0000 Received-SPF: none (ns1.primenet.com.au: domain at sunsite.dk does not designate permitted sender hosts) Received: (qmail 97585 invoked from network); 21 Sep 2006 17:27:39 -0000 Received: from sunsite.dk (130.225.247.90) by a.mx.sunsite.dk with SMTP; 21 Sep 2006 17:27:39 -0000 Received: (qmail 13042 invoked by alias); 21 Sep 2006 17:27:37 -0000 Mailing-List: contact zsh-workers-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 22755 Received: (qmail 13033 invoked from network); 21 Sep 2006 17:27:36 -0000 Received: from news.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.88) by sunsite.dk with SMTP; 21 Sep 2006 17:27:36 -0000 Received: (qmail 97282 invoked from network); 21 Sep 2006 17:27:36 -0000 Received: from cluster-c.mailcontrol.com (168.143.177.190) by a.mx.sunsite.dk with SMTP; 21 Sep 2006 17:27:34 -0000 Received: from cameurexb01.EUROPE.ROOT.PRI ([62.189.241.200]) by rly07c.srv.mailcontrol.com (MailControl) with ESMTP id k8LHPxkv027296 for ; Thu, 21 Sep 2006 18:27:19 +0100 Received: from news01.csr.com ([10.103.143.38]) by cameurexb01.EUROPE.ROOT.PRI with Microsoft SMTPSVC(6.0.3790.1830); Thu, 21 Sep 2006 18:22:25 +0100 Received: from news01.csr.com (localhost.localdomain [127.0.0.1]) by news01.csr.com (8.13.7/8.13.4) with ESMTP id k8LHMODE008779 for ; Thu, 21 Sep 2006 18:22:24 +0100 Received: from csr.com (pws@localhost) by news01.csr.com (8.13.7/8.13.7/Submit) with ESMTP id k8LHMOQ5008776 for ; Thu, 21 Sep 2006 18:22:24 +0100 Message-Id: <200609211722.k8LHMOQ5008776@news01.csr.com> X-Authentication-Warning: news01.csr.com: pws owned process doing -bs To: zsh-workers@sunsite.dk Subject: Re: PATCH: Re: Broken completion with UTF-8 description In-reply-to: <200609212104.23198.arvidjaar@newmail.ru> References: <200609171853.57050.arvidjaar@newmail.ru> <20060917201612.fe9933d5.p.w.stephenson@ntlworld.com> <200609212104.23198.arvidjaar@newmail.ru> Comments: In-reply-to Andrey Borzenkov message dated "Thu, 21 Sep 2006 21:04:17 +0400." Date: Thu, 21 Sep 2006 18:22:24 +0100 From: Peter Stephenson X-OriginalArrivalTime: 21 Sep 2006 17:22:25.0148 (UTC) FILETIME=[815DB3C0:01C6DDA2] Content-Type: text/plain MIME-Version: 1.0 X-Scanned-By: MailControl A-07-04-02 (www.mailcontrol.com) on 10.67.0.117 Andrey Borzenkov wrote: > How are matches sorted currently? Do we have another function doing collate > sort or completion simply sorts in numerical order? I am not sure if using > strpcmp is the right thing but this is the first I caught. Did you take a look at strbpcmp() in zle_tricky.c? > Please review as I am not sure is usage of ztrdup/zfree is right in this case > . It'll work, but the standard completion system trick seems to be to dupstring() and not worry about the temporary usage. You'll appreciate that it's not that easy to understand the completion code simply by looking at it, but I didn't see anything that looked obviously stupid. > +/* > + * FIXME this should be defined globally. I have to find other places > + * where it is used > + * */ > + > +#define INTERMATCH_GAP 2 Ah, I see you've found another undocumented magic number used without any indication. I found a few of those. -- Peter Stephenson Software Engineer CSR PLC, Churchill House, Cambridge Business Park, Cowley Road Cambridge, CB4 0WZ, UK Tel: +44 (0)1223 692070 To access the latest news from CSR copy this link into a web browser: http://www.csr.com/email_sig.php