From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: =?utf-8?Q?=C3=93scar_Fuentes?= Newsgroups: gmane.emacs.devel Subject: Re: Making `interactive' conditional Date: Mon, 11 Jan 2016 17:34:43 +0100 Message-ID: <87mvscdqho.fsf@wanadoo.es> References: <87mvszdp6b.fsf@gnus.org> <8737u9kv6f.fsf@russet.org.uk> <87fuy7hdc6.fsf_-_@wanadoo.es> <87bn8vh8q4.fsf@wanadoo.es> <4002fc97-5629-4367-8b8f-48b659fefdce@default> <87r3hoehmx.fsf@wanadoo.es> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1452530152 8775 80.91.229.3 (11 Jan 2016 16:35:52 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Mon, 11 Jan 2016 16:35:52 +0000 (UTC) To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Mon Jan 11 17:35:43 2016 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 1aIfRV-0002fF-1d for ged-emacs-devel@m.gmane.org; Mon, 11 Jan 2016 17:35:41 +0100 Original-Received: from localhost ([::1]:55667 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aIfRU-00065O-8P for ged-emacs-devel@m.gmane.org; Mon, 11 Jan 2016 11:35:40 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:39091) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aIfQn-0004tp-6N for emacs-devel@gnu.org; Mon, 11 Jan 2016 11:34:58 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1aIfQk-0006CK-03 for emacs-devel@gnu.org; Mon, 11 Jan 2016 11:34:57 -0500 Original-Received: from plane.gmane.org ([80.91.229.3]:45063) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aIfQj-0006C7-PN for emacs-devel@gnu.org; Mon, 11 Jan 2016 11:34:53 -0500 Original-Received: from list by plane.gmane.org with local (Exim 4.69) (envelope-from ) id 1aIfQg-00027k-R6 for emacs-devel@gnu.org; Mon, 11 Jan 2016 17:34:50 +0100 Original-Received: from 215.red-81-39-60.dynamicip.rima-tde.net ([81.39.60.215]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Mon, 11 Jan 2016 17:34:50 +0100 Original-Received: from ofv by 215.red-81-39-60.dynamicip.rima-tde.net with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Mon, 11 Jan 2016 17:34:50 +0100 X-Injected-Via-Gmane: http://gmane.org/ Original-Lines: 19 Original-X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: 215.red-81-39-60.dynamicip.rima-tde.net User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.0.50 (gnu/linux) Cancel-Lock: sha1:c5z0JLXjC+AEiMCx5pHD4be4M8s= X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 80.91.229.3 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:198032 Archived-At: "Herring, Davis" writes: >> (and (not read-only) visiting-file) > > So now you can't invoke it in *scratch*? I don't expect to use Lisp predicates, no. Allowing those when the filtering is executed has unbounded time complexity. > Of course, you can come up with another refinement to the condition > (e.g., mode-class). My point is merely that writing these predicates > is very subtle when the standard is not "is this command likely to > work when invoked" (in which case you wouldn't be bothering with > "visiting-file") but rather "is the user plausibly looking for this > command in the list". Filtering out editing commands when the buffer is not meant to be edited in any case enters into the "the user plausibly is not looking for this command" category.