Maintenance Ruby 3.4 gets fixes, but no new features. Switch to Ruby 4.0 →
class method
Fiddle.dlunwrap
Fiddle.dlunwrap(addr)
ext/fiddle/fiddle.c
View on GitHub ↗
VALUE
rb_fiddle_ptr2value(VALUE self, VALUE addr)
{
return (VALUE)NUM2PTR(addr);
}
Returns the Ruby object stored at the memory address addr
Example:
Example
x = Object.new # => #<Object:0x0000000107c7d870> Fiddle.dlwrap(x) # => 4425504880 Fiddle.dlunwrap(_) # => #<Object:0x0000000107c7d870>