From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.bugs Subject: bug#591: 23.0.60; lisp-complete-symbol erases extra text Date: Tue, 29 Jul 2008 18:07:57 -0400 Message-ID: References: <87ej5czaef.fsf@stupidchicken.com> Reply-To: Stefan Monnier , 591@emacsbugs.donarmstrong.com NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1217370463 30165 80.91.229.12 (29 Jul 2008 22:27:43 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 29 Jul 2008 22:27:43 +0000 (UTC) Cc: 591@emacsbugs.donarmstrong.com To: Chong Yidong Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Wed Jul 30 00:28:33 2008 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1KNxgC-0002Tx-Jf for geb-bug-gnu-emacs@m.gmane.org; Wed, 30 Jul 2008 00:28:29 +0200 Original-Received: from localhost ([127.0.0.1]:53500 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1KNxfH-00033U-W0 for geb-bug-gnu-emacs@m.gmane.org; Tue, 29 Jul 2008 18:27:32 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1KNxfC-00032E-Pd for bug-gnu-emacs@gnu.org; Tue, 29 Jul 2008 18:27:26 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1KNxfB-00031X-4k for bug-gnu-emacs@gnu.org; Tue, 29 Jul 2008 18:27:26 -0400 Original-Received: from [199.232.76.173] (port=37143 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1KNxfB-00031U-1Z for bug-gnu-emacs@gnu.org; Tue, 29 Jul 2008 18:27:25 -0400 Original-Received: from rzlab.ucr.edu ([138.23.92.77]:55879) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1KNxfA-00041p-MJ for bug-gnu-emacs@gnu.org; Tue, 29 Jul 2008 18:27:25 -0400 Original-Received: from rzlab.ucr.edu (rzlab.ucr.edu [127.0.0.1]) by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id m6TMRKBh005195; Tue, 29 Jul 2008 15:27:20 -0700 Original-Received: (from debbugs@localhost) by rzlab.ucr.edu (8.13.8/8.13.8/Submit) id m6TMF3k7001714; Tue, 29 Jul 2008 15:15:03 -0700 X-Loop: don@donarmstrong.com Resent-From: Stefan Monnier Resent-To: bug-submit-list@donarmstrong.com Resent-CC: Emacs Bugs Resent-Date: Tue, 29 Jul 2008 22:15:03 +0000 Resent-Message-ID: Resent-Sender: don@donarmstrong.com X-Emacs-PR-Message: report 591 X-Emacs-PR-Package: emacs X-Emacs-PR-Keywords: Original-Received: via spool by 591-submit@emacsbugs.donarmstrong.com id=B591.1217369293473 (code B ref 591); Tue, 29 Jul 2008 22:15:03 +0000 Original-Received: (at 591) by emacsbugs.donarmstrong.com; 29 Jul 2008 22:08:13 +0000 Original-Received: from ironport2-out.teksavvy.com (ironport2-out.pppoe.ca [206.248.154.182]) by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id m6TM88WU000467 for <591@emacsbugs.donarmstrong.com>; Tue, 29 Jul 2008 15:08:10 -0700 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: Ak0GAOowj0hFxIYw/2dsb2JhbACBW4lEpjaBdA X-IronPort-AV: E=Sophos;i="4.31,274,1215403200"; d="scan'208";a="24947370" Original-Received: from 69-196-134-48.dsl.teksavvy.com (HELO pastel.home) ([69.196.134.48]) by ironport2-out.teksavvy.com with ESMTP; 29 Jul 2008 18:08:02 -0400 Original-Received: by pastel.home (Postfix, from userid 20848) id 38133806B; Tue, 29 Jul 2008 18:07:57 -0400 (EDT) In-Reply-To: <87ej5czaef.fsf@stupidchicken.com> (Chong Yidong's message of "Tue, 29 Jul 2008 16:46:16 -0400") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.0.60 (gnu/linux) X-detected-kernel: by monty-python.gnu.org: Linux 2.6 (newer, 3) Resent-Date: Tue, 29 Jul 2008 18:27:26 -0400 X-BeenThere: bug-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:18916 Archived-At: >> In *scratch*, type this, and leave cursor after the final `for': >> >> format-decode-buffer >> forward-char >> >> for >> >> Then hit `M-TAB'. Choose one of the completions using mouse-2 in *Completions*. >> >> Only the final `for' should be completed, but instead all of the text >> in the buffer is replaced by the chosen completion. > Hi Stefan, > This bug was introduced by your patch: Yes, I know. > This sets completion-base-size to 0, which causes the completions buffer > to delete everything in the Lisp buffer when you make a selection. The problem is that leaving it nil will revert to the use of a heuristic. Fixing it right is a bit more difficult. > I don't understand why we need the (completely undocumented) hack > introduced here, where the cdr of the last item on the completions list > gives completion-base-size. Does anything else in Emacs depend on this? > Why not simply add a new optional argument to display-completion-list? Yes the base-size in the cdr is a hack, and we be able to get rid of it now that I've added the new `boundaries' action. But passing it as an additional argument won't make any difference for the bug at hand. Stefan