From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Le Wang Newsgroups: gmane.emacs.devel Subject: Re: flx -- flex with better sorting Date: Thu, 2 May 2013 01:27:48 +0800 Message-ID: References: <87ip32ofdn.fsf@wanadoo.es> <87bo8uoclh.fsf@wanadoo.es> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: multipart/alternative; boundary=f46d043893cdcb2e2a04dbab6fe5 X-Trace: ger.gmane.org 1367429283 32519 80.91.229.3 (1 May 2013 17:28:03 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 1 May 2013 17:28:03 +0000 (UTC) Cc: emacs-devel@gnu.org To: =?ISO-8859-1?Q?=D3scar_Fuentes?= Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Wed May 01 19:28:02 2013 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1UXaou-0002fa-U8 for ged-emacs-devel@m.gmane.org; Wed, 01 May 2013 19:27:57 +0200 Original-Received: from localhost ([::1]:47542 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UXaou-0006g0-EQ for ged-emacs-devel@m.gmane.org; Wed, 01 May 2013 13:27:56 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:33214) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UXaop-0006f2-5W for emacs-devel@gnu.org; Wed, 01 May 2013 13:27:53 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UXaon-0008Lg-CI for emacs-devel@gnu.org; Wed, 01 May 2013 13:27:51 -0400 Original-Received: from mail-wg0-x233.google.com ([2a00:1450:400c:c00::233]:57037) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UXaon-0008La-23 for emacs-devel@gnu.org; Wed, 01 May 2013 13:27:49 -0400 Original-Received: by mail-wg0-f51.google.com with SMTP id b12so1604920wgh.30 for ; Wed, 01 May 2013 10:27:48 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:in-reply-to:references:date:message-id :subject:from:to:cc:content-type; bh=KbJRH/Vgo3BoIDhUwgapUe5WZdvsrCWzgMEz25mgXIg=; b=JVuG6ujoCzBWc649JXhw2qoAXkYUOzNyPRpU5IXl7i8I15yVQihuhtpfNebZ2i1xFE B7u3tQMBc1p16C+0LSIlDmedo+f0NtS0AJRqB+MWfFxep3BF1V5bXpYhQXpGlHyiyqNs FeQWJhu60SnaKmqkNrVqL50NHN2clxKNI8O+dS80DymXkfQEfZ94J5MWVu/TDWtu2Bca 2z48X72YpykbpdpEE9dvEL1HypbldgYCLjBsk0gXNUD0bnNiTZoCTge8cyt6RV++MISe xFoPscAQSUo7RPS7zEvYP6a564fuAqVkvkvfZWGGKA8IMyyf+lQqlUaDwcXAcApc/Qf9 phkA== X-Received: by 10.180.73.228 with SMTP id o4mr30743610wiv.12.1367429268317; Wed, 01 May 2013 10:27:48 -0700 (PDT) Original-Received: by 10.217.116.8 with HTTP; Wed, 1 May 2013 10:27:48 -0700 (PDT) In-Reply-To: <87bo8uoclh.fsf@wanadoo.es> X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2a00:1450:400c:c00::233 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:159248 Archived-At: --f46d043893cdcb2e2a04dbab6fe5 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable On Thu, May 2, 2013 at 1:04 AM, =D3scar Fuentes wrote: > Le Wang writes: > > >> 4. Sometimes it fails to work as advertised. For instance, if I type > >> `ltx' this file is shown first on the list of matches: > >> > >> lib/Target/NVPTX/NVPTXLowerAggrCopies.h > >> > >> but I would expect > >> > >> lib/Target/X86/* (* meaning any file under that subdirectory). > >> > > > > 1. The algorithm favors basepaths heavily. > > 2. I ended up considering all capitals to be beginning of word. > > > > This means ltx is matching as expected. As you supply more letters, > better > > results should float to the top. > > Okay. Knowing this makes for a much more effective usage. > > >> 5. Another quirk is that it rejects capital letters. For instance, if = I > >> type `lT' it shows no matches, but in fact there are lots of files > >> like this: > >> > >> lib/Target/... > >> > >> Actually, typing just `T' fails to find any candidate, but there are > >> lots files with a capital T on its name. > >> > > > > I hadn't considered people might do this. :-) Will fix soon. > > Ideally, when using capital letters those candidates that matched case > would get higher points. > I fixed this bug. Capital letters are considered word beginnings so they are always preferred. More quirks: > > C-s, C-r etc stops working on ido after enabling flx. > I opened a bug on github to track this. > > One Emacs instance started to quickly use memory and had to kill it when > noticed that the system was furiously paging. That Emacs instance was > doing nothing, just showing a prompt of 3 candidates for kill-buffer. > It'd be good to get repro steps for this. With ido, C-x k (kill-buffer) usually offers the current buffer as the > first candidate. After activating flx, that's not necessarily so. > The completion list should change until you hit the first letter. After that flx takes over sorting. Is this what you're seeing? > While navigating directory trees with find-file, at certain point no > candidates where listed as soon as any string was entered. With no > input, all candidates were shown. I was unable to replicate the problem. > I opened a bug on github to track this. But I don't actually use ido, so it may take some time to get around to this. Follow up in the bug if you have more repro details. Thanks. --=20 Le --f46d043893cdcb2e2a04dbab6fe5 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable

= On Thu, May 2, 2013 at 1:04 AM, =D3scar Fuentes <ofv@wanadoo.es> wrote:
Le Wang <l26wang@gmail.com> writes:

>> 4. Sometimes it fails to work as advertised. For instance, if I ty= pe
>> =A0 =A0`ltx' this file is shown first on the list of matches:<= br> >>
>> lib/Target/NVPTX/NVPTXLowerAggrCopies.h
>>
>> but I would expect
>>
>> lib/Target/X86/* (* meaning any file under that subdirectory).
>>
>
> 1. The algorithm favors basepaths heavily.
> 2. I ended up considering all capitals to be beginning of word.
>
> This means ltx is matching as expected. =A0As you supply more letters,= better
> results should float to the top.

Okay. Knowing this makes for a much more effective usage.

>> 5. Another quirk is that it rejects capital letters. For instance,= if I
>> =A0 =A0type `lT' it shows no matches, but in fact there are lo= ts of files
>> =A0 =A0like this:
>>
>> lib/Target/...
>>
>> Actually, typing just `T' fails to find any candidate, but the= re are
>> lots files with a capital T on its name.
>>
>
> I hadn't considered people might do this. =A0:-) =A0Will fix soon.=

Ideally, when using capital letters those candidates that matched cas= e
would get higher points.

I fixed = this bug. =A0Capital letters are considered word beginnings so they are alw= ays preferred.=A0

More quirks:

C-s, C-r etc stops working on ido after enabling flx.
=
I opened a bug on github to track this.=A0

One Emacs instance started to quickly use memory and had to kill it when noticed that the system was furiously paging. That Emacs instance was
doing nothing, just showing a prompt of 3 candidates for kill-buffer.

It'd be good to get repro steps fo= r this.

With ido, C-x k (kill-buffer) usually offers the current buffer as the
first candidate. After activating flx, that's not necessarily so.

The completion list should change unti= l you hit the first letter. =A0After that flx takes over sorting. =A0Is thi= s what you're seeing?
=A0
While navigating directory trees with find-file, at certain point no
candidates where listed as soon as any string was entered. With no
input, all candidates were shown. I was unable to replicate the problem.

I opened a bug on github to track this. =A0But=A0I d= on't actually use ido, so it may take some time to get around to this. = =A0Follow up in the bug if you have more repro details.

Thanks.

--
Le
--f46d043893cdcb2e2a04dbab6fe5--