diff options
author | Andy Wingo <wingo@pobox.com> | 2018-06-21 08:39:03 +0200 |
---|---|---|
committer | Andy Wingo <wingo@pobox.com> | 2018-06-21 20:18:54 +0200 |
commit | 16879cabed0e9bf218986bc886c3336a5f5a21c0 (patch) | |
tree | 3864d5f4926d4141b2ca0a0d378ca7b854aa6cc8 /libguile/hash.c | |
parent | 5e5afde06fd9dd0992294d6c7dc9f9966c0caa37 (diff) | |
download | guile-16879cabed0e9bf218986bc886c3336a5f5a21c0.tar.gz |
Replace uses of scm_t_int8, scm_t_uintmax, etc with stdint types
* libguile/bitvectors.c:
* libguile/bitvectors.h:
* libguile/bytevectors.c:
* libguile/bytevectors.h:
* libguile/chars.c:
* libguile/continuations.c:
* libguile/control.c:
* libguile/conv-integer.i.c:
* libguile/conv-uinteger.i.c:
* libguile/dynstack.c:
* libguile/dynstack.h:
* libguile/foreign.c:
* libguile/frames.c:
* libguile/frames.h:
* libguile/gc-inline.h:
* libguile/gc.h:
* libguile/gsubr.c:
* libguile/gsubr.h:
* libguile/hash.c:
* libguile/i18n.c:
* libguile/instructions.c:
* libguile/intrinsics.c:
* libguile/intrinsics.h:
* libguile/loader.c:
* libguile/loader.h:
* libguile/numbers.c:
* libguile/numbers.h:
* libguile/pairs.c:
* libguile/ports-internal.h:
* libguile/ports.c:
* libguile/ports.h:
* libguile/posix.c:
* libguile/print.c:
* libguile/print.h:
* libguile/programs.c:
* libguile/programs.h:
* libguile/r6rs-ports.c:
* libguile/random.c:
* libguile/random.h:
* libguile/scm.h:
* libguile/socket.c:
* libguile/srfi-4.c:
* libguile/srfi-4.h:
* libguile/stacks.c:
* libguile/stime.c:
* libguile/strings.c:
* libguile/struct.c:
* libguile/struct.h:
* libguile/symbols.c:
* libguile/threads.c:
* libguile/threads.h:
* libguile/uniform.c:
* libguile/vm-engine.c:
* libguile/vm.c:
* libguile/vm.h:
* libguile/vports.c:
* test-suite/standalone/test-conversion.c:
* test-suite/standalone/test-ffi-lib.c:
* test-suite/standalone/test-scm-take-u8vector.c:
* test-suite/standalone/test-srfi-4.c: Replace e.g. scm_t_uint8 with
uint8_t.
Diffstat (limited to 'libguile/hash.c')
-rw-r--r-- | libguile/hash.c | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/libguile/hash.c b/libguile/hash.c index bb3be1d38..d6e93dae0 100644 --- a/libguile/hash.c +++ b/libguile/hash.c @@ -82,10 +82,10 @@ extern double floor(); #define JENKINS_LOOKUP3_HASHWORD2(k, length, ret) \ do { \ - scm_t_uint32 a, b, c; \ + uint32_t a, b, c; \ \ /* Set up the internal state. */ \ - a = b = c = 0xdeadbeef + ((scm_t_uint32)(length<<2)) + 47; \ + a = b = c = 0xdeadbeef + ((uint32_t)(length<<2)) + 47; \ \ /* Handle most of the key. */ \ while (length > 3) \ @@ -117,7 +117,7 @@ extern double floor(); static unsigned long -narrow_string_hash (const scm_t_uint8 *str, size_t len) +narrow_string_hash (const uint8_t *str, size_t len) { unsigned long ret; JENKINS_LOOKUP3_HASHWORD2 (str, len, ret); @@ -140,7 +140,7 @@ scm_i_string_hash (SCM str) size_t len = scm_i_string_length (str); if (scm_i_is_narrow_string (str)) - return narrow_string_hash ((const scm_t_uint8 *) scm_i_string_chars (str), + return narrow_string_hash ((const uint8_t *) scm_i_string_chars (str), len); else return wide_string_hash (scm_i_string_wide_chars (str), len); @@ -158,21 +158,21 @@ scm_i_latin1_string_hash (const char *str, size_t len) if (len == (size_t) -1) len = strlen (str); - return narrow_string_hash ((const scm_t_uint8 *) str, len); + return narrow_string_hash ((const uint8_t *) str, len); } /* A tricky optimization, but probably worth it. */ unsigned long scm_i_utf8_string_hash (const char *str, size_t len) { - const scm_t_uint8 *end, *ustr = (const scm_t_uint8 *) str; + const uint8_t *end, *ustr = (const uint8_t *) str; unsigned long ret; /* The length of the string in characters. This name corresponds to Jenkins' original name. */ size_t length; - scm_t_uint32 a, b, c, u32; + uint32_t a, b, c, u32; if (len == (size_t) -1) len = strlen (str); @@ -186,7 +186,7 @@ scm_i_utf8_string_hash (const char *str, size_t len) length = u8_strnlen (ustr, len); /* Set up the internal state. */ - a = b = c = 0xdeadbeef + ((scm_t_uint32)(length<<2)) + 47; + a = b = c = 0xdeadbeef + ((uint32_t)(length<<2)) + 47; /* Handle most of the key. */ while (length > 3) @@ -308,7 +308,7 @@ scm_raw_ihash (SCM obj, size_t depth) case scm_tc7_symbol: return scm_i_symbol_hash (obj); case scm_tc7_pointer: - return scm_raw_ihashq ((scm_t_uintptr) SCM_POINTER_VALUE (obj)); + return scm_raw_ihashq ((uintptr_t) SCM_POINTER_VALUE (obj)); case scm_tc7_wvect: case scm_tc7_vector: { |