emacs-devel
[Top][All Lists]
Advanced

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

Re: Bug #25608 and the comment-cache branch


From: Alan Mackenzie
Subject: Re: Bug #25608 and the comment-cache branch
Date: Tue, 7 Feb 2017 21:09:42 +0000
User-agent: Mutt/1.7.2 (2016-11-26)

Hello, Eli.

On Tue, Feb 07, 2017 at 17:29:40 +0200, Eli Zaretskii wrote:
> > Date: Mon, 6 Feb 2017 20:01:16 +0000
> > From: Alan Mackenzie <address@hidden>
> > Cc: address@hidden

> > The syntactic significance of a buffer position is not changed by
> > any narrowing in force, no matter what the narrowing is "used for".

> If that's what you think, you are not talking about Emacs.  Emacs
> always behaved as if nothing existed outside of the current
> narrowing.

Not consistently.  Font lock, in all the modes I'm aware of, does not
invert its "stringiness" when point-min lies within a string.

> Even the display engine behaves like that: e.g., by suitable narrowing
> of bidirectional text you can completely change how the accessible
> portion is displayed.

Is this a deliberate design decision, or is it simply what tumbled out
after bidi was implemented in the easiest and most natural fashion?

> > That one or more multiple-mode attempts attempt to use narrowing that
> > way is a fundamental problem in those modes which we should solve by
> > providing a better method.

> That's true, but it doesn't affect the basic fact that Emacs behaves
> differently, and you cannot change that without significant changes on
> levels below applications.

> > Even if the user narrows to the string, it's still a string.

> Emacs currently doesn't have any means of knowing that, because the
> portions of the buffer outside the accessible region are simply not
> accessible.

As you know, I've implemented a scheme by which Emacs can know this.

Up till now, recognition of literals has been done solely by the local
context, probably because it was easier to implement this way rather
than any deep design decision.  Or am I wrong here?

Is there any part of Emacs which depends on this way of recognising
literals, and would that be badly hurt if literals came to be recognised
by their global context (as syntax-ppss currently sort of does)?

-- 
Alan Mackenzie (Nuremberg, Germany).



reply via email to

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