unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
From: Lowell Kirsh <lkirsh@cs.ubc.ca>
Subject: Re: font locking problem
Date: Fri, 07 May 2004 20:25:05 -0700	[thread overview]
Message-ID: <c7hjuh$4b5$1@mughi.cs.ubc.ca> (raw)
In-Reply-To: <klhf7c.q5.ln@acm.acm>

Thanks for the help. I won't post my java source here because I know 
that it's ok. All java files cause the same problems. Good to know about 
jit-lock as a replacemnet for lazy-lock. I'll be sure to give it a try.

Lowell

Alan Mackenzie wrote:
> Lowell Kirsh <lkirsh@cs.ubc.ca> wrote on Wed, 05 May 2004 14:12:54 -0700:
> 
>>Alan Mackenzie wrote:
>>
>>>Would you tell us your Emacs version number (M-x emacs-version) and your
>>>CC Mode version number (M-x c-version), please.
> 
> 
>>emacs-version: 21.3.1
>>c-version: 5.28
> 
> 
> OK, thanks!  These two certainly _ought_ to work sensibly together.
> 
> 
>>>That's an internal coding error, probably in CC Mode.  Try setting
>>>`debug-on-error'  (M-: (setq debug-on-error t)), then visit the file again.
>>>That should give a stack dump.
> 
> 
>>Here's a stack dump:
> 
> 
>>Debugger entered--Lisp error: (wrong-type-argument integer-or-marker-p nil)
>>   goto-char(nil)
>>   eval((goto-char (match-beginning 4)))         <====================
>>   font-lock-fontify-keywords-region(1 1515 t)   <====================
>>   font-lock-default-fontify-region(1 1515 t)
>>   font-lock-fontify-region(1 1515 t)
>>   byte-code("?Ã \x18Ä?Åed	#?Æ ?Ç\x12+Ã?" [save-match-data-internal verbose 
>>font-lock-fontified match-data ((set-match-data 
>>save-match-data-internal)) font-lock-fontify-region 
>>font-lock-after-fontify-buffer t] 4)
>>   font-lock-default-fontify-buffer()
>>   font-lock-fontify-buffer()
>>   font-lock-mode()
>>   turn-on-font-lock()
>>   turn-on-font-lock-if-enabled()
>>   global-font-lock-mode-buffers()
>>   run-hooks(find-file-hooks)
>>   after-find-file(nil t)
>>   find-file-noselect-1(#<buffer FileTokenizer.java> 
>>"~/java/FileTokenizer.java" nil nil "~/java/FileTokenizer.java" (3385326 
>>775))
>>   find-file-noselect("~/java/FileTokenizer.java" nil nil 1)
>>   find-file("~/java/FileTokenizer.java" 1)
>>   call-interactively(find-file)
> 
> 
> Quick question:  does this problem happen with any file.java, or is it
> only FileTokenizer.java which crashes?  If the latter, is there a
> (java) syntactic error in this file?  [Just for clarity:  even if there
> is such an error, Emacs shouldn't be bailing out on it ;-]
> 
> I've had a look at the code in font-lock.el, but can't make much of the
> information in the dump.  (In particular, I can't see the connection
> between the two lines of the dump I've marked with "<=======", which is
> the critical bit.  Stefan, what am I missing?)
> 
> The file FileTokenizer.java is only 1515 bytes long, isn't it?  Could you
> possibly post it here (or even email it to me on acm@muc.de), so that I
> could step through it with a debugger?
> 
> 
>>So, what should I do? Work around this error until the next version 
>>comes out? I'd rather do that than build from the newest cvs source 
>>(laziness).
> 
> 
> Yes, I can certainly empathise with you on that one.  ;-)
> 
> One thing to do would be to try with `jit-lock-mode' in place of
> `lazy-lock-mode'.  jit-lock is based on the same ideas as lazy-lock.  It
> was a reimplementation done after it emerged that there were fundamental
> problems with lazy-lock.
> 
> 
>>Lowell
> 
> 

  reply	other threads:[~2004-05-08  3:25 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-05-04  2:32 font locking problem Lowell Kirsh
2004-05-04 16:26 ` Kevin Rodgers
2004-05-04 22:36   ` Lowell Kirsh
2004-05-05  7:14 ` Alan Mackenzie
2004-05-05 21:12   ` Lowell Kirsh
2004-05-07  8:33     ` Alan Mackenzie
2004-05-08  3:25       ` Lowell Kirsh [this message]
2004-05-09 19:44       ` Stefan Monnier
2004-05-10 21:29         ` Lowell Kirsh
2004-05-11 15:45           ` Kevin Rodgers

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='c7hjuh$4b5$1@mughi.cs.ubc.ca' \
    --to=lkirsh@cs.ubc.ca \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).