From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: "Sean O'Rourke" Newsgroups: gmane.emacs.devel Subject: Re: PC-do-completion weird behavior acronym expansion. Date: Wed, 05 Sep 2007 21:51:22 -0700 Message-ID: References: <87odgzxkpk.fsf@lrde.org> <87wsv87yqn.fsf@elegiac.orebokech.com> NNTP-Posting-Host: dough.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Trace: sea.gmane.org 1189054340 24843 80.91.229.10 (6 Sep 2007 04:52:20 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Thu, 6 Sep 2007 04:52:20 +0000 (UTC) Cc: =?iso-8859-1?Q?Micha=EBl?= Cadilhac To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Thu Sep 06 06:57:35 2007 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by dough.gmane.org with esmtp (Exim 4.50) id 1IT9Qq-0005kS-AI for ged-emacs-devel@m.gmane.org; Thu, 06 Sep 2007 06:57:33 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1IT9Lh-0003e6-RO for ged-emacs-devel@m.gmane.org; Thu, 06 Sep 2007 00:52:13 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1IT9Le-0003e1-Dy for emacs-devel@gnu.org; Thu, 06 Sep 2007 00:52:10 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1IT9LY-0003d1-BD for emacs-devel@gnu.org; Thu, 06 Sep 2007 00:52:10 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1IT9LY-0003cw-53 for emacs-devel@gnu.org; Thu, 06 Sep 2007 00:52:04 -0400 Original-Received: from outbound2.ucsd.edu ([132.239.1.206]) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1IT9LX-0002z5-1i for emacs-devel@gnu.org; Thu, 06 Sep 2007 00:52:04 -0400 Original-Received: from smtp.ucsd.edu (smtp.ucsd.edu [132.239.1.49]) by outbound2.ucsd.edu (8.13.6/8.13.6) with ESMTP id l864pRjI005251 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Wed, 5 Sep 2007 21:51:28 -0700 (PDT) DomainKey-Signature: a=rsa-sha1; s=2007001; d=ucsd.edu; c=simple; q=dns; b=f30oyJTTuk9O+PrRbCTc6Aydot8mPgqH6dSh3g3n7/oS06s/PHjXR2Gi8Hk9ZVPf6 E5ZuJo58OvdY3+ajT/sQQ== Original-Received: from dyn128-54-220-221.ucsd.edu (dyn128-54-220-221.ucsd.edu [128.54.220.221]) by smtp.ucsd.edu (8.13.6/8.13.4) with ESMTP id l864pQbw014979; Wed, 5 Sep 2007 21:51:27 -0700 (PDT) In-Reply-To: <87wsv87yqn.fsf@elegiac.orebokech.com> (Romain Francoise's message of "Mon\, 03 Sep 2007 13\:52\:00 +0200") User-Agent: Gnus/5.11 (Gnus v5.11) Emacs/22.1.50 (darwin) X-Detected-Kernel: FreeBSD 6.x (1) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:77925 Archived-At: --=-=-= Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable Romain Francoise writes: > michael@cadilhac.name (Micha=EBl Cadilhac) writes: > >> The following change=A0: > >> 2007-08-07 Sean O'Rourke > >> * complete.el (PC-lisp-complete-symbol): Complete symbol around poi= nt. >> (PC-do-completion): Add "acronym completion" for symbols and >> filenames, so e.g. "mvbl" expands to "make-variable-buffer-local". > >> seems to introduce a little (but annoying) bug [...] > > It introduces another annoying bug: hitting TAB when the list of > possible completions is empty signals an error. Yeah, that does suck -- my apologies. Please try the attached patch. /s 2007-09-05 Sean O'Rourke * complete.el (PC-do-completion): don't try to treat empty string as an abbreviation. --=-=-= Content-Type: text/x-patch Content-Disposition: attachment Index: complete.el =================================================================== RCS file: /cvsroot/emacs/emacs/lisp/complete.el,v retrieving revision 1.78 diff -p -u -w -r1.78 complete.el --- complete.el 26 Aug 2007 19:20:10 -0000 1.78 +++ complete.el 6 Sep 2007 04:49:05 -0000 @@ -596,9 +596,10 @@ GOTO-END is non-nil, however, it instead (setq poss (all-completions (if env-on basestr str) table pred)) - (unless poss + (unless (or poss (string-equal str "")) ;; Try completion as an abbreviation, e.g. "mvb" -> - ;; "m-v-b" -> "multiple-value-bind" + ;; "m-v-b" -> "multiple-value-bind", but only for + ;; non-empty strings. (setq origstr str abbreviated t) (if filename --=-=-= Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Emacs-devel mailing list Emacs-devel@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-devel --=-=-=--