summaryrefslogtreecommitdiff
path: root/hash.c
diff options
context:
space:
mode:
authormatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2003-01-20 08:29:24 +0000
committermatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2003-01-20 08:29:24 +0000
commitd242ae60d8d8bccb8e209130d3bdb1cc41333b8c (patch)
treee1cc1f856aac1c3bda4897c7a244b43039316f3d /hash.c
parent181edd12a09a76e2443c702ff2e17777fe8cfeb5 (diff)
* regex.c (is_in_list): should work weill with UTF-8.
* regex.c (re_match_exec): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@3363 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'hash.c')
-rw-r--r--hash.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/hash.c b/hash.c
index 257a4c8e47..249bc645a5 100644
--- a/hash.c
+++ b/hash.c
@@ -101,10 +101,7 @@ rb_any_hash(a)
default:
DEFER_INTS;
hval = rb_funcall(a, id_hash, 0);
- if (FIXNUM_P(hval)) {
- hval %= 536870923;
- }
- else {
+ if (!FIXNUM_P(hval)) {
hval = rb_funcall(hval, '%', 1, INT2FIX(536870923));
}
ENABLE_INTS;