class FFI::ManagedStruct

def initialize(pointer=nil)

When passed a pointer, create a new ManagedStruct which will invoke the class method release() on

ManagedStruct.new
ManagedStruct.new(pointer)
call-seq:
def initialize(pointer=nil)
  raise NoMethodError, "release() not implemented for class #{self}" unless self.class.respond_to? :release
  raise ArgumentError, "Must supply a pointer to memory for the Struct" unless pointer
  super AutoPointer.new(pointer, self.class.method(:release))
end