bug-gnu-emacs
[Top][All Lists]
Advanced

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

bug#18826: 24.3.94; c++-mode bad indentation after programmatic insert w


From: Dmitry Gutov
Subject: bug#18826: 24.3.94; c++-mode bad indentation after programmatic insert with locally changed syntax table
Date: Mon, 27 Oct 2014 17:21:48 +0700
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.2.0

On 10/27/2014 03:53 PM, Alan Mackenzie wrote:

They (that is, the c-is-sws and c-in-sws properties) mark syntactic
whitespace.  They're set during calls to c-forward-syntactic-ws and
c-backward-syntactic-ws, which are used all over the place, just as much
in the indentation engine, and the commands, as in font lock.  They're
intended to mark CPP structures and, especially, massive comments, such
as are frequently found at the beginning of source files.  They're
intended to speed up the skipping of WS.

It sounds like it can be implemented in syntax-propertize-function without much trouble. Adding such props in movement commands sounds counter-intuitive, although I can see how this can be useful from the performance perspective.

It's already implemented and running.  :-)  The syntax-table properties
in the vicinity of a buffer change are removed and re-applied with tender
loving care.

Cool. It'll require a patch to syntax.el in the trunk, right?

No it's not.  Apologies.  I hadn't read your email properly.

That's good. I'll take that to mean that < and > having belonging to paren class won't stop them from being propertized in the before/after-change hooks like you described. Then I'll keep the code as-is, thanks!





reply via email to

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