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

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

bug#15251: 24.3.50; do-auto-fill "continues" comment from inside a strin


From: Dmitry Gutov
Subject: bug#15251: 24.3.50; do-auto-fill "continues" comment from inside a string
Date: Wed, 02 Oct 2013 03:50:34 +0300
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.0

On 02.10.2013 03:32, Stefan Monnier wrote:
- Change code that uses comment-use-global-state to use (and
   comment-use-syntax comment-use-global-state) instead.

This is already the case: `comment-search-forward' consults the value of `comment-use-global-state' only when `comment-use-syntax' is truthy.

- Maybe make comment-use-global-state obsolete.

Context: the problem with syntax-ppss is not so much performance as
correctness, because syntax-ppss can get confused if you use several
syntax-tables in the same buffer (e.g. via font-lock-syntax-table), or
if you use narrowing.

Yes, that seems hard to test for.

And if `syntax-ppss' can be borked in some modes, using its value in `comment-beginning' like I did in the respective patch, also seems unsafe.





reply via email to

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