From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#23794: Emacs bug #23794; sort-line behavior regressed from prior Emacs versions Date: Sun, 19 Jun 2016 19:55:14 +0300 Message-ID: <83lh2186fh.fsf__33123.1218217455$1466355427$gmane$org@gnu.org> References: <83shwa9zmr.fsf@gnu.org> <83lh229ywc.fsf@gnu.org> <83inx69xcx.fsf@gnu.org> <0984ce22-cbcf-42a6-906e-a03b65f3c71c@default> <8360t5aolu.fsf@gnu.org> <83vb158awq.fsf@gnu.org> <83oa6x87ky.fsf@gnu.org> Reply-To: Eli Zaretskii NNTP-Posting-Host: plane.gmane.org X-Trace: ger.gmane.org 1466355427 20071 80.91.229.3 (19 Jun 2016 16:57:07 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sun, 19 Jun 2016 16:57:07 +0000 (UTC) Cc: 23794@debbugs.gnu.org, rms@gnu.org, emacs-devel@gnu.org To: rswgnu@gmail.com Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sun Jun 19 18:56:52 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 1bEg1i-00012e-7M for geb-bug-gnu-emacs@m.gmane.org; Sun, 19 Jun 2016 18:56:50 +0200 Original-Received: from localhost ([::1]:39439 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bEg1h-0001To-FM for geb-bug-gnu-emacs@m.gmane.org; Sun, 19 Jun 2016 12:56:49 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:56816) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bEg11-00019R-Lm for bug-gnu-emacs@gnu.org; Sun, 19 Jun 2016 12:56:08 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bEg0w-0007aE-93 for bug-gnu-emacs@gnu.org; Sun, 19 Jun 2016 12:56:06 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:34270) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bEg0w-0007aA-5m for bug-gnu-emacs@gnu.org; Sun, 19 Jun 2016 12:56:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1bEg0w-0004fi-1r for bug-gnu-emacs@gnu.org; Sun, 19 Jun 2016 12:56:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 19 Jun 2016 16:56:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 23794 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 23794-submit@debbugs.gnu.org id=B23794.146635534417925 (code B ref 23794); Sun, 19 Jun 2016 16:56:02 +0000 Original-Received: (at 23794) by debbugs.gnu.org; 19 Jun 2016 16:55:44 +0000 Original-Received: from localhost ([127.0.0.1]:46607 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1bEg0e-0004f2-JP for submit@debbugs.gnu.org; Sun, 19 Jun 2016 12:55:44 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:37509) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1bEg0d-0004em-5s for 23794@debbugs.gnu.org; Sun, 19 Jun 2016 12:55:43 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bEg0U-0007Vr-QM for 23794@debbugs.gnu.org; Sun, 19 Jun 2016 12:55:38 -0400 Original-Received: from fencepost.gnu.org ([2001:4830:134:3::e]:55436) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bEg0U-0007Vk-Js; Sun, 19 Jun 2016 12:55:34 -0400 Original-Received: from 84.94.185.246.cable.012.net.il ([84.94.185.246]:2744 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_128_CBC_SHA1:128) (Exim 4.82) (envelope-from ) id 1bEg0K-0001zO-E5; Sun, 19 Jun 2016 12:55:25 -0400 In-reply-to: (message from Robert Weiner on Sun, 19 Jun 2016 12:51:08 -0400) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] 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:119783 Archived-At: > From: Robert Weiner > Date: Sun, 19 Jun 2016 12:51:08 -0400 > Cc: Drew Adams , Richard Stallman , > emacs-devel , 23794@debbugs.gnu.org > > On Sun, Jun 19, 2016 at 12:30 PM, Eli Zaretskii wrote: > > Didn't think that far, but is it really clean for sort-lines to have > special code for some major mode? I thought a better way is to > override the default behavior by having sort-lines call functions > through funcall or somesuch, and then outline modes could set the > appropriate variable to the function of their liking? > > The problem with that approach is that each mode has to be aware of this and add a setting, really not much > different than each mode having its own sort function or way of calling a sort function. It is much more useful > to centralize the behavior within the sorting library, even if it adds some conditional complexity to the code. Not necessarily: if you set that up in outline-mode, all of its descendants will inherit the setting for free. > Here is the suggested patch to do it this way. -- Bob Thanks, I hope others will comment on this.