|
From: | Daniel Colascione |
Subject: | Re: cc-mode fontification feels random |
Date: | Wed, 09 Jun 2021 11:51:28 -0700 |
User-agent: | AquaMail/1.29.2-1810 (build: 102900008) |
On June 9, 2021 11:37:17 AM Eli Zaretskii <eliz@gnu.org> wrote:
Date: Wed, 9 Jun 2021 18:22:57 +0000 Cc: Daniel Colascione <dancol@dancol.org>, monnier@iro.umontreal.ca, rudalics@gmx.at, emacs-devel@gnu.org, rms@gnu.org From: Alan Mackenzie <acm@muc.de>I think we agree. Except that for me, it should also not try if it cannot do it quickly enough, not only reliably enough.Quickly and reliably enough are desirable things, but in competition with eachother. Reliably enough is a lot easier to measure, quickly enough depends on the machine, the degree of optimisation, and above all, the user's expectations.That's why we had (and still have) font-lock-maximum-decoration: so that users could control the tradeoff. Unfortunately, support for that variable is all but absent nowadays, because of the widespread mistaken assumption that font-lock is fast enough in all modes.
It should be fast enough for all modes. This isn't 1985. Computers in general are *several orders* of magnitude faster than needed to do real time syntax highlighting in general. Other editors don't seem to struggle. Tree sitter is very fast. If regular editing is stuttering because of fontification, we have bad data structures, algorithms, or architectures --- that is, bugs. And we shouldn't add user options to paper over bugs. That's ridiculous. I can't believe we really want to propose a "please make syntax highlighting wrong" user option.
[Prev in Thread] | Current Thread | [Next in Thread] |