Ruby shared_ptr fixes for use with minherit
This commit is contained in:
parent
04fd4a9c68
commit
e12277a469
4 changed files with 76 additions and 10 deletions
28
Examples/test-suite/ruby/ruby_minherit_shared_ptr_runme.rb
Normal file
28
Examples/test-suite/ruby/ruby_minherit_shared_ptr_runme.rb
Normal file
|
|
@ -0,0 +1,28 @@
|
|||
#!/usr/bin/env ruby
|
||||
#
|
||||
# Put description here
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
#
|
||||
|
||||
require 'ruby_minherit_shared_ptr'
|
||||
|
||||
md = Ruby_minherit_shared_ptr::MultiDerived.new(11, 22)
|
||||
|
||||
if md.Base1Func != 11 then
|
||||
raise RuntimeError
|
||||
end
|
||||
if md.Interface1Func != 22 then
|
||||
raise RuntimeError
|
||||
end
|
||||
if Ruby_minherit_shared_ptr.BaseCheck(md) != 11 then
|
||||
raise RuntimeError
|
||||
end
|
||||
if Ruby_minherit_shared_ptr.InterfaceCheck(md) != 22 then
|
||||
raise RuntimeError
|
||||
end
|
||||
if Ruby_minherit_shared_ptr.DerivedCheck(md) != 33 then
|
||||
raise RuntimeError
|
||||
end
|
||||
Loading…
Add table
Add a link
Reference in a new issue