]> git.eshelyaron.com Git - emacs.git/commit
Increase `so-long-threshold' and `so-long-max-lines' defaults
authorPhil Sainty <psainty@orcon.net.nz>
Sun, 10 Jan 2021 01:29:32 +0000 (14:29 +1300)
committerPhil Sainty <psainty@orcon.net.nz>
Tue, 3 Aug 2021 11:20:06 +0000 (23:20 +1200)
commit9df60d52d50b86639a82f22d7c0a07a81c3ba817
tree167cbcd82f84de23625efd299169af6cdc5a41d9
parent359a8e4eda047b7dcb7e64faff7f8eaacf5d937c
Increase `so-long-threshold' and `so-long-max-lines' defaults

* lisp/so-long.el (so-long-threshold, so-long-max-lines): Increase
default values to reduce false-positives.

* etc/NEWS: Describe changes.

Lines shorter than 10,000 characters shouldn't generally be causing
problems, so testing this explicitly will largely eliminate
false-positives.  We must also increase the maximum number of lines
to check, because 'minified' code may still include newlines, and so
there may be many lines shorter than the new threshold before we find
a line which exceeds it.

Previously we used a minimum-effort heuristic, testing a very small
number of lines against a maximum length which, while not remotely
long enough to cause problems, would nevertheless be uncommon in any
normal file of programming code (and hence indicative that the file
was likely to be minified code).

Testing indicates that the performance penalty for the larger values
should be negligible.
etc/NEWS
lisp/so-long.el