summaryrefslogtreecommitdiff
path: root/error.c
diff options
context:
space:
mode:
authorko1 <ko1@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2009-07-07 20:28:27 +0000
committerko1 <ko1@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2009-07-07 20:28:27 +0000
commit9e607430088d2b89576769530aa9069680da97f5 (patch)
tree0ee8d8249c167842a36aae1ed843a8551f430404 /error.c
parent26a1d97d8ccca6987549b3b4b5cdac61dacfdfe6 (diff)
* include/ruby/ruby.h:
rename "...TypeStruct" and "typed_struct" to "TypedData..." and "typeddata", respectively. rename rb_data_type_t#name to rb_data_type_t#wrap_struct_name. * error.c, gc.c, iseq.c, vm.c: ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@23987 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'error.c')
-rw-r--r--error.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/error.c b/error.c
index 537b1742fd..c3738db856 100644
--- a/error.c
+++ b/error.c
@@ -317,7 +317,7 @@ rb_check_type(VALUE x, int t)
}
int
-rb_typed_struct_is_kind_of(VALUE obj, const rb_data_type_t *data_type)
+rb_typeddata_is_kind_of(VALUE obj, const rb_data_type_t *data_type)
{
if (SPECIAL_CONST_P(obj) || BUILTIN_TYPE(obj) != T_DATA ||
!RTYPEDDATA_P(obj) || RTYPEDDATA_TYPE(obj) != data_type) {
@@ -327,7 +327,7 @@ rb_typed_struct_is_kind_of(VALUE obj, const rb_data_type_t *data_type)
}
void *
-rb_check_typed_struct(VALUE obj, const rb_data_type_t *data_type)
+rb_check_typeddata(VALUE obj, const rb_data_type_t *data_type)
{
const char *etype;
static const char mesg[] = "wrong argument type %s (expected %s)";
@@ -337,11 +337,11 @@ rb_check_typed_struct(VALUE obj, const rb_data_type_t *data_type)
}
if (!RTYPEDDATA_P(obj)) {
etype = rb_obj_classname(obj);
- rb_raise(rb_eTypeError, mesg, etype, data_type->name);
+ rb_raise(rb_eTypeError, mesg, etype, data_type->wrap_struct_name);
}
else if (RTYPEDDATA_TYPE(obj) != data_type) {
- etype = RTYPEDDATA_TYPE(obj)->name;
- rb_raise(rb_eTypeError, mesg, etype, data_type->name);
+ etype = RTYPEDDATA_TYPE(obj)->wrap_struct_name;
+ rb_raise(rb_eTypeError, mesg, etype, data_type->wrap_struct_name);
}
return DATA_PTR(obj);
}