From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.bugs Subject: bug#4587: Antwort: Re: bug#4587: 23.1; sort-lines and sort-fields always set buffer modified Date: Wed, 30 Sep 2009 09:51:50 -0400 Message-ID: References: Reply-To: Stefan Monnier , 4587@emacsbugs.donarmstrong.com NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1254328587 12762 80.91.229.12 (30 Sep 2009 16:36:27 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 30 Sep 2009 16:36:27 +0000 (UTC) Cc: 4587@emacsbugs.donarmstrong.com, bug-gnu-emacs@gnu.org To: Roland.Meier@continental-corporation.com Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Wed Sep 30 18:36:20 2009 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1Mt2A4-0006km-L9 for geb-bug-gnu-emacs@m.gmane.org; Wed, 30 Sep 2009 18:36:17 +0200 Original-Received: from localhost ([127.0.0.1]:45805 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Mt2A4-0006wX-2z for geb-bug-gnu-emacs@m.gmane.org; Wed, 30 Sep 2009 12:36:16 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1Mszpu-00033n-6r for bug-gnu-emacs@gnu.org; Wed, 30 Sep 2009 10:07:18 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1Mszpp-0002zk-Hc for bug-gnu-emacs@gnu.org; Wed, 30 Sep 2009 10:07:17 -0400 Original-Received: from [199.232.76.173] (port=51540 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Mszpp-0002zS-5g for bug-gnu-emacs@gnu.org; Wed, 30 Sep 2009 10:07:13 -0400 Original-Received: from rzlab.ucr.edu ([138.23.92.77]:55768) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1Mszpn-00008a-U5 for bug-gnu-emacs@gnu.org; Wed, 30 Sep 2009 10:07:12 -0400 Original-Received: from rzlab.ucr.edu (rzlab.ucr.edu [127.0.0.1]) by rzlab.ucr.edu (8.14.3/8.14.3/Debian-5) with ESMTP id n8UE7766018494; Wed, 30 Sep 2009 07:07:07 -0700 Original-Received: (from debbugs@localhost) by rzlab.ucr.edu (8.14.3/8.14.3/Submit) id n8UE06gU016625; Wed, 30 Sep 2009 07:00:06 -0700 Resent-Date: Wed, 30 Sep 2009 07:00:06 -0700 X-Loop: owner@emacsbugs.donarmstrong.com Resent-From: Stefan Monnier Resent-To: bug-submit-list@donarmstrong.com Resent-CC: Emacs Bugs 2Resent-Date: Wed, 30 Sep 2009 14:00:05 +0000 Resent-Message-ID: Resent-Sender: owner@emacsbugs.donarmstrong.com X-Emacs-PR-Message: followup 4587 X-Emacs-PR-Package: emacs X-Emacs-PR-Keywords: Original-Received: via spool by 4587-submit@emacsbugs.donarmstrong.com id=B4587.125431872115712 (code B ref 4587); Wed, 30 Sep 2009 14:00:05 +0000 Original-Received: (at 4587) by emacsbugs.donarmstrong.com; 30 Sep 2009 13:52:01 +0000 X-Spam-Bayes: score:0.5 Bayes not run. spammytokens:Tokens not available. hammytokens:Tokens not available. Original-Received: from ironport2-out.pppoe.ca (ironport2-out.teksavvy.com [206.248.154.183]) by rzlab.ucr.edu (8.14.3/8.14.3/Debian-5) with ESMTP id n8UDpxYM015573 for <4587@emacsbugs.donarmstrong.com>; Wed, 30 Sep 2009 06:52:00 -0700 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AqIEAOf+wkrO+KOO/2dsb2JhbACBUddFhCcEhw8 X-IronPort-AV: E=Sophos;i="4.44,480,1249272000"; d="scan'208";a="46840175" Original-Received: from 206-248-163-142.dsl.teksavvy.com (HELO pastel.home) ([206.248.163.142]) by ironport2-out.pppoe.ca with ESMTP; 30 Sep 2009 09:51:50 -0400 Original-Received: by pastel.home (Postfix, from userid 20848) id D6F868109; Wed, 30 Sep 2009 09:51:50 -0400 (EDT) In-Reply-To: (Roland Meier's message of "Wed, 30 Sep 2009 12:00:56 +0200") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.1.50 (gnu/linux) X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6 (newer, 2) Resent-Date: Wed, 30 Sep 2009 10:07:17 -0400 X-BeenThere: bug-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:31599 Archived-At: >> Yes, that's generally desirable. But in the above cases, given the way >> the code currently works, it's fairly inconvenient to do (the code does >> modify the buffer, it just so happens that the end text is the same as >> the original text), so it doesn't seem worth the trouble. > Wouldn't it be possible in case of an unmodified buffer to copy the > content of the region at the beginning to a temporary buffer, compare it > to the result afterwards, and if they match to restore the unmodified > status? I'd indeed expect that to implement the feature you request, the code would have to do something like that. Most likely not copying the text itself, but instead storing an md5 or somesuch hash of the text. > I sometimes need to check a list (which isn't small enough to be checked > at a glance) after editing it if it is still sorted. > Now I write he region before and after sorting it to separate files and > compare them, but I wonder if a powerful tool like Emacs must keep such an > obvious annoyance like this... No, it definitely doesn't have to keep such obvious annoyances. But it's not very high on the priority list. Stefan