From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Drew Adams Newsgroups: gmane.emacs.bugs Subject: bug#21072: 24.5; inconsistent behaviour of `C-M-h (mark-defun)' in Emacs Lisp Date: Fri, 6 May 2016 22:07:13 -0700 (PDT) Message-ID: References: <55A74B3C.8030608@gmail.com> <87k2jm2bay.fsf@amu.edu.pl> <83r3dln1ez.fsf@gnu.org> <87y47tzn0v.fsf@mbork.pl> <83lh3tmyzv.fsf@gnu.org> <87twihzhni.fsf@mbork.pl> <83fuu1mu25.fsf@gnu.org> <87eg9jynn0.fsf@mbork.pl> <83h9edkhjs.fsf@gnu.org> <874mabe5h6.fsf@mbork.pl> <83twibfil2.fsf@gnu.org> <87y47mcywp.fsf@mbork.pl> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: quoted-printable X-Trace: ger.gmane.org 1462597709 3910 80.91.229.3 (7 May 2016 05:08:29 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sat, 7 May 2016 05:08:29 +0000 (UTC) Cc: rfflrccrd@gmail.com, 21072@debbugs.gnu.org To: Marcin Borkowski , Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sat May 07 07:08:15 2016 Return-path: Envelope-to: geb-bug-gnu-emacs@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 1ayuTP-00018k-6a for geb-bug-gnu-emacs@m.gmane.org; Sat, 07 May 2016 07:08:15 +0200 Original-Received: from localhost ([::1]:33200 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ayuTK-0007Gq-Tm for geb-bug-gnu-emacs@m.gmane.org; Sat, 07 May 2016 01:08:10 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:43304) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ayuTG-0007Az-Cp for bug-gnu-emacs@gnu.org; Sat, 07 May 2016 01:08:08 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ayuTC-00061l-3X for bug-gnu-emacs@gnu.org; Sat, 07 May 2016 01:08:05 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:58115) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ayuTB-00061h-WC for bug-gnu-emacs@gnu.org; Sat, 07 May 2016 01:08:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1ayuTB-00080D-Pu for bug-gnu-emacs@gnu.org; Sat, 07 May 2016 01:08:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Drew Adams Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 07 May 2016 05:08:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 21072 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 21072-submit@debbugs.gnu.org id=B21072.146259765030718 (code B ref 21072); Sat, 07 May 2016 05:08:01 +0000 Original-Received: (at 21072) by debbugs.gnu.org; 7 May 2016 05:07:30 +0000 Original-Received: from localhost ([127.0.0.1]:42219 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ayuSg-0007zO-GE for submit@debbugs.gnu.org; Sat, 07 May 2016 01:07:30 -0400 Original-Received: from aserp1040.oracle.com ([141.146.126.69]:31131) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ayuSe-0007z7-6A for 21072@debbugs.gnu.org; Sat, 07 May 2016 01:07:28 -0400 Original-Received: from aserv0022.oracle.com (aserv0022.oracle.com [141.146.126.234]) by aserp1040.oracle.com (Sentrion-MTA-4.3.2/Sentrion-MTA-4.3.2) with ESMTP id u4757KW7015124 (version=TLSv1 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Sat, 7 May 2016 05:07:20 GMT Original-Received: from userv0121.oracle.com (userv0121.oracle.com [156.151.31.72]) by aserv0022.oracle.com (8.13.8/8.13.8) with ESMTP id u4757JGr012011 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Sat, 7 May 2016 05:07:20 GMT Original-Received: from abhmp0011.oracle.com (abhmp0011.oracle.com [141.146.116.17]) by userv0121.oracle.com (8.13.8/8.13.8) with ESMTP id u4757EQU028251; Sat, 7 May 2016 05:07:18 GMT In-Reply-To: <87y47mcywp.fsf@mbork.pl> X-Priority: 3 X-Mailer: Oracle Beehive Extensions for Outlook 2.0.1.9 (901082) [OL 12.0.6744.5000 (x86)] X-Source-IP: aserv0022.oracle.com [141.146.126.234] X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 208.118.235.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:117940 Archived-At: I agree that the behavior is not particularly consistent, and it does not completely correspond to the doc. What the best fix is, I don't know. It's been this way for a long time, so there might be people who expect or like it to do what it does, in which case the doc should probably be fixed somewhat. On the other hand, I'd bet that few, if any, would complain if better behavior were implemented. In any case, the behavior of being able to repeat to keep selecting more defuns further down should be kept. I'd suggest that Someone (TM) (Marcin?) implement a better behavior and propose it to emacs-devel. ;-) What might be better? 1. At least consistency wrt which defun gets selected, when betweeen defuns. The doc suggests a general rule (the next defun), but that is not always respected. 2. Something consistent also wrt a comment before the defun that will be selected. 3. It could be good for a numeric prefix arg to select that many defuns. 4. It could be good for a negative prefix arg to select in the opposite direction. This is the main improvement I'd like to see. E.g. `M-- C-M-h' selects the previous defun; `M-2 C-M-h' selects the two previous defuns. Someone should play around and dream up something useful. Wrt #2, I'm not sure what the best approach might be.