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: xref and leaving "temporary" buffers open Date: Thu, 30 Jul 2015 17:41:21 -0400 Message-ID: References: <55B2DC8F.3050305@yandex.ru> <55B3489C.2070009@gmx.at> <55B390CE.6020104@yandex.ru> <55B3994A.5010709@gmx.at> <55B3A0B6.6080101@yandex.ru> <55B3B0FC.3080004@gmx.at> <55B3EDBD.8050409@yandex.ru> <55B4C439.1040909@gmx.at> <55B4E5B3.3000108@yandex.ru> <55B65610.7070308@gmx.at> <55B77C57.6010306@yandex.ru> <55B82F77.3090204@yandex.ru> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1438292521 15595 80.91.229.3 (30 Jul 2015 21:42:01 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Thu, 30 Jul 2015 21:42:01 +0000 (UTC) Cc: martin rudalics , emacs-devel To: Dmitry Gutov Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Thu Jul 30 23:41:53 2015 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1ZKvaI-0003v2-AZ for ged-emacs-devel@m.gmane.org; Thu, 30 Jul 2015 23:41:50 +0200 Original-Received: from localhost ([::1]:42091 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZKvaH-0003cV-KX for ged-emacs-devel@m.gmane.org; Thu, 30 Jul 2015 17:41:49 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:33262) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZKva6-0003cE-5W for emacs-devel@gnu.org; Thu, 30 Jul 2015 17:41:39 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZKva0-0007M7-FV for emacs-devel@gnu.org; Thu, 30 Jul 2015 17:41:38 -0400 Original-Received: from chene.dit.umontreal.ca ([132.204.246.20]:52350) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZKva0-0007Lk-AF for emacs-devel@gnu.org; Thu, 30 Jul 2015 17:41:32 -0400 Original-Received: from fmsmemgm.homelinux.net (lechon.iro.umontreal.ca [132.204.27.242]) by chene.DIT.UMontreal.CA (8.14.1/8.14.1) with ESMTP id t6ULfSvF031875; Thu, 30 Jul 2015 17:41:29 -0400 Original-Received: by fmsmemgm.homelinux.net (Postfix, from userid 20848) id F0736AE09C; Thu, 30 Jul 2015 17:41:21 -0400 (EDT) In-Reply-To: <55B82F77.3090204@yandex.ru> (Dmitry Gutov's message of "Wed, 29 Jul 2015 04:42:15 +0300") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.0.50 (gnu/linux) X-NAI-Spam-Flag: NO X-NAI-Spam-Threshold: 5 X-NAI-Spam-Score: 0 X-NAI-Spam-Rules: 1 Rules triggered RV5383=0 X-NAI-Spam-Version: 2.3.0.9393 : core <5383> : inlines <3499> : streams <1480399> : uri <2000352> X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 132.204.246.20 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:188210 Archived-At: > Right. There were more specific proposals in this thread. You might want to > comment on those. I'm afraid I don't have the time to read all those messages. >> - set a buffer-local variable "buffer-file-incomplete" to a function >> which performs the missing setup (e.g. set up VC status and stuff). >> - ignore buffers with this var set to a non-nil value in things like >> buffer completion. > So, you'd limit the changes to the higher level, like read-buffer-to-switch > and internal-complete-buffer-except? Yes. > What about other interfaces we have for buffer switching? > ido-make-buffer-list-1 calls buffer-list (that one's easy to change, since > it's in the core), iflipb calls buffer-list, helm-buffers-list calls > buffer-list. AFAIK they (should) all skip the "hidden buffers" (those starting with a space), so we'd just have to make those incomplete buffers use a name with a leading space. > And depending on the file size, the overhead from vc-find-file-hook may > become noticeable, too. In (find-file-noselect ".gitignore"), it takes more > than half of the time (15 out of 25 ms), here. But for xdisp.c, that's probably negligible compared to the syntax-propertize call ;-) Stefan