1
Fork 0
mirror of https://git.savannah.gnu.org/git/guile.git synced 2025-06-29 14:30:34 +02:00

* symbols.c (scm_strhash): scm_downcase is now a function, not an

array; use it appropriately.  Since GCC is quite happy to
subscript functions, it never warned us about this; we should use
-Wpointer-arith in the future.  I guess we never tested
case-insensitivity.
This commit is contained in:
Jim Blandy 1996-08-30 03:36:29 +00:00
parent 866679103b
commit 566011b96d

View file

@ -76,7 +76,7 @@ scm_strhash (str, len, n)
scm_sizet i = 5;
unsigned long h = 264 % n;
while (i--)
h = ((h << 8) + ((unsigned) (scm_downcase[str[h % len]]))) % n;
h = ((h << 8) + ((unsigned) (scm_downcase (str[h % len])))) % n;
return h;
}
else
@ -84,7 +84,7 @@ scm_strhash (str, len, n)
scm_sizet i = len;
unsigned long h = 0;
while (i)
h = ((h << 8) + ((unsigned) (scm_downcase[str[--i]]))) % n;
h = ((h << 8) + ((unsigned) (scm_downcase (str[--i])))) % n;
return h;
}
}