From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.devel Subject: Re: separate name uniquification from `generate-new-buffer-name' Date: Tue, 25 May 2010 15:30:03 -0400 Message-ID: References: NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7BIT X-Trace: dough.gmane.org 1274815869 777 80.91.229.12 (25 May 2010 19:31:09 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Tue, 25 May 2010 19:31:09 +0000 (UTC) Cc: emacs-devel@gnu.org To: Drew Adams Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue May 25 21:31:04 2010 connect(): No such file or directory Return-path: Envelope-to: ged-emacs-devel@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 1OGzqA-0006Jp-N9 for ged-emacs-devel@m.gmane.org; Tue, 25 May 2010 21:31:03 +0200 Original-Received: from localhost ([127.0.0.1]:42713 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OGzq8-0006Bl-R1 for ged-emacs-devel@m.gmane.org; Tue, 25 May 2010 15:31:00 -0400 Original-Received: from [140.186.70.92] (port=33187 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OGzpJ-0005cX-OY for emacs-devel@gnu.org; Tue, 25 May 2010 15:30:10 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1OGzpE-000599-N3 for emacs-devel@gnu.org; Tue, 25 May 2010 15:30:09 -0400 Original-Received: from relais.videotron.ca ([24.201.245.36]:34108) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OGzpE-00058w-JV for emacs-devel@gnu.org; Tue, 25 May 2010 15:30:04 -0400 Original-Received: from ceviche.home ([96.21.101.38]) by VL-MR-MR001.ip.videotron.ca (Sun Java(tm) System Messaging Server 6.3-8.01 (built Dec 16 2008; 32bit)) with ESMTP id <0L2Z00BEXQ6349D0@VL-MR-MR001.ip.videotron.ca> for emacs-devel@gnu.org; Tue, 25 May 2010 15:30:03 -0400 (EDT) Original-Received: by ceviche.home (Postfix, from userid 20848) id 13CF8660BB; Tue, 25 May 2010 15:30:03 -0400 (EDT) In-reply-to: User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.50 (gnu/linux) X-detected-operating-system: by eggs.gnu.org: Solaris 10 (beta) 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:125266 Archived-At: > Something I would like to see is separation of -suffix name > uniquifying from `generate-new-buffer-name'. The latter could just > use the more general unique-naming function (unless C optimization is > important in that particular case). Mostly agreed. As you noticed, uniquify uses advices and that should be fixed. A good way to fix it is to come up with a good name-buffer-function variable that holds a function that's run whenever a buffer name is chosen or modified. This variable's default would be a function that implements the usual stuff and it could be replaced by uniquify to do something more clever. Stefan