summaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2009-07-07 07:54:28 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2009-07-07 07:54:28 +0000
commit776867e14b8110643f6691d882b29acd966919f4 (patch)
tree995b4ebf38b0616393b4c0391a711544636e43de /include
parent4fdd11e028c2c0d3a14bb17e45dd57b6fd84ed7c (diff)
downloadruby-776867e14b8110643f6691d882b29acd966919f4.tar.gz
ruby-776867e14b8110643f6691d882b29acd966919f4.tar.xz
ruby-776867e14b8110643f6691d882b29acd966919f4.zip
* error.c (rb_typed_struct_is_kind_of): new function to see if the
given typed struct. git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@23983 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'include')
-rw-r--r--include/ruby/ruby.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/include/ruby/ruby.h b/include/ruby/ruby.h
index 8aef106b9..d9d23355e 100644
--- a/include/ruby/ruby.h
+++ b/include/ruby/ruby.h
@@ -764,8 +764,10 @@ typedef void (*RUBY_DATA_FUNC)(void*);
VALUE rb_data_object_alloc(VALUE,void*,RUBY_DATA_FUNC,RUBY_DATA_FUNC);
VALUE rb_data_typed_object_alloc(VALUE klass, void *datap, const rb_data_type_t *);
+int rb_typed_struct_is_kind_of(VALUE, const rb_data_type_t *);
void *rb_check_typed_struct(VALUE, const rb_data_type_t *);
#define Check_TypedStruct(v,t) rb_check_typed_struct((VALUE)(v),t)
+#define RUBY_TYPED_DEFAULT_FREE ((void (*)(void *))-1)
#define Data_Wrap_Struct(klass,mark,free,sval)\
rb_data_object_alloc(klass,sval,(RUBY_DATA_FUNC)mark,(RUBY_DATA_FUNC)free)