mirror of
https://git.savannah.gnu.org/git/guile.git
synced 2025-06-24 12:20:20 +02:00
VM: Redefine INUM_MIN and INUM_MAX without assumptions.
* libguile/vm-i-scheme.c (INUM_MIN, INUM_MAX): Redefine to avoid assumptions about the representation of inums.
This commit is contained in:
parent
00472a22bb
commit
478fa0d530
1 changed files with 4 additions and 2 deletions
|
@ -207,8 +207,10 @@ VM_DEFINE_FUNCTION (149, ge, "ge?", 2)
|
|||
/* The maximum/minimum tagged integers. */
|
||||
#undef INUM_MAX
|
||||
#undef INUM_MIN
|
||||
#define INUM_MAX (INTPTR_MAX - 1)
|
||||
#define INUM_MIN (INTPTR_MIN + scm_tc2_int)
|
||||
#define INUM_MAX \
|
||||
((scm_t_signed_bits) SCM_UNPACK (SCM_I_MAKINUM (SCM_MOST_POSITIVE_FIXNUM)))
|
||||
#define INUM_MIN \
|
||||
((scm_t_signed_bits) SCM_UNPACK (SCM_I_MAKINUM (SCM_MOST_NEGATIVE_FIXNUM)))
|
||||
|
||||
#undef FUNC2
|
||||
#define FUNC2(CFUNC,SFUNC) \
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue