emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: /srv/bzr/emacs/trunk r101338: * lisp/emacs-lisp/syntax.el (syntax-pp


From: Stefan Monnier
Subject: Re: /srv/bzr/emacs/trunk r101338: * lisp/emacs-lisp/syntax.el (syntax-ppss): More sanity check to catch
Date: Wed, 12 Feb 2014 09:26:40 -0500
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (gnu/linux)

>>> One option is to have a hook that takes a (POS . PPSS) pair, which
>>> syntax-ppss intends to use as a starting point for parsing, and return
>>> a new such pair to use instead, where the returned position should
>>> always be >= POS.
> A problem: suppose point is in a primary mode region, and POS is
> in a submode region above it. Then we can't use the value of PPSS at all.

I don't understand the problem.  Of course your hook would return
a completely different PPSS to use along with the new buffer position
from where to start parsing.

> Does the hook re-scan the buffer from the beginning?

I don't understand the question.

> I suppose this could be handled if `syntax-ppss-flush-cache' removed or
> modified the cache entries where NEXT-BOUNDARY is after BEG.

Exactly.

> And by modified, I mean set NEXT-BOUNDARY to BEG.

Yes, something like that.


        Stefan



reply via email to

[Prev in Thread] Current Thread [Next in Thread]