From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: "Eric M. Ludlam" Newsgroups: gmane.emacs.devel Subject: Re[2]: font-lock patch for automated edits Date: Sun, 31 Aug 2008 23:07:50 -0400 Message-ID: <200809010307.m8137o8x017968@projectile.siege-engine.com> References: <200808301456.m7UEuKa9030348@projectile.siege-engine.com> NNTP-Posting-Host: lo.gmane.org X-Trace: ger.gmane.org 1220238493 10985 80.91.229.12 (1 Sep 2008 03:08:13 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Mon, 1 Sep 2008 03:08:13 +0000 (UTC) Cc: emacs-devel@gnu.org To: Stefan Monnier Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Mon Sep 01 05:09:07 2008 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1KZzmp-0007mI-UD for ged-emacs-devel@m.gmane.org; Mon, 01 Sep 2008 05:09:04 +0200 Original-Received: from localhost ([127.0.0.1]:56166 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1KZzlr-0003Qn-3d for ged-emacs-devel@m.gmane.org; Sun, 31 Aug 2008 23:08:03 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1KZzlk-0003N0-PW for emacs-devel@gnu.org; Sun, 31 Aug 2008 23:07:56 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1KZzlk-0003M8-AH for emacs-devel@gnu.org; Sun, 31 Aug 2008 23:07:56 -0400 Original-Received: from [199.232.76.173] (port=36064 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1KZzlj-0003Lg-SE for emacs-devel@gnu.org; Sun, 31 Aug 2008 23:07:55 -0400 Original-Received: from static-71-184-83-10.bstnma.fios.verizon.net ([71.184.83.10]:60832 helo=projectile.siege-engine.com) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1KZzli-0002td-SZ for emacs-devel@gnu.org; Sun, 31 Aug 2008 23:07:55 -0400 Original-Received: from projectile.siege-engine.com (localhost.localdomain [127.0.0.1]) by projectile.siege-engine.com (8.12.8/8.12.8) with ESMTP id m8137oWB017970; Sun, 31 Aug 2008 23:07:50 -0400 Original-Received: (from zappo@localhost) by projectile.siege-engine.com (8.12.8/8.12.8/Submit) id m8137o8x017968; Sun, 31 Aug 2008 23:07:50 -0400 In-reply-to: (message from Stefan Monnier on Sun, 31 Aug 2008 02:15:31 -0400) X-detected-kernel: by monty-python.gnu.org: Linux 2.4-2.6 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:103352 Archived-At: >>> Stefan Monnier seems to think that: >> I have some tests for the CEDET/Semantic incremental parsing engine. >> This test calls 'erase-buffer', and performs edits very quickly, and >> was causing font-lock to throw errors in my tests. > >Do you have backtraces for those bugs? Hi, After fixing the first bug, I'd bump into the next. I undid my changes to font-lock, and attached my first stack trace. Also see attached a very short version of what I was running. I need to run it twice to get the error. It's actually as easy as just typing: M-x erase-buffer RET in a buffer with font-locked stuff in it. It If you want to try out the entire setup I was running, you could get CEDET from the source-forge CVS, do a build, and then run semantic-utest-main. Eric ------------------------ Debugger entered--Lisp error: (args-out-of-range 88 88) get-text-property(88 font-lock-multiline) font-lock-extend-region-multiline() font-lock-default-fontify-region(1 88 nil) font-lock-fontify-region(1 88) font-lock-after-change-function(1 1 87) erase-buffer() (let ((buff ...)) (switch-to-buffer buff) (setq buffer-offer-save nil) (erase-buffer) (insert "/* Test file for C language for Unit Tests */\n\n#include \n#include \"sutest.h\"\n\n") (set-buffer-modified-p nil)) crash-font-lock() call-interactively(crash-font-lock t nil) execute-extended-command(nil) call-interactively(execute-extended-command nil nil) ------------------------ ;; Enable global-font-lock mode before using this (defun crash-font-lock () "Crash font lock by fast-editing a buffer." (interactive) (let ((buff (find-file-noselect "/tmp/CFL.cpp"))) (switch-to-buffer buff) (setq buffer-offer-save nil) (erase-buffer) (insert "/* Test file for C language for Unit Tests */ #include #include \"sutest.h\" " ) (set-buffer-modified-p nil) ))