From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Wanrong Lin Newsgroups: gmane.emacs.bugs Subject: bug#39484: 26.3; try-completion bug Date: Tue, 27 Oct 2020 16:44:25 -0400 Message-ID: <8fed8748-8331-5ca7-6c91-108c27945bb2@gmail.com> References: <874kmf1peq.fsf@gnus.org> <87361zbi5x.fsf@igel.home> <87h7qfzdf8.fsf@gnus.org> <87y2jr9zwt.fsf@igel.home> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="12189"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:68.0) Gecko/20100101 Thunderbird/68.12.1 Cc: Lars Ingebrigtsen , Stefan Monnier , 39484@debbugs.gnu.org To: Andreas Schwab Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Tue Oct 27 21:45:14 2020 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1kXVqD-00032z-7c for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 27 Oct 2020 21:45:13 +0100 Original-Received: from localhost ([::1]:33052 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kXVqC-000249-7w for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 27 Oct 2020 16:45:12 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:37996) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kXVq1-00023H-Un for bug-gnu-emacs@gnu.org; Tue, 27 Oct 2020 16:45:01 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:34539) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1kXVq1-00078Q-L1 for bug-gnu-emacs@gnu.org; Tue, 27 Oct 2020 16:45:01 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1kXVq1-0007N4-Iz for bug-gnu-emacs@gnu.org; Tue, 27 Oct 2020 16:45:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Wanrong Lin Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 27 Oct 2020 20:45:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 39484 X-GNU-PR-Package: emacs Original-Received: via spool by 39484-submit@debbugs.gnu.org id=B39484.160383147628287 (code B ref 39484); Tue, 27 Oct 2020 20:45:01 +0000 Original-Received: (at 39484) by debbugs.gnu.org; 27 Oct 2020 20:44:36 +0000 Original-Received: from localhost ([127.0.0.1]:46085 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kXVpc-0007MB-1i for submit@debbugs.gnu.org; Tue, 27 Oct 2020 16:44:36 -0400 Original-Received: from mail-pj1-f42.google.com ([209.85.216.42]:37354) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kXVpZ-0007Lw-CO for 39484@debbugs.gnu.org; Tue, 27 Oct 2020 16:44:34 -0400 Original-Received: by mail-pj1-f42.google.com with SMTP id lt2so1356162pjb.2 for <39484@debbugs.gnu.org>; Tue, 27 Oct 2020 13:44:33 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-transfer-encoding:content-language; bh=DNuL0CjKTyIpN8OWa2gHXHubKCUCIiw1Cyw7u3F70DY=; b=XpQPRPMSI13qAd89GBqZOVBQvF7RaIiunkHeYGOF1lxjOt44cDaUSQXDIVi4vUs5AL ADCoGR/C2LPbWFadNyLD/A6hXN4P3OhJoEVJQ+1ONZugLaZ8oO+MrOsSNJ4+v6WNtmJp R4T8CPzBJaIV4Ri3Dc5jtVJLXkZzXYpAIFdIWVNU7p+PXHDFEXB7q1FaZEcvh130UqTX vmVjf3OPhiYXFqlXgpaODeTXD8ZNils5FEXDf8NrhYpXPrPgnEXaczreUgIesXzpFclm pPASsPzpgln9gmajMb0uYyZYVFFLvlF14nARGjBakvL0CYvCB+VMB6AifmXWcJuyM1Pi W1Jg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-transfer-encoding :content-language; bh=DNuL0CjKTyIpN8OWa2gHXHubKCUCIiw1Cyw7u3F70DY=; b=oaIHqlczln/7Ke66rwBm8A1oaUdCIgE90U9ecWRzfB5TDlHnEyiQisCvJ5SW4qVYnK XRce7vBOPEOYKdCIfoq5voikCGa1cyznhis6MiYYbemsAmwrbuhoc9BDTmPt25HkTZP0 pL2QvC9jhDNCmy3YIV+dBfcUzBXSKPwD3SS+ZW2Iya7OfalVU2E7QRGLCHJIIZMoM4Ar 3SciOW6W7ceUDP/U4KRgdLmC56BXBkYKI9eREeAR2h/Ycys9yOcYYKfa5CeIYbKDdgq2 KFhQV3VUVSOldtSPR628iBoyhCvTZfB4S38nxjnIfRfzpkxMym4UFXMVdqDeUApG2NrM 6tww== X-Gm-Message-State: AOAM532PX8YE0wdQST9u7Q98yKAETshhmlSMQWYs86LPmixpzScxUUP0 2vHApJ/YlLIhWMZ4goo8BmQoDnEorEDP7g== X-Google-Smtp-Source: ABdhPJzsseTupaSqfkS7jJjFqy1PHrUmu0ufCHN6OlV3GBEWMDByRt7fp30qLxIDN3XMaDMWZ3zP8g== X-Received: by 2002:a17:90a:e615:: with SMTP id j21mr3661299pjy.66.1603831467223; Tue, 27 Oct 2020 13:44:27 -0700 (PDT) Original-Received: from [192.168.2.19] (c-71-226-226-185.hsd1.nj.comcast.net. [71.226.226.185]) by smtp.googlemail.com with ESMTPSA id 17sm3153556pfj.49.2020.10.27.13.44.26 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 27 Oct 2020 13:44:26 -0700 (PDT) In-Reply-To: <87y2jr9zwt.fsf@igel.home> Content-Language: en-US X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:191791 Archived-At: My understanding is: "ignoring case" here applies to the comparison part, not the returning part. What makes me think so: 1. That variable name is "completion-ignore-case", meaning, complete as much as possible ignoring case in comparison. But still, the action is to "complete", and "complete" should use the original candidate text when possible. 2.  the first example did return the original text in the candidate instead of the user input. (let ((completion-ignore-case t))        (try-completion "xy" '("XyzD" "XyzAbc"))        ) ==> "Xyz" I am not saying other behaviors are "wrong", but not ideal in my view, and there should be some rationale (performance?) behind it. Wanrong On 10/27/2020 4:28 PM, Andreas Schwab wrote: > On Okt 27 2020, Wanrong Lin wrote: > >> I remember this behavior gives me problem in "ido" trying to expand the >> user input to the max common matched text among all candidates, because >> as you can see, the "expansion" using this method may end up returning >> something that is not common at all for all the candidates. > It isn't? "xyz" surely is a common prefix of "XyzD" and "XyzAbc", > ignoring case. > > Andreas. >