aboutsummaryrefslogtreecommitdiffstats
path: root/iseq.c
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2017-10-26 07:23:23 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2017-10-26 07:23:23 +0000
commit38828e61970293b1be6113413cbce96294280953 (patch)
tree57a01309af17a79bcf3f47f2bb95cf135fa955ca /iseq.c
parent9016f61ef226ec0acf6cfc7ddc429257312ca1db (diff)
downloadruby-38828e61970293b1be6113413cbce96294280953.tar.gz
common conversion functions
* array.c (rb_to_array_type): make public to share common code internally. * hash.c (rb_to_hash_type): make public to share common code internally. * symbol.c (rb_to_symbol_type): make public to share common code internally. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@60438 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'iseq.c')
-rw-r--r--iseq.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/iseq.c b/iseq.c
index adb0c79917..ccea4f1549 100644
--- a/iseq.c
+++ b/iseq.c
@@ -520,10 +520,10 @@ rb_iseq_load_iseq(VALUE fname)
return NULL;
}
-#define CHECK_ARRAY(v) rb_convert_type_with_id((v), T_ARRAY, "Array", idTo_ary)
-#define CHECK_HASH(v) rb_convert_type_with_id((v), T_HASH, "Hash", idTo_hash)
-#define CHECK_STRING(v) rb_convert_type_with_id((v), T_STRING, "String", idTo_str)
-#define CHECK_SYMBOL(v) rb_convert_type_with_id((v), T_SYMBOL, "Symbol", idTo_sym)
+#define CHECK_ARRAY(v) rb_to_array_type(v)
+#define CHECK_HASH(v) rb_to_hash_type(v)
+#define CHECK_STRING(v) rb_str_to_str(v)
+#define CHECK_SYMBOL(v) rb_to_symbol_type(v)
static inline VALUE CHECK_INTEGER(VALUE v) {(void)NUM2LONG(v); return v;}
static enum iseq_type