From: Lars Ingebrigtsen <larsi@gnus.org>
To: Phil Sainty <psainty@orcon.net.nz>
Cc: 45652@debbugs.gnu.org, "積丹尼 Dan Jacobson" <jidanni@jidanni.org>
Subject: bug#45652: so-long mode not triggered despite big file with very long lines
Date: Tue, 12 Jan 2021 20:22:46 +0100 [thread overview]
Message-ID: <87lfcyhse1.fsf@gnus.org> (raw)
In-Reply-To: <9463451af6d023fb4595ffa9182615b6@webmail.orcon.net.nz> (Phil Sainty's message of "Tue, 12 Jan 2021 15:42:37 +1300")
Phil Sainty <psainty@orcon.net.nz> writes:
> I'm not sure that so-long itself would find it useful to know any kind
> of averages, but longest line is obviously useful, and the number of
> lines sounds more or less like a freebie, and might be useful too.
The `buffer-line-statistics' function is now on the trunk, and it
returns count/longest/mean, since those three are free-ish. (I could
also add standard deviation or variance -- it would basically just be a
sqrt and a division per line?)
Testing in a 18MB zip file (which is probably on the outer limits of
what people load into Emacs, size-wise, for editing), it takes 0.002
seconds to compute the data, so for real usage, it should be
unnoticeable.
The data for that file is
(81472 2632 220.35040259229885)
There's a bit more newlines in that zip file than I'd expect? I mean,
if it was totally random, it should be 255 or something?
Anyway, I digress.
--
(domestic pets only, the antidote for overdose, milk.)
bloggy blog: http://lars.ingebrigtsen.no
next prev parent reply other threads:[~2021-01-12 19:22 UTC|newest]
Thread overview: 25+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-01-04 11:47 bug#45652: so-long mode not triggered despite big file with very long lines 積丹尼 Dan Jacobson
2021-01-10 14:53 ` Lars Ingebrigtsen
2021-01-11 11:21 ` 積丹尼 Dan Jacobson
2021-01-11 11:28 ` Phil Sainty
2021-01-11 12:55 ` 積丹尼 Dan Jacobson
2021-01-11 19:10 ` Phil Sainty
2021-01-11 23:04 ` 積丹尼 Dan Jacobson
2021-01-12 2:30 ` Phil Sainty
2021-01-12 5:53 ` 積丹尼 Dan Jacobson
2021-01-11 18:39 ` Lars Ingebrigtsen
2021-01-11 19:18 ` Phil Sainty
2021-01-11 19:30 ` Lars Ingebrigtsen
2021-01-11 21:07 ` Lars Ingebrigtsen
2021-01-12 2:42 ` Phil Sainty
2021-01-12 12:41 ` Lars Ingebrigtsen
2021-01-12 15:28 ` Eli Zaretskii
2021-01-12 15:37 ` Lars Ingebrigtsen
2021-01-12 15:50 ` Eli Zaretskii
2021-01-12 17:44 ` Lars Ingebrigtsen
2021-01-12 19:22 ` Lars Ingebrigtsen [this message]
2021-01-12 23:49 ` Phil Sainty
2021-07-30 5:30 ` Phil Sainty
2021-08-03 11:47 ` Phil Sainty
2021-01-12 3:25 ` Eli Zaretskii
2021-01-12 12:40 ` Lars Ingebrigtsen
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87lfcyhse1.fsf@gnus.org \
--to=larsi@gnus.org \
--cc=45652@debbugs.gnu.org \
--cc=jidanni@jidanni.org \
--cc=psainty@orcon.net.nz \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.