[Top][All Lists]

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

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

From: E Sabof
Subject: Re: /srv/bzr/emacs/trunk r101338:*lisp/emacs-lisp/syntax.el(syntax-ppss): More sanity check to catchtch
Date: Sun, 16 Feb 2014 17:48:04 +0000
User-agent: mu4e; emacs

Dmitry Gutov <address@hidden> writes:

> Until you define what such a function would do, it's hard for things to
> go wrong.

I should probably get re-acquainted with mmm. It might contain useful 
functionality that I haven't considered.

>From personal experience of dealing with multi-lingual files, I'd say I'd like 
>fontification, language-sensitive navigation and indentation. I suppose some 
>keys might change as well, but I'not convinced that the benefits outweigh the 
>additional complexity.

It might be possible to achieve consistent navigation by making functions such 
as beginning-of-defun consult a region property before consulting the 
buffer-local beginning-of-defun-function.

I might also like error-checking, but it's conceivable to move this 
responsibility to flymake.

> But let's just look at things in motion. What would make a major mode
> call this function? It would have to know about a set of template
> delimiters, right? And somehow translate them into `set-region-mode'
> calls?
> Are BEGINNING and END buffer positions? What happens if the user inserts
> some text in the buffer? Will all regions below suddenly become invalid?
> Okay, let's make them markers. What happens when the user removes a
> region? Or just one delimiter? Or adds a new delimiter, or region?

This requires a parsing loop, which I'd guess is how mmm handles it.


reply via email to

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