diff options
author | Andy Wingo <wingo@pobox.com> | 2022-01-06 20:12:06 +0100 |
---|---|---|
committer | Andy Wingo <wingo@pobox.com> | 2022-01-13 09:37:16 +0100 |
commit | 27910181c53a7f836bfc8dc9c5619e2e3110eeaf (patch) | |
tree | 056872d3cb0460ca3cb627355814e2debf7df6b2 /libguile/integers.h | |
parent | f4db3ca3f9986477f6a8d4eddae8b88604e3f8a9 (diff) | |
download | guile-27910181c53a7f836bfc8dc9c5619e2e3110eeaf.tar.gz |
Reimplement scm_from_int8 etc
* libguile/integers.c (make_bignum_from_uint64):
(make_bignum_from_int64): New helpers.
(scm_integer_from_int64):
(scm_integer_from_uint64): New internal functions.
* libguile/integers.h: Declare new internal functions.
* libguile/numbers.c (range_error): Declare as noreturn.xo
(inum_in_range): New helper.
(scm_from_signed_integer):
(scm_to_signed_integer):
(scm_from_unsigned_integer):
(scm_to_unsigned_integer):
(scm_to_int8):
(scm_from_int8):
(scm_to_uint8):
(scm_from_uint8):
(scm_to_int16):
(scm_from_int16):
(scm_to_uint16):
(scm_from_uint16): Implement manually.
Diffstat (limited to 'libguile/integers.h')
-rw-r--r-- | libguile/integers.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/libguile/integers.h b/libguile/integers.h index 60e3ea9bd..8bf91f567 100644 --- a/libguile/integers.h +++ b/libguile/integers.h @@ -202,6 +202,9 @@ SCM_INTERNAL SCM scm_integer_exact_quotient_zz (struct scm_bignum *n, SCM_INTERNAL int scm_integer_to_int64_z (struct scm_bignum *z, int64_t *val); SCM_INTERNAL int scm_integer_to_uint64_z (struct scm_bignum *z, uint64_t *val); +SCM_INTERNAL SCM scm_integer_from_int64 (int64_t n); +SCM_INTERNAL SCM scm_integer_from_uint64 (uint64_t n); + #endif /* SCM_INTEGERS_H */ |