From: Thomas Fitzsimmons <fitzsim@fitzsim.org>
To: emacs-devel@gnu.org
Cc: "Mattias Engdegård" <mattiase@acm.org>
Subject: Re: master 9f464cc: Stop using calc for ntlm time computation
Date: Mon, 26 Oct 2020 17:19:52 -0400 [thread overview]
Message-ID: <m37drcheh3.fsf@fitzsim.org> (raw)
In-Reply-To: <20200816091705.318C0209AC@vcs0.savannah.gnu.org> ("Mattias Engdegård"'s message of "Sun, 16 Aug 2020 05:17:04 -0400 (EDT)")
Hi Mattias,
Mattias Engdegård <mattiase@savannah.gnu.org> writes:
> branch: master
> commit 9f464ccaf9acc36b22bc292c6c572048e147d281
> Author: Mattias Engdegård <mattiase@acm.org>
> Commit: Mattias Engdegård <mattiase@acm.org>
>
> Stop using calc for ntlm time computation
>
> * lisp/net/ntlm.el: Don't require calc.
> (ntlm-compute-timestamp): Use plain arithmetic instead of calc.
> (ntlm--time-to-timestamp): New helper function.
[...]
> - ;; FIXME: This can likely be significantly simplified using the new
> - ;; bignums support!
Thanks for fixing this item.
ntlm.el goes into GNU ELPA so I'd like to keep it working on older
versions of Emacs. I usually try to keep it working at least back to
Emacs 24.1, the first version to support packages via package.el.
The new code definitely makes sense for Emacs versions that have bignum
support. However I'd like to know before I bump the ntlm.el version
(and thus make these updates available to GNU ELPA users), are there
configurations anyone knows of where the new code will fail, but the
"calc" version would work?
I seem to remember I wrote the strange calc version to avoid integer
overflow, but I don't remember the characteristics of the system on
which I developed it; maybe it had a 32-bit word size. Admittedly
though, I recently tried the new calculation code on Emacs 24.1, running
on an x86-64 system, and it works.
Still, if these types of calculations are known to overflow on 32-bit
Emacs builds then my inclination would be to conditionalize them.
Thanks,
Thomas
next parent reply other threads:[~2020-10-26 21:19 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20200816091703.7193.11125@vcs0.savannah.gnu.org>
[not found] ` <20200816091705.318C0209AC@vcs0.savannah.gnu.org>
2020-10-26 21:19 ` Thomas Fitzsimmons [this message]
2020-10-26 21:57 ` master 9f464cc: Stop using calc for ntlm time computation Mattias Engdegård
2020-10-27 11:33 ` Mattias Engdegård
2020-10-27 13:06 ` Stefan Monnier
2020-10-27 13:45 ` Stefan Monnier
2020-10-27 14:01 ` Mattias Engdegård
2020-10-27 14:06 ` Mattias Engdegård
2020-10-27 15:23 ` Stefan Monnier
2020-10-27 16:18 ` Mattias Engdegård
2020-10-27 16:28 ` Thomas Fitzsimmons
2020-10-27 13:53 ` Mattias Engdegård
2020-10-27 15:34 ` Thomas Fitzsimmons
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
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=m37drcheh3.fsf@fitzsim.org \
--to=fitzsim@fitzsim.org \
--cc=emacs-devel@gnu.org \
--cc=mattiase@acm.org \
/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 public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).