diff options
author | drbrain <drbrain@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2011-08-16 00:34:51 +0000 |
---|---|---|
committer | drbrain <drbrain@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2011-08-16 00:34:51 +0000 |
commit | de6d4f7e7bdb78e5cb443a2e327265b52cde0d44 (patch) | |
tree | 7252478a71b4a14c2d8f594aaed1ce0757129a85 /ext/dl/cptr.c | |
parent | 87ff4b24ae4911bda46a5426024959c278da69b2 (diff) | |
download | ruby-de6d4f7e7bdb78e5cb443a2e327265b52cde0d44.tar.gz |
* ext/dl: Add documentation. Patch by Vincent Batts. [Ruby 1.9 - Bug #5192]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@32982 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext/dl/cptr.c')
-rw-r--r-- | ext/dl/cptr.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/ext/dl/cptr.c b/ext/dl/cptr.c index 2f6a65fe52..89dcb942c0 100644 --- a/ext/dl/cptr.c +++ b/ext/dl/cptr.c @@ -640,6 +640,11 @@ Init_dlptr(void) { id_to_ptr = rb_intern("to_ptr"); + /* Document-class: DL::CPtr + * + * CPtr is a class to handle C pointers + * + */ rb_cDLCPtr = rb_define_class_under(rb_mDL, "CPtr", rb_cObject); rb_define_alloc_func(rb_cDLCPtr, rb_dlptr_s_allocate); rb_define_singleton_method(rb_cDLCPtr, "malloc", rb_dlptr_s_malloc, -1); @@ -669,5 +674,9 @@ Init_dlptr(void) rb_define_method(rb_cDLCPtr, "size", rb_dlptr_size_get, 0); rb_define_method(rb_cDLCPtr, "size=", rb_dlptr_size_set, 1); + /* Document-const: NULL + * + * A NULL pointer + */ rb_define_const(rb_mDL, "NULL", rb_dlptr_new(0, 0, 0)); } |