unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
* [bug] python-mode, jit-lock, syntax-pss during file load
@ 2004-06-11 15:16 Karl Chen
  2004-06-21 17:04 ` Dave Love
  0 siblings, 1 reply; 4+ messages in thread
From: Karl Chen @ 2004-06-11 15:16 UTC (permalink / raw)



(syntax-ppss) doesn't work correctly at file load when
font-lock-support-mode is 'jit-lock-mode.

Symptom: when (re)loading a python file whose initial contents
look like:

'''   ...  '
blah1:
  blah2

'''

If jit-lock-mode is on, then python-mode guesses python-indent of
2 because it thinks "blah1:" is not in a string.

If you evaluate (python-guess-indent) after the file has loaded,
it returns 4.  It only returns 2 while the file is loading.  (It
was annoying that python-guess-indent returns different results
when debugging is enabled!)

Other font lock support modes (or no font lock) might also have
problems.  I think the fix is to force syntaxification/
fontification before python-guess-indent is called.





-- 
Karl 2004-06-11 17:07

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2004-06-24  3:04 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-06-11 15:16 [bug] python-mode, jit-lock, syntax-pss during file load Karl Chen
2004-06-21 17:04 ` Dave Love
2004-06-22  8:43   ` another jit-lock bug Karl Chen
2004-06-24  3:04     ` Richard Stallman

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

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).