From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Kevin Rodgers Newsgroups: gmane.emacs.help Subject: Re: C-x C-b (switch-to-buffer) smarter suggestions? Date: Thu, 11 Feb 2010 21:42:26 -0700 Message-ID: References: NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1265949804 32189 80.91.229.12 (12 Feb 2010 04:43:24 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 12 Feb 2010 04:43:24 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Fri Feb 12 05:43:21 2010 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1NfnN8-0003xM-2a for geh-help-gnu-emacs@m.gmane.org; Fri, 12 Feb 2010 05:43:18 +0100 Original-Received: from localhost ([127.0.0.1]:49221 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NfnN7-0002vK-Kh for geh-help-gnu-emacs@m.gmane.org; Thu, 11 Feb 2010 23:43:17 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1NfnMl-0002vF-38 for help-gnu-emacs@gnu.org; Thu, 11 Feb 2010 23:42:55 -0500 Original-Received: from [140.186.70.92] (port=53404 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NfnMk-0002v7-4J for help-gnu-emacs@gnu.org; Thu, 11 Feb 2010 23:42:54 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1NfnMh-0000Xx-Sm for help-gnu-emacs@gnu.org; Thu, 11 Feb 2010 23:42:53 -0500 Original-Received: from lo.gmane.org ([80.91.229.12]:33681) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1NfnMh-0000Xq-LO for help-gnu-emacs@gnu.org; Thu, 11 Feb 2010 23:42:51 -0500 Original-Received: from list by lo.gmane.org with local (Exim 4.69) (envelope-from ) id 1NfnMf-0003k4-KN for help-gnu-emacs@gnu.org; Fri, 12 Feb 2010 05:42:49 +0100 Original-Received: from c-71-237-24-138.hsd1.co.comcast.net ([71.237.24.138]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Fri, 12 Feb 2010 05:42:49 +0100 Original-Received: from kevin.d.rodgers by c-71-237-24-138.hsd1.co.comcast.net with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Fri, 12 Feb 2010 05:42:49 +0100 X-Injected-Via-Gmane: http://gmane.org/ Original-Lines: 20 Original-X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: c-71-237-24-138.hsd1.co.comcast.net User-Agent: Thunderbird 2.0.0.23 (Macintosh/20090812) In-Reply-To: X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 3) X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:71817 Archived-At: Jorgen Grahn wrote: > On Tue, 2010-02-09, Kevin Rodgers wrote: ... > Thanks! I can't get it to work though, when just pasted into ~/.emacs: > > - C-x b > - prompt appears, I type 'foo' and press return > - error message: 'Wrong type argument: listp, "foo"' Sorry, I pasted a test version. The only change is: (defadvice switch-to-buffer (before switch-from-buffer activate) "Temporarily bind `switch-from-buffer' to the current buffer while reading args interactively. See `internal-complete-buffer'." (interactive (let ((switch-from-buffer (current-buffer))) (list (read-buffer "Switch to buffer: " (other-buffer)))))) -- Kevin Rodgers Denver, Colorado, USA