From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Alan Mackenzie Newsgroups: gmane.emacs.bugs Subject: bug#7181: 24.0.50; args-out-of-range while reverting C++ header file Date: Sat, 9 Oct 2010 21:13:32 +0000 Message-ID: <20101009211332.GA5486__6220.02340755916$1286658729$gmane$org@muc.de> References: <87zkuo2djr.fsf@telefonica.net> <83wrprn3ou.fsf@gnu.org> <87sk0f32pp.fsf@telefonica.net> <87ocb331wo.fsf@telefonica.net> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit X-Trace: dough.gmane.org 1286658729 26432 80.91.229.12 (9 Oct 2010 21:12:09 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Sat, 9 Oct 2010 21:12:09 +0000 (UTC) Cc: 7181@debbugs.gnu.org, emacs-devel@gnu.org To: =?UTF-8?Q?=C3=93scar?= Fuentes Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sat Oct 09 23:12:08 2010 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.69) (envelope-from ) id 1P4gi7-0004jb-CX for geb-bug-gnu-emacs@m.gmane.org; Sat, 09 Oct 2010 23:12:07 +0200 Original-Received: from localhost ([127.0.0.1]:33218 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1P4gi6-0005Ns-Pr for geb-bug-gnu-emacs@m.gmane.org; Sat, 09 Oct 2010 17:12:06 -0400 Original-Received: from [140.186.70.92] (port=47826 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1P4gi0-0005Nk-Sf for bug-gnu-emacs@gnu.org; Sat, 09 Oct 2010 17:12:01 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1P4ghz-0002Mi-2o for bug-gnu-emacs@gnu.org; Sat, 09 Oct 2010 17:12:00 -0400 Original-Received: from debbugs.gnu.org ([140.186.70.43]:55148) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1P4ghy-0002Md-VG for bug-gnu-emacs@gnu.org; Sat, 09 Oct 2010 17:11:59 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.69) (envelope-from ) id 1P4gUT-00089O-Vl; Sat, 09 Oct 2010 16:58:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Alan Mackenzie Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-To: owner@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 09 Oct 2010 20:58:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 7181 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 7181-submit@debbugs.gnu.org id=B7181.128665784231319 (code B ref 7181); Sat, 09 Oct 2010 20:58:01 +0000 Original-Received: (at 7181) by debbugs.gnu.org; 9 Oct 2010 20:57:22 +0000 Original-Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1P4gTq-000896-Bc for submit@debbugs.gnu.org; Sat, 09 Oct 2010 16:57:22 -0400 Original-Received: from colin.muc.de ([193.149.48.1] helo=mail.muc.de) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1P4gTn-000890-Nk for 7181@debbugs.gnu.org; Sat, 09 Oct 2010 16:57:20 -0400 Original-Received: (qmail 14905 invoked by uid 3782); 9 Oct 2010 21:00:39 -0000 Original-Received: from acm.muc.de (pD9E51812.dip.t-dialin.net [217.229.24.18]) by colin2.muc.de (tmda-ofmipd) with ESMTP; Sat, 09 Oct 2010 23:00:38 +0200 Original-Received: (qmail 5625 invoked by uid 1000); 9 Oct 2010 21:13:32 -0000 Content-Disposition: inline In-Reply-To: <87ocb331wo.fsf@telefonica.net> User-Agent: Mutt/1.5.9i X-Delivery-Agent: TMDA/1.1.5 (Fettercairn) X-Primary-Address: acm@muc.de X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list Resent-Date: Sat, 09 Oct 2010 16:58:01 -0400 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 3) 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: , 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:40788 Archived-At: Hi, Óscar, On Sat, Oct 09, 2010 at 03:56:39PM +0200, Óscar Fuentes wrote: > With the attached files the problem can be reproduced predictability: > > Save the attached files b.h.master and b.h.next to a directory and cd to > it. > > $ emacs -Q & > $ cp b.h.master b.h > C-x C-f b.h > $ cp b.h.next b.h > M-x revert-buffer > > and the args-out-of-range error pops: > > c-clear-char-property-with-value-function: Args out of range: 166, 453 > > I was unable to try with the latest Emacs sources because the build is > broken. My Emacs is from the 16 September. > Thanks for the recipe. I turned on debug-on-error and got this traceback: Debugger entered--Lisp error: (args-out-of-range 166 453) remove-text-properties(166 453 (category)) c-clear-char-property-with-value-function(1 453 category c-cpp-delimiter) c-neutralize-syntax-in-and-mark-CPP(94 94 286) c-after-change(94 94 286) <<====================================== insert-file-contents("/home/acm/b.h" t nil nil t) revert-buffer(t) call-interactively(revert-buffer nil nil) c-after-change is on the after-change-functions hook. The values of BEG END OLD-LEN it is being passed look utterly wrong. BEG and END should delimit the entire buffer and OLD-LEN should be the length of the previous buffer. Surely? -- Alan Mackenzie (Nuremberg, Germany).