summaryrefslogtreecommitdiff
path: root/hash.c
diff options
context:
space:
mode:
Diffstat (limited to 'hash.c')
-rw-r--r--hash.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/hash.c b/hash.c
index 7b8733f41c..5b13d98ea3 100644
--- a/hash.c
+++ b/hash.c
@@ -17,6 +17,7 @@
#include <errno.h>
#include "probes.h"
#include "id.h"
+#include "symbol.h"
#ifdef __APPLE__
# ifdef HAVE_CRT_EXTERNS_H
@@ -149,7 +150,7 @@ rb_any_hash(VALUE a)
hnum = rb_str_hash(a);
}
else if (BUILTIN_TYPE(a) == T_SYMBOL) {
- hnum = rb_objid_hash((st_index_t)a);
+ return RSYMBOL(a)->hashval;
}
else if (BUILTIN_TYPE(a) == T_FLOAT) {
return rb_dbl_hash(rb_float_value(a));