[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Merging bignum to master
From: |
Andy Moreton |
Subject: |
Re: Merging bignum to master |
Date: |
Thu, 16 Aug 2018 00:57:10 +0100 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/26.1.50 (windows-nt) |
On Wed 15 Aug 2018, Pip Cet wrote:
> If you really think XFIXNUMFWD is a good name, don't you at least
> agree that it should go with renaming other references to intfwds to
> fixnumfwds? Right now we have:
>
> static struct Lisp_Intfwd *
> XFIXNUMFWD (union Lisp_Fwd *a)
> {
> eassert (INTFWDP (a));
> return &a->u_intfwd;
> }
Please don't top-post on technical mailing lists.
XFIXNUMFWD might not be pretty, but it does convey the idea that this is
code that only understands fixnums (the same as pre-bignum emacs), and
will need careful inspection before modifying it to support bignums.
> I still think that's clearly a case of over-eager replacement (XINT ->
> XFIXNUM). To have XFIXNUMFWD but INTFWDP seems obviously wrong to me.
The XINT -> XFIXNUM renaming preserved the meaning from pre-bignum
emacs i.e. only fixnums are supported.
It would seem sensible to rename INTFWDP -> FIXNUMFWDP to keep the
naming consistent, and then extend the code to support bignums later.
One thing to be careful of here is that on 64bit Windows builds of
emacs, sizeof (EMACS_INT) is 64bit but sizeof (long) is 32bit. This
requires careful use of the GMP library API, which does not accept long
long inputs (see mpz_set_intmax and mpz_set_uintmax in lisp.h).
AndyM
- Re: Merging bignum to master, (continued)
- Re: Merging bignum to master, John Wiegley, 2018/08/12
- Re: Merging bignum to master, Pip Cet, 2018/08/12
- Re: Merging bignum to master, Tom Tromey, 2018/08/12
- Re: Merging bignum to master, Paul Eggert, 2018/08/13
- Re: Merging bignum to master, Noam Postavsky, 2018/08/13
- Re: Merging bignum to master, Pip Cet, 2018/08/14
- Re: Merging bignum to master, Paul Eggert, 2018/08/14
- Re: Merging bignum to master, Pip Cet, 2018/08/15
- Re: Merging bignum to master, Paul Eggert, 2018/08/15
- Re: Merging bignum to master,
Andy Moreton <=
- Re: Merging bignum to master, Stefan Monnier, 2018/08/16
- Some vars now limited to fixnum size. (Was: Merging bignum to master), Karl Fogel, 2018/08/20
- Re: Some vars now limited to fixnum size. (Was: Merging bignum to master), Paul Eggert, 2018/08/20
- Re: Some vars now limited to fixnum size. (Was: Merging bignum to master), Eli Zaretskii, 2018/08/20
- Re: Some vars now limited to fixnum size. (Was: Merging bignum to master), Paul Eggert, 2018/08/20
- Re: Some vars now limited to fixnum size. (Was: Merging bignum to master), Eli Zaretskii, 2018/08/20
- Re: Some vars now limited to fixnum size. (Was: Merging bignum to master), Pip Cet, 2018/08/20
- Re: Some vars now limited to fixnum size. (Was: Merging bignum to master), Paul Eggert, 2018/08/20
- Re: Some vars now limited to fixnum size., Tom Tromey, 2018/08/21
- Re: Some vars now limited to fixnum size., Andy Moreton, 2018/08/21