1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

* ext/dl/cptr.c (to_int): DL::CPtr supports to_int

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@25996 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
tenderlove 2009-12-04 23:21:01 +00:00
parent beb486d55e
commit 6a1aebaabf
2 changed files with 6 additions and 0 deletions

View file

@ -3,6 +3,11 @@ require_relative '../ruby/envutil'
module DL
class TestCPtr < TestBase
def test_cptr_to_int
null = DL::NULL
assert_equal(null.to_i, null.to_int)
end
def test_malloc_free_func_int
free = CFunc.new(DL::RUBY_FREE, TYPE_VOID, 'free')