From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Aidan Gauland Newsgroups: gmane.emacs.bugs Subject: bug#14207: 24.2; insert-file-contents clobbers match data Date: Tue, 16 Apr 2013 13:22:12 +1200 Message-ID: <87bo9fb77f.fsf@dimension8.tehua.net> References: <87fvysbohx.fsf@dimension8.tehua.net> <83ehec74r0.fsf@gnu.org> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1366075374 11206 80.91.229.3 (16 Apr 2013 01:22:54 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 16 Apr 2013 01:22:54 +0000 (UTC) Cc: 14207@debbugs.gnu.org To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Tue Apr 16 03:22:58 2013 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 1URubq-0006I9-2Y for geb-bug-gnu-emacs@m.gmane.org; Tue, 16 Apr 2013 03:22:58 +0200 Original-Received: from localhost ([::1]:53901 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1URubp-0001r4-7j for geb-bug-gnu-emacs@m.gmane.org; Mon, 15 Apr 2013 21:22:57 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:43895) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1URubi-0001qu-Uq for bug-gnu-emacs@gnu.org; Mon, 15 Apr 2013 21:22:54 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1URubg-0000e1-3s for bug-gnu-emacs@gnu.org; Mon, 15 Apr 2013 21:22:50 -0400 Original-Received: from debbugs.gnu.org ([140.186.70.43]:49241) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1URubg-0000dx-0J for bug-gnu-emacs@gnu.org; Mon, 15 Apr 2013 21:22:48 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.72) (envelope-from ) id 1URufm-00031D-8g for bug-gnu-emacs@gnu.org; Mon, 15 Apr 2013 21:27:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Aidan Gauland Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 16 Apr 2013 01:27:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 14207 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 14207-submit@debbugs.gnu.org id=B14207.136607560511573 (code B ref 14207); Tue, 16 Apr 2013 01:27:02 +0000 Original-Received: (at 14207) by debbugs.gnu.org; 16 Apr 2013 01:26:45 +0000 Original-Received: from localhost ([127.0.0.1]:53350 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1URufU-00030Z-59 for submit@debbugs.gnu.org; Mon, 15 Apr 2013 21:26:45 -0400 Original-Received: from jersey.rurallink.co.nz ([114.134.15.197]:52139 helo=smtp.rurallink.co.nz) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1URufP-00030I-S2 for 14207@debbugs.gnu.org; Mon, 15 Apr 2013 21:26:42 -0400 Original-Received: from [49.143.231.198] (helo=dimension8.tehua.net) by smtp.rurallink.co.nz with esmtpsa (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16) (Exim 4.72) (envelope-from ) id 1URubD-0007Bl-H4; Tue, 16 Apr 2013 13:22:21 +1200 In-Reply-To: <83ehec74r0.fsf@gnu.org> (Eli Zaretskii's message of "Mon, 15 Apr 2013 08:16:35 +0300") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.2 (gnu/linux) X-Rurallink-Authenticated-User: aidalgol@no8wireless.co.nz X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 140.186.70.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-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:73442 Archived-At: Eli Zaretskii writes: >> From: Aidan Gauland >> Date: Mon, 15 Apr 2013 12:56:26 +1200 >> >> If (and only if) the match data is non-nil when `insert-file-contents' >> is called, it clobbers the match-data. > > And why is that a bug? > > From the ELisp manual (node "Match Data"): > > Notice that all functions are allowed to overwrite the match data > unless they're explicitly documented not to do so. > > 'insert-file-contents' is not documented to preserve match data. Oh, OK. I thought it was the other way around: functions are supposed to explicitly be documented as modifying the match data.